Class: VoiceML::NotificationsList

Inherits:
Object
  • Object
show all
Defined in:
lib/voiceml/models/diagnostics.rb

Overview

‘GET /Calls/Sid/Notifications` — always an empty list (Twilio-compat stub).

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(hash = {}) ⇒ NotificationsList

Returns a new instance of NotificationsList.



10
11
12
13
14
15
16
# File 'lib/voiceml/models/diagnostics.rb', line 10

def initialize(hash = {})
  @notifications = hash['notifications'] || []
  @page          = hash['page']     || 0
  @page_size     = hash['page_size'] || 0
  @total         = hash['total']    || 0
  @uri           = hash['uri']
end

Instance Attribute Details

#notificationsObject (readonly)

Returns the value of attribute notifications.



8
9
10
# File 'lib/voiceml/models/diagnostics.rb', line 8

def notifications
  @notifications
end

#pageObject (readonly)

Returns the value of attribute page.



8
9
10
# File 'lib/voiceml/models/diagnostics.rb', line 8

def page
  @page
end

#page_sizeObject (readonly)

Returns the value of attribute page_size.



8
9
10
# File 'lib/voiceml/models/diagnostics.rb', line 8

def page_size
  @page_size
end

#totalObject (readonly)

Returns the value of attribute total.



8
9
10
# File 'lib/voiceml/models/diagnostics.rb', line 8

def total
  @total
end

#uriObject (readonly)

Returns the value of attribute uri.



8
9
10
# File 'lib/voiceml/models/diagnostics.rb', line 8

def uri
  @uri
end

Class Method Details

.from_hash(hash) ⇒ Object



18
19
20
# File 'lib/voiceml/models/diagnostics.rb', line 18

def self.from_hash(hash)
  new(hash || {})
end