Sha256: 32be1cc8896af65b576dcd3dccc055545074f3e8419186c8285609c8770f10fd

Contents?: true

Size: 437 Bytes

Versions: 12

Compression:

Stored size: 437 Bytes

Contents

# frozen_string_literal: true
module ActiveTriples
  class Configuration
    # Basic configuration item which overrides the value for a key on the object.
    class Item
      attr_reader :object, :key
      def initialize(object, key)
        @object = object
        @key = key
      end

      def value
        object.inner_hash[key]
      end

      def set(value)
        object.inner_hash[key] = value
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
active-triples-1.2.0 lib/active_triples/configuration/item.rb
active-triples-1.1.1 lib/active_triples/configuration/item.rb
active-triples-1.1.0 lib/active_triples/configuration/item.rb
active-triples-1.0.0 lib/active_triples/configuration/item.rb
active-triples-1.0.0.rc1 lib/active_triples/configuration/item.rb
active-triples-0.11.0 lib/active_triples/configuration/item.rb
active-triples-0.10.2 lib/active_triples/configuration/item.rb
active-triples-0.10.1 lib/active_triples/configuration/item.rb
active-triples-0.10.0 lib/active_triples/configuration/item.rb
active-triples-0.9.0 lib/active_triples/configuration/item.rb
active-triples-0.8.3 lib/active_triples/configuration/item.rb
active-triples-0.8.2 lib/active_triples/configuration/item.rb