Class: YandexMetrica::Counter::Kind
- Inherits:
-
Object
- Object
- YandexMetrica::Counter::Kind
- Defined in:
- lib/yandex-metrica/counter/kind.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(name, value) ⇒ Kind
constructor
A new instance of Kind.
- #to_s ⇒ Object
Constructor Details
#initialize(name, value) ⇒ Kind
Returns a new instance of Kind.
4 5 6 |
# File 'lib/yandex-metrica/counter/kind.rb', line 4 def initialize(name, value) @name, @value = name, value end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
3 4 5 |
# File 'lib/yandex-metrica/counter/kind.rb', line 3 def name @name end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
3 4 5 |
# File 'lib/yandex-metrica/counter/kind.rb', line 3 def value @value end |
Instance Method Details
#to_s ⇒ Object
8 9 10 |
# File 'lib/yandex-metrica/counter/kind.rb', line 8 def to_s "#{@name}:#{@value}" end |