Class: Redis::TimeSeries::Filters::Absent

Inherits:
Struct
  • Object
show all
Defined in:
lib/redis/time_series/filters.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#labelObject

Returns the value of attribute label

Returns:

  • (Object)

    the current value of label



37
38
39
# File 'lib/redis/time_series/filters.rb', line 37

def label
  @label
end

Class Method Details

.parse(str) ⇒ Object



40
41
42
# File 'lib/redis/time_series/filters.rb', line 40

def self.parse(str)
  new(str.delete('='))
end

Instance Method Details

#to_hObject



44
45
46
# File 'lib/redis/time_series/filters.rb', line 44

def to_h
  { label => false }
end

#to_sObject



48
49
50
# File 'lib/redis/time_series/filters.rb', line 48

def to_s
  "#{label}="
end