AppleSauce
    Preparing search index...

    Interface IAsyncEventDatabase

    The async base interface for a set of events

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

    Hierarchy (View Summary)

    Index

    Properties

    update?: (event: Event) => void

    Notifies the database that an event has updated

    Methods