Class: FbGraph::Score
Instance Attribute Summary collapse
-
#application ⇒ Object
Returns the value of attribute application.
-
#score ⇒ Object
Returns the value of attribute score.
-
#user ⇒ Object
Returns the value of attribute user.
Attributes inherited from Node
#access_token, #endpoint, #identifier, #raw_attributes
Instance Method Summary collapse
-
#initialize(identifier, attributes = {}) ⇒ Score
constructor
A new instance of Score.
Methods inherited from Node
#connection, #destroy, fetch, #fetch, #update
Methods included from Comparison
Constructor Details
#initialize(identifier, attributes = {}) ⇒ Score
Returns a new instance of Score.
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/fb_graph/score.rb', line 5 def initialize(identifier, attributes = {}) super if user = attributes[:user] @user = User.new(user[:id], user) end if app = attributes[:application] @application = Application.new(app[:id], app) end @score = attributes[:score] end |
Instance Attribute Details
#application ⇒ Object
Returns the value of attribute application.
3 4 5 |
# File 'lib/fb_graph/score.rb', line 3 def application @application end |
#score ⇒ Object
Returns the value of attribute score.
3 4 5 |
# File 'lib/fb_graph/score.rb', line 3 def score @score end |
#user ⇒ Object
Returns the value of attribute user.
3 4 5 |
# File 'lib/fb_graph/score.rb', line 3 def user @user end |