Class: Gecko::Pusher::Channel::Number

Inherits:
Base
  • Object
show all
Defined in:
lib/gecko-pusher/channel/number.rb

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Gecko::Pusher::Channel::Base

Instance Method Details

#push(*args) ⇒ Object



6
7
8
9
10
11
12
# File 'lib/gecko-pusher/channel/number.rb', line 6

def push(*args)
  options = extract_options(args)
  data = {item: extract_values(args)}
  data[:type] = options[:type] unless options[:type].nil?
  data[:absolute] = options[:absolute] unless options[:absolute].nil?
  _push(data)
end