Class: VoiceML::AssistantsV1MessageList

Inherits:
Object
  • Object
show all
Includes:
V1Pageable
Defined in:
lib/voiceml/models/assistants_v1.rb

Constant Summary

Constants included from V1Pageable

V1Pageable::META_FIELDS

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from V1Pageable

#assign_meta_fields

Constructor Details

#initialize(hash = {}) ⇒ AssistantsV1MessageList

Returns a new instance of AssistantsV1MessageList.



178
179
180
181
# File 'lib/voiceml/models/assistants_v1.rb', line 178

def initialize(hash = {})
  assign_meta_fields(hash)
  @messages = (hash['messages'] || []).map { |h| AssistantsV1Message.from_hash(h) }
end

Instance Attribute Details

#messagesObject (readonly)

Returns the value of attribute messages.



177
178
179
# File 'lib/voiceml/models/assistants_v1.rb', line 177

def messages
  @messages
end