Class: RaccMatchParser::MatchLine
- Inherits:
-
Struct
- Object
- Struct
- RaccMatchParser::MatchLine
- Defined in:
- lib/sportdb/parser.rb
Instance Attribute Summary collapse
-
#date ⇒ Object
Returns the value of attribute date.
-
#geo ⇒ Object
Returns the value of attribute geo.
-
#ord ⇒ Object
Returns the value of attribute ord.
-
#score ⇒ Object
Returns the value of attribute score.
-
#team1 ⇒ Object
Returns the value of attribute team1.
-
#team2 ⇒ Object
Returns the value of attribute team2.
-
#time ⇒ Object
Returns the value of attribute time.
Instance Method Summary collapse
Instance Attribute Details
#date ⇒ Object
Returns the value of attribute date
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def date @date end |
#geo ⇒ Object
Returns the value of attribute geo
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def geo @geo end |
#ord ⇒ Object
Returns the value of attribute ord
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def ord @ord end |
#score ⇒ Object
Returns the value of attribute score
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def score @score end |
#team1 ⇒ Object
Returns the value of attribute team1
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def team1 @team1 end |
#team2 ⇒ Object
Returns the value of attribute team2
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def team2 @team2 end |
#time ⇒ Object
Returns the value of attribute time
236 237 238 |
# File 'lib/sportdb/parser.rb', line 236 def time @time end |
Instance Method Details
#pretty_print(printer) ⇒ Object
240 241 242 243 244 245 246 247 248 249 250 251 252 253 |
# File 'lib/sportdb/parser.rb', line 240 def pretty_print( printer ) printer.text( "<MatchLine " ) printer.text( "#{self.team1} v #{self.team2}") printer.breakable members.zip(values) do |name, value| next if [:team1, :team2].include?( name ) next if value.nil? printer.text( "#{name}=#{value.pretty_inspect}" ) end printer.text( ">" ) end |