Class: Tweetkit::Response::Tweets::Expansions::Polls::Poll

Inherits:
Object
  • Object
show all
Defined in:
lib/tweetkit/response.rb

Defined Under Namespace

Classes: Options

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(poll) ⇒ Poll

Returns a new instance of Poll.



491
492
493
494
# File 'lib/tweetkit/response.rb', line 491

def initialize(poll)
  @id = poll['id']
  @options = Options.new(poll['options'])
end

Instance Attribute Details

#idObject

Returns the value of attribute id.



489
490
491
# File 'lib/tweetkit/response.rb', line 489

def id
  @id
end

#optionsObject

Returns the value of attribute options.



489
490
491
# File 'lib/tweetkit/response.rb', line 489

def options
  @options
end