Class: NotifyUser::Apns

Inherits:
Push
  • Object
show all
Defined in:
app/models/notify_user/apns.rb

Constant Summary collapse

NO_ERROR =
-42
INVALID_TOKEN_ERROR =
8
CONNECTION =
APNConnection.new

Constants inherited from Push

Push::PAYLOAD_LIMIT, Push::SYMBOL_NAMES_SIZE

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(notifications, devices, options) ⇒ Apns

Returns a new instance of Apns.



12
13
14
15
16
17
# File 'app/models/notify_user/apns.rb', line 12

def initialize(notifications, devices, options)
  super(notifications, devices, options)

  @push_options = setup_options
  @devices = devices
end

Instance Attribute Details

#push_optionsObject

Returns the value of attribute push_options.



10
11
12
# File 'app/models/notify_user/apns.rb', line 10

def push_options
  @push_options
end

Instance Method Details

#pushObject



19
20
21
# File 'app/models/notify_user/apns.rb', line 19

def push
  send_notifications
end