AppleSauce
    Preparing search index...

    Interface IEventDatabase

    The base interface for a database of events

    interface IEventDatabase {
        update?: (event: Event) => void;
        add(event: Event): Event;
        getByFilters(filters: Filter | Filter[]): Event[];
        getEvent(id: string): Event | undefined;
        getReplaceable(
            kind: number,
            pubkey: string,
            identifier?: string,
        ): Event | undefined;
        getReplaceableHistory(
            kind: number,
            pubkey: string,
            identifier?: string,
        ): Event[] | undefined;
        getTimeline(filters: Filter | Filter[]): Event[];
        hasEvent(id: string): boolean;
        hasReplaceable(kind: number, pubkey: string, identifier?: string): boolean;
        remove(event: string | Event): boolean;
        removeByFilters(filters: Filter | Filter[]): number;
    }

    Hierarchy (View Summary)

    Index

    Properties

    update?: (event: Event) => void

    Notifies the database that an event has updated

    Methods