Class: FootStats::Live::Card

Inherits:
Object
  • Object
show all
Defined in:
lib/foot_stats/live_card.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params) ⇒ Card

Returns a new instance of Card.



6
7
8
9
10
11
# File 'lib/foot_stats/live_card.rb', line 6

def initialize(params)
  @player_name = params['@Jogador']
  @period      = params['@Periodo']
  @minute      = params['@Minuto'].to_i
  @type        = params['@Tipo']
end

Instance Attribute Details

#minuteObject (readonly)

Returns the value of attribute minute.



4
5
6
# File 'lib/foot_stats/live_card.rb', line 4

def minute
  @minute
end

#periodObject (readonly)

Returns the value of attribute period.



4
5
6
# File 'lib/foot_stats/live_card.rb', line 4

def period
  @period
end

#player_nameObject (readonly)

Returns the value of attribute player_name.



4
5
6
# File 'lib/foot_stats/live_card.rb', line 4

def player_name
  @player_name
end

#typeObject (readonly)

Returns the value of attribute type.



4
5
6
# File 'lib/foot_stats/live_card.rb', line 4

def type
  @type
end