Class: AnyCache Private

Inherits:
Object
  • Object
show all
Includes:
Delegation, Qonfig::Configurable
Defined in:
lib/any_cache.rb,
lib/any_cache/error.rb,
lib/any_cache/version.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Since:

  • 0.1.0

Defined Under Namespace

Modules: Adapters, Delegation, Drivers, Logging

Constant Summary collapse

Error =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Since:

  • 0.1.0

Class.new(StandardError)
UnsupportedDriverError =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Since:

  • 0.1.0

Class.new(Error)
VERSION =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Since:

  • 0.1.0

'0.3.0'

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Delegation

included

Constructor Details

#initialize(adapter) ⇒ void

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Parameters:

Since:

  • 0.1.0



109
110
111
# File 'lib/any_cache.rb', line 109

def initialize(adapter)
  @adapter = adapter
end

Instance Attribute Details

#adapterAnyCache::Adapters::Basic (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns:

Since:

  • 0.1.0



102
103
104
# File 'lib/any_cache.rb', line 102

def adapter
  @adapter
end

Class Method Details

.build(driver = Drivers.build(config)) ⇒ AnyCache

Parameters:

  • driver (Object) (defaults to: Drivers.build(config))

Returns:

Since:

  • 0.1.0



75
76
77
# File 'lib/any_cache.rb', line 75

def build(driver = Drivers.build(config))
  new(Adapters.build(driver))
end