Package io.ably.lib.realtime
Interface AblyRealtime.Channels
- All Superinterfaces:
ReadOnlyMap<String,
Channel>
- Enclosing class:
- AblyRealtime
A collection of Channels associated with this Ably Realtime instance.
-
Method Summary
Modifier and TypeMethodDescriptionCreates a newChannel
object, or returns the existing channel object.get
(String channelName, ChannelOptions channelOptions) Creates a newChannel
object, with the specifiedChannelOptions
, or returns the existing channel object.void
Releases aChannel
object, deleting it, and enabling it to be garbage collected.Methods inherited from interface io.ably.lib.types.ReadOnlyMap
containsKey, containsValue, entrySet, get, isEmpty, keySet, size, values
-
Method Details
-
get
Creates a newChannel
object, or returns the existing channel object.Spec: RSN3a, RTS3a
- Parameters:
-
channelName
- The channel name. - Returns:
- A
Channel
object.
-
get
Creates a newChannel
object, with the specifiedChannelOptions
, or returns the existing channel object.Spec: RSN3c, RTS3c
- Parameters:
-
channelName
- The channel name. -
channelOptions
- AChannelOptions
object. - Returns:
- A
Channel
object. - Throws:
AblyException
-
release
Releases aChannel
object, deleting it, and enabling it to be garbage collected. It also removes any listeners associated with the channel. To release a channel, theChannelState
must be INITIALIZED, DETACHED, or FAILED.Spec: RSN4, RTS4
- Parameters:
-
channelName
- The channel name.
-