Class: Plivo::Row

Inherits:
Object
  • Object
show all
Defined in:
lib/plivo/interactive.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id: nil, title: nil, description: nil) ⇒ Row



125
126
127
128
129
# File 'lib/plivo/interactive.rb', line 125

def initialize(id: nil, title: nil, description: nil)
  @id = id
  @title = title
  @description = description
end

Instance Attribute Details

#descriptionObject

Returns the value of attribute description.



123
124
125
# File 'lib/plivo/interactive.rb', line 123

def description
  @description
end

#idObject

Returns the value of attribute id.



123
124
125
# File 'lib/plivo/interactive.rb', line 123

def id
  @id
end

#titleObject

Returns the value of attribute title.



123
124
125
# File 'lib/plivo/interactive.rb', line 123

def title
  @title
end

Instance Method Details

#to_hashObject



131
132
133
134
135
136
137
# File 'lib/plivo/interactive.rb', line 131

def to_hash
  {
    id: @id,
    title: @title,
    description: @description
  }.reject { |_, v| v.nil? }
end