Class: Stew::Community::SteamId
- Inherits:
-
Object
- Object
- Stew::Community::SteamId
- Defined in:
- lib/stew/community/steam_id.rb
Overview
The base class for all Steam Ids. Has accessors for the base profile, games and friends of a Steam Id
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Instance Method Summary collapse
- #friends ⇒ Object
- #games ⇒ Object
-
#initialize(data, opts = {}) ⇒ SteamId
constructor
A new instance of SteamId.
- #profile ⇒ Object
Constructor Details
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
14 15 16 |
# File 'lib/stew/community/steam_id.rb', line 14 def id @id end |
Instance Method Details
#friends ⇒ Object
29 30 31 |
# File 'lib/stew/community/steam_id.rb', line 29 def friends @friends ||= ProfileFriends.new @client.profile_friends(@id) end |
#games ⇒ Object
25 26 27 |
# File 'lib/stew/community/steam_id.rb', line 25 def games @games ||= ProfileGames.new @client.profile_games(@id) end |