Package io.ably.lib.push
Class PushBase.ChannelSubscription
java.lang.Object
io.ably.lib.push.PushBase.ChannelSubscription
- Enclosing class:
- PushBase
Contains the subscriptions of a device, or a group of devices sharing the same clientId,
has to a channel in order to receive push notifications.
-
Field Summary
Modifier and TypeFieldDescriptionfinal String
The channel the push notification subscription is for.final String
The ID of the client the device, or devices are associated to.final String
The unique ID of the device.protected static HttpCore.BodyHandler<PushBase.ChannelSubscription>
protected static HttpCore.ResponseHandler<PushBase.ChannelSubscription>
-
Method Summary
Modifier and TypeMethodDescriptionboolean
static PushBase.ChannelSubscription
forClientId
(String channel, String clientId) A static factory method to create a PushChannelSubscription object for a channel and group of devices sharing the same clientId.static PushBase.ChannelSubscription
A static factory method to create a PushChannelSubscription object for a channel and single device.static PushBase.ChannelSubscription
fromJsonObject
(com.google.gson.JsonObject o) com.google.gson.JsonObject
toString()
-
Field Details
-
channel
The channel the push notification subscription is for.Spec: PCS4
-
deviceId
The unique ID of the device.Spec: PCS2, PCS5, PCS6
-
clientId
The ID of the client the device, or devices are associated to.Spec: PCS3, PCS6
-
httpResponseHandler
-
httpBodyHandler
-
-
Method Details
-
forDevice
A static factory method to create a PushChannelSubscription object for a channel and single device.- Parameters:
-
channel
- The channel name. -
deviceId
- The unique ID of the device. - Returns:
- A
PushBase.ChannelSubscription
object.
-
forClientId
A static factory method to create a PushChannelSubscription object for a channel and group of devices sharing the same clientId.- Parameters:
-
channel
- The channel name. -
clientId
- The ID of the client. - Returns:
- A
PushBase.ChannelSubscription
object.
-
toJsonObject
public com.google.gson.JsonObject toJsonObject() -
equals
-
toString
-
fromJsonObject
-