Class ListItemManager

The manager of items that belong to a list channel.

Example

new ListItemManager(channel);

Hierarchy

Constructors

Properties

cache: CacheCollection<string, ListItem>

This cache of the manager.

channel: ListChannel

The list channel the items belong to.

client: Client

The client the manager belongs to.

Methods

  • Add a item to the list channel.

    Returns

    The added item.

    Example

    items.add('Hello World!');
    

    Parameters

    • message: string

      The message of the item.

    • Optional note: string

      The note of the item.

    Returns Promise<ListItem>

  • Edit a item in the list channel.

    Returns

    The edited item.

    Example

    items.edit(item, 'Hello World!');
    

    Parameters

    • listItem: string | ListItem

      The item to edit.

    • message: string

      The message of the item.

    • Optional note: string

      The note of the item.

    Returns Promise<ListItem>