Sha256: 6e9fd9c5d7627b64e4cdd57648cc5678ae866ef35656be6bee4df57060655b17

Contents?: true

Size: 717 Bytes

Versions: 12

Compression:

Stored size: 717 Bytes

Contents

require 'representable/json'
require 'ostruct'

module Consul
  module Model

    # Consul Key Value representation
    #
    # Reference: https://www.consul.io/intro/getting-started/kv.html
    #
    class KeyValue < OpenStruct
      module Representer
        include Representable::JSON
        include Representable::Hash
        include Representable::Hash::AllowSymbols

        property :create_index, as: :CreateIndex
        property :modify_index, as: :ModifyIndex
        property :lock_index, as: :LockIndex
        property :key, as: :Key
        property :flags, as: :Flags
        property :value, as: :Value
        property :session, as: :Session
      end
      extend Representer
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
consul-ruby-client-0.0.13 lib/consul/model/key_value.rb
consul-ruby-client-0.0.12 lib/consul/model/key_value.rb
consul-ruby-client-0.0.11 lib/consul/model/key_value.rb
consul-ruby-client-0.0.10 lib/consul/model/key_value.rb
consul-ruby-client-0.0.9 lib/consul/model/key_value.rb
consul-ruby-client-0.0.8 lib/consul/model/key_value.rb
consul-ruby-client-0.0.7 lib/consul/model/key_value.rb
consul-ruby-client-0.0.6 lib/consul/model/key_value.rb
consul-ruby-client-0.0.5 lib/consul/model/key_value.rb
consul-ruby-client-0.0.4 lib/consul/model/key_value.rb
consul-ruby-client-0.0.3 lib/consul/model/key_value.rb
consul-ruby-client-0.0.2 lib/consul/model/key_value.rb