Sha256: dd8edbb85c82883375fe3e847569cfe066f9f492d311b9423cef2d613f7ad5d0

Contents?: true

Size: 584 Bytes

Versions: 9

Compression:

Stored size: 584 Bytes

Contents

# frozen_string_literal: true

require 'active_support/core_ext/module/delegation'

require_relative 'entry/keypath'
require_relative 'entry/value'

class ActiveSet
  class Instructions
    class Entry
      attr_reader :keypath

      delegate :path, :attribute, :operator, :associations_array,
               :associations_hash, :value_for, :resource_for, :titleized,
               to: :keypath

      def initialize(keypath, value)
        @keypath = KeyPath.new(keypath)
        @value = Value.new(value)
      end

      def value
        @value.raw
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
activeset-0.5.8 lib/active_set/instructions/entry.rb
activeset-0.5.7 lib/active_set/instructions/entry.rb
activeset-0.5.6 lib/active_set/instructions/entry.rb
activeset-0.5.5 lib/active_set/instructions/entry.rb
activeset-0.5.4 lib/active_set/instructions/entry.rb
activeset-0.5.3 lib/active_set/instructions/entry.rb
activeset-0.5.2 lib/active_set/instructions/entry.rb
activeset-0.5.1 lib/active_set/instructions/entry.rb
activeset-0.5.0 lib/active_set/instructions/entry.rb