Class: Flipper::Adapters::Poll

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Includes:
Flipper::Adapter
Defined in:
lib/flipper/adapters/poll.rb

Constant Summary collapse

Poller =

Deprecated

::Flipper::Poller

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Flipper::Adapter

#default_config, #export, #get_all, #get_multi, #import, included, #name, #read_only?

Constructor Details

#initialize(poller, adapter) ⇒ Poll

Returns a new instance of Poll.



17
18
19
20
21
22
# File 'lib/flipper/adapters/poll.rb', line 17

def initialize(poller, adapter)
  @adapter = adapter
  @poller = poller
  @last_synced_at = 0
  @poller.start
end

Instance Attribute Details

#adapterObject (readonly)

Returns the value of attribute adapter.



13
14
15
# File 'lib/flipper/adapters/poll.rb', line 13

def adapter
  @adapter
end

#pollerObject (readonly)

Returns the value of attribute poller.



13
14
15
# File 'lib/flipper/adapters/poll.rb', line 13

def poller
  @poller
end