Sha256: 8adf225e10b1039c8546229da5456ff706711fea02861b0f378ec244c2c62e51

Contents?: true

Size: 587 Bytes

Versions: 2

Compression:

Stored size: 587 Bytes

Contents

require_relative 'cache/cacher'

module RenuoCmsRails
  module Cache
    @cache = Cacher.new(RenuoCmsRails::API)

    attr_reader :cache

    # Initializes the cache. This will connect via HTTPS to the configured CMS host, so make sure that the host is
    # configured prior to calling this method.
    delegate :initialize_cache, to: :cache

    # Gets the content if the content with the content_path is in the cache, nil otherwise.
    # @param [String] content_path
    # @return [String]
    delegate :get, to: :cache

    module_function :cache, :get, :initialize_cache
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
renuo-cms-rails-0.2.1 lib/renuo_cms_rails/cache.rb
renuo-cms-rails-0.2.0 lib/renuo_cms_rails/cache.rb