TCHChannel Class Reference
Inherits from | NSObject |
---|---|
Declared in | TCHChannel.h |
delegate
Optional channel delegate. Upon setting the delegate, you will receive the current channel synchronization status by delegate method.
@property (nonatomic, weak) id<TCHChannelDelegate> delegate
Discussion
Optional channel delegate. Upon setting the delegate, you will receive the current channel synchronization status by delegate method.
Declared In
TCHChannel.h
sid
The unique identifier for this channel.
@property (nonatomic, copy, readonly) NSString *sid
Discussion
The unique identifier for this channel.
Declared In
TCHChannel.h
friendlyName
The friendly name for this channel.
@property (nonatomic, copy, readonly) NSString *friendlyName
Discussion
The friendly name for this channel.
Declared In
TCHChannel.h
uniqueName
The unique name for this channel.
@property (nonatomic, copy, readonly) NSString *uniqueName
Discussion
The unique name for this channel.
Declared In
TCHChannel.h
messages
The messages list object for this channel.
@property (nonatomic, strong, readonly) TCHMessages *messages
Discussion
The messages list object for this channel.
Declared In
TCHChannel.h
members
The members list object for this channel.
@property (nonatomic, strong, readonly) TCHMembers *members
Discussion
The members list object for this channel.
Declared In
TCHChannel.h
status
The current user’s status on this channel.
@property (nonatomic, assign, readonly) TCHChannelStatus status
Discussion
The current user’s status on this channel.
Declared In
TCHChannel.h
type
The channel’s visibility type.
@property (nonatomic, assign, readonly) TCHChannelType type
Discussion
The channel’s visibility type.
Declared In
TCHChannel.h
dateCreated
The timestamp the channel was created.
@property (nonatomic, strong, readonly) NSString *dateCreated
Discussion
The timestamp the channel was created.
Declared In
TCHChannel.h
dateCreatedAsDate
The timestamp the channel was created as an NSDate.
@property (nonatomic, strong, readonly) NSDate *dateCreatedAsDate
Discussion
The timestamp the channel was created as an NSDate.
Declared In
TCHChannel.h
createdBy
The identity of the channel’s creator.
@property (nonatomic, copy, readonly) NSString *createdBy
Discussion
The identity of the channel’s creator.
Declared In
TCHChannel.h
dateUpdated
The timestamp the channel was last updated.
@property (nonatomic, strong, readonly) NSString *dateUpdated
Discussion
The timestamp the channel was last updated.
Declared In
TCHChannel.h
dateUpdatedAsDate
The timestamp the channel was last updated as an NSDate.
@property (nonatomic, strong, readonly) NSDate *dateUpdatedAsDate
Discussion
The timestamp the channel was last updated as an NSDate.
Declared In
TCHChannel.h
– attributes
Return this channel’s attributes.
- (NSDictionary<NSString*,id> *)attributes
Return Value
The developer-defined extensible attributes for this channel.
Discussion
Return this channel’s attributes.
Declared In
TCHChannel.h
– setAttributes:completion:
Set this channel’s attributes.
- (void)setAttributes:(NSDictionary<NSString*,id> *)attributes completion:(TCHCompletion)completion
Parameters
attributes |
The new developer-defined extensible attributes for this channel. (Supported types are NSString, NSNumber, NSArray, NSDictionary and NSNull) |
---|---|
completion |
Completion block that will specify the result of the operation. |
Discussion
Set this channel’s attributes.
Declared In
TCHChannel.h
– setFriendlyName:completion:
Set this channel’s friendly name.
- (void)setFriendlyName:(NSString *)friendlyName completion:(TCHCompletion)completion
Parameters
friendlyName |
The new friendly name for this channel. |
---|---|
completion |
Completion block that will specify the result of the operation. |
Discussion
Set this channel’s friendly name.
Declared In
TCHChannel.h
– setUniqueName:completion:
Set this channel’s unique name.
- (void)setUniqueName:(NSString *)uniqueName completion:(TCHCompletion)completion
Parameters
uniqueName |
The new unique name for this channel. |
---|---|
completion |
Completion block that will specify the result of the operation. |
Discussion
Set this channel’s unique name.
Declared In
TCHChannel.h
– joinWithCompletion:
Join the current user to this channel.
- (void)joinWithCompletion:(TCHCompletion)completion
Parameters
completion |
Completion block that will specify the result of the operation. |
---|
Discussion
Join the current user to this channel.
Declared In
TCHChannel.h
– declineInvitationWithCompletion:
Decline an invitation to this channel.
- (void)declineInvitationWithCompletion:(TCHCompletion)completion
Parameters
completion |
Completion block that will specify the result of the operation. |
---|
Discussion
Decline an invitation to this channel.
Declared In
TCHChannel.h
– leaveWithCompletion:
Leave the current channel.
- (void)leaveWithCompletion:(TCHCompletion)completion
Parameters
completion |
Completion block that will specify the result of the operation. |
---|
Discussion
Leave the current channel.
Declared In
TCHChannel.h
– typing
Indicates to other users and the backend that the user is typing a message to this channel.
- (void)typing
Discussion
Indicates to other users and the backend that the user is typing a message to this channel.
Declared In
TCHChannel.h
– memberWithIdentity:
Fetch the member object for the given identity if it exists.
- (TCHMember *)memberWithIdentity:(NSString *)identity
Parameters
identity |
The username to fetch. |
---|
Return Value
The TCHMember object, if one exists for the username for this channel.
Discussion
Fetch the member object for the given identity if it exists.
Declared In
TCHChannel.h
– getUnconsumedMessagesCountWithCompletion:
Fetch the number of unconsumed messages on this channel for the current user.
- (void)getUnconsumedMessagesCountWithCompletion:(TCHCountCompletion)completion
Parameters
completion |
Completion block that will speciy the requested count. If no completion block is specified, no operation will be executed. |
---|
Discussion
Fetch the number of unconsumed messages on this channel for the current user.
Available even if the channel is not yet synchronized. Subsequent calls of this method prior to the local cache’s expiry will return cached values.
Declared In
TCHChannel.h
– getMessagesCountWithCompletion:
Fetch the number of messages on this channel.
- (void)getMessagesCountWithCompletion:(TCHCountCompletion)completion
Parameters
completion |
Completion block that will speciy the requested count. If no completion block is specified, no operation will be executed. |
---|
Discussion
Fetch the number of messages on this channel.
Available even if the channel is not yet synchronized.
Available even if the channel is not yet synchronized. Subsequent calls of this method prior to the local cache’s expiry will return cached values.
Declared In
TCHChannel.h
– getMembersCountWithCompletion:
Fetch the number of members on this channel.
- (void)getMembersCountWithCompletion:(TCHCountCompletion)completion
Parameters
completion |
Completion block that will speciy the requested count. If no completion block is specified, no operation will be executed. |
---|
Discussion
Fetch the number of members on this channel.
Available even if the channel is not yet synchronized.
Available even if the channel is not yet synchronized. Subsequent calls of this method prior to the local cache’s expiry will return cached values.
Declared In
TCHChannel.h