class PollAnswer
This object represents an answer of a user in a non-anonymous poll.¶ ↑
Public Instance Methods
option_ids()
click to toggle source
0-based identifiers of answer options, chosen by the user. May be empty if the user retracted their vote.
# File lib/objects/poll_answer.rb, line 26 def option_ids @poll.option_ids end
poll_id()
click to toggle source
Unique poll identifier.
# File lib/objects/poll_answer.rb, line 15 def poll_id @poll.poll_id end
user()
click to toggle source
The user, who changed the answer to the poll. Return User
object
# File lib/objects/poll_answer.rb, line 20 def user User.new(@poll.user) end