Class: YandexMetrica::Counter::Kind

Inherits:
Object
  • Object
show all
Defined in:
lib/yandex-metrica/counter/kind.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

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

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/yandex-metrica/counter/kind.rb', line 3

def name
  @name
end

#valueObject (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_sObject



8
9
10
# File 'lib/yandex-metrica/counter/kind.rb', line 8

def to_s
  "#{@name}:#{@value}"
end