TCHChannels Class Reference

Inherits from NSObject
Declared in TCHChannels.h

Overview

Representation of a chat channel list.

– userChannelsWithCompletion:

Retrieve a list of channels the user has a participation state on, for example invited, joined, creator.

- (void)userChannelsWithCompletion:(TCHChannelPaginatorCompletion)completion

Parameters

completion

Completion block that will specify the result of the operation and a reference to the first page of user channels. If no completion block is specified, no operation will be executed.

Discussion

Retrieve a list of channels the user has a participation state on, for example invited, joined, creator.

Declared In

TCHChannels.h

– publicChannelsWithCompletion:

Retrieve a list of channel descriptors for publicly visible channels.

- (void)publicChannelsWithCompletion:(TCHChannelDescriptorPaginatorCompletion)completion

Parameters

completion

Completion block that will specify the result of the operation and a reference to the first page of public channels. If no completion block is specified, no operation will be executed.

Discussion

Retrieve a list of channel descriptors for publicly visible channels.

Declared In

TCHChannels.h

– createChannelWithOptions:completion:

Create a new channel with the specified options.

- (void)createChannelWithOptions:(NSDictionary *)options completion:(TCHChannelCompletion)completion

Parameters

options

Channel options for new channel whose keys are TCHChannelOption* constants. (optional - may be empty or nil)

completion

Completion block that will specify the result of the operation and a reference to the new channel.

Discussion

Create a new channel with the specified options.

TCHChannelOptionFriendlyName - String friendly name (optional)

TCHChannelOptionUniqueName - String unique name (optional)

TCHChannelOptionType - Expected values are @(TCHChannelTypePublic) or @(TCHChannelTypePrivate) (optional)

TCHChannelOptionAttributes - Expected value is an NSDictionary<NSString,id> , see also TCHChannel setAttributes:completion: (optional)

Declared In

TCHChannels.h

– channelWithSidOrUniqueName:completion:

Obtains a channel with the specified id or unique name.

- (void)channelWithSidOrUniqueName:(NSString *)sidOrUniqueName completion:(TCHChannelCompletion)completion

Parameters

sidOrUniqueName

Identifier or unique name for the channel.

completion

Completion block that will specify the result of the operation and a reference to the requested channel if it exists.

Discussion

Obtains a channel with the specified id or unique name.

Declared In

TCHChannels.h