Class: TF2LineParser::Player
- Inherits:
-
Object
- Object
- TF2LineParser::Player
- Defined in:
- lib/tf2_line_parser/player.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#steam_id ⇒ Object
Returns the value of attribute steam_id.
-
#team ⇒ Object
Returns the value of attribute team.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name, steam_id, team) ⇒ Player
constructor
A new instance of Player.
Constructor Details
#initialize(name, steam_id, team) ⇒ Player
Returns a new instance of Player.
7 8 9 10 11 |
# File 'lib/tf2_line_parser/player.rb', line 7 def initialize(name, steam_id, team) @name = name @steam_id = steam_id @team = team end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
5 6 7 |
# File 'lib/tf2_line_parser/player.rb', line 5 def name @name end |
#steam_id ⇒ Object
Returns the value of attribute steam_id.
5 6 7 |
# File 'lib/tf2_line_parser/player.rb', line 5 def steam_id @steam_id end |
#team ⇒ Object
Returns the value of attribute team.
5 6 7 |
# File 'lib/tf2_line_parser/player.rb', line 5 def team @team end |
Instance Method Details
#==(other) ⇒ Object
13 14 15 |
# File 'lib/tf2_line_parser/player.rb', line 13 def ==(other) steam_id == other.steam_id end |