Package io.ably.lib.objects
Class Adapter
java.lang.Object
io.ably.lib.objects.Adapter
- All Implemented Interfaces:
LiveObjectsAdapter
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Retrieves the maximum message size allowed for the messages.void
send
(@NotNull ProtocolMessage msg, @NotNull CompletionListener listener) Sends a protocol message to its intended recipient.void
setChannelSerial
(@NotNull String channelName, @NotNull String channelSerial) Sets the channel serial for a specific channel.
-
Constructor Details
-
Adapter
-
-
Method Details
-
setChannelSerial
public void setChannelSerial(@NotNull @NotNull String channelName, @NotNull @NotNull String channelSerial) Description copied from interface:LiveObjectsAdapter
Sets the channel serial for a specific channel.- Specified by:
-
setChannelSerial
in interfaceLiveObjectsAdapter
- Parameters:
-
channelName
- the name of the channel for which to set the serial -
channelSerial
- the serial to set for the channel
-
send
public void send(@NotNull @NotNull ProtocolMessage msg, @NotNull @NotNull CompletionListener listener) throws AblyException Description copied from interface:LiveObjectsAdapter
Sends a protocol message to its intended recipient. This method transmits a protocol message, allowing for queuing events if necessary, and notifies the provided listener upon the success or failure of the send operation.- Specified by:
-
send
in interfaceLiveObjectsAdapter
- Parameters:
-
msg
- the protocol message to send. -
listener
- a listener to be notified of the success or failure of the send operation. - Throws:
-
AblyException
- if an error occurs during the send operation.
-
maxMessageSizeLimit
public int maxMessageSizeLimit()Description copied from interface:LiveObjectsAdapter
Retrieves the maximum message size allowed for the messages. This method returns the maximum size in bytes that a message can have.- Specified by:
-
maxMessageSizeLimit
in interfaceLiveObjectsAdapter
- Returns:
- the maximum message size limit in bytes.
-