mpc-js
    Preparing search index...

    Interface StickerCommands

    interface StickerCommands {
        decrementSticker(
            type: string,
            uri: string,
            name: string,
            value: number,
        ): Promise<void>;
        deleteSticker(type: string, uri: string, name?: string): Promise<void>;
        findStickers(
            type: string,
            uri: string,
            name: string,
            value?: string,
            operator?: "=" | "<" | ">",
        ): Promise<Map<string, string>>;
        getSticker(type: string, uri: string, name: string): Promise<string>;
        getStickerNames(): Promise<string[]>;
        getStickerNamesTypes(type?: string): Promise<[string, string][]>;
        getStickerTypes(): Promise<string[]>;
        incrementSticker(
            type: string,
            uri: string,
            name: string,
            value: number,
        ): Promise<void>;
        listStickers(type: string, uri: string): Promise<Map<string, string>>;
        setSticker(
            type: string,
            uri: string,
            name: string,
            value: string,
        ): Promise<void>;
    }

    Hierarchy

    • ReturnType<typeof createStickerCommands>
      • StickerCommands
    Index

    Methods

    • Adds a sticker value to the specified object. If a sticker item with that name already exists, it is decremented by supplied value.

      Parameters

      • type: string
      • uri: string
      • name: string
      • value: number

      Returns Promise<void>

    • Deletes a sticker value from the specified object. If you do not specify a sticker name, all sticker values are deleted.

      Parameters

      • type: string
      • uri: string
      • Optionalname: string

      Returns Promise<void>

    • Searches the sticker database for stickers with the specified name, below the specified directory (uri). Returns a Map with the URIs of the matching songs as keys.

      Parameters

      • type: string
      • uri: string
      • name: string
      • Optionalvalue: string
      • operator: "=" | "<" | ">" = '='

      Returns Promise<Map<string, string>>

    • Reads a sticker value for the specified object.

      Parameters

      • type: string
      • uri: string
      • name: string

      Returns Promise<string>

    • Gets a list of uniq sticker names.

      Returns Promise<string[]>

    • Gets a list of uniq sticker names and their types.

      Parameters

      • Optionaltype: string

      Returns Promise<[string, string][]>

    • Gets a list of available sticker types.

      Returns Promise<string[]>

    • Adds a sticker value to the specified object. If a sticker item with that name already exists, it is incremented by supplied value.

      Parameters

      • type: string
      • uri: string
      • name: string
      • value: number

      Returns Promise<void>

    • Lists the stickers for the specified object. Returns a Map with sticker names as keys.

      Parameters

      • type: string
      • uri: string

      Returns Promise<Map<string, string>>

    • Adds a sticker value to the specified object. If a sticker item with that name already exists, it is replaced.

      Parameters

      • type: string
      • uri: string
      • name: string
      • value: string

      Returns Promise<void>