class Ably::Realtime::Push
Class providing push notification functionality
Attributes
client[R]
@private
Public Class Methods
new(client)
click to toggle source
# File lib/submodules/ably-ruby/lib/ably/realtime/push.rb, line 10 def initialize(client) @client = client end
Public Instance Methods
activate(*arg)
click to toggle source
Activates the device for push notifications with FCM or APNS, obtaining a unique identifier from them. Subsequently registers the device with Ably
and stores the deviceIdentityToken in local storage.
@spec RSH2a
@note This is unsupported in the Ruby library
# File lib/submodules/ably-ruby/lib/ably/realtime/push.rb, line 31 def activate(*arg) raise_unsupported end
admin()
click to toggle source
A {Ably::Realtime::Push::Admin} object.
@spec RSH1
@return [Ably::Realtime::Push::Admin]
# File lib/submodules/ably-ruby/lib/ably/realtime/push.rb, line 20 def admin @admin ||= Admin.new(self) end
deactivate(*arg)
click to toggle source
Deactivates the device from receiving push notifications with Ably
and FCM or APNS.
@spec RSH2b
@note This is unsupported in the Ruby library
# File lib/submodules/ably-ruby/lib/ably/realtime/push.rb, line 41 def deactivate(*arg) raise_unsupported end
Private Instance Methods
raise_unsupported()
click to toggle source
# File lib/submodules/ably-ruby/lib/ably/realtime/push.rb, line 47 def raise_unsupported raise Ably::Exceptions::PushNotificationsNotSupported, 'This device does not support receiving or subscribing to push notifications. All PushChannel methods are unavailable' end