Sha256: 4b8ab28f2c290258588cdd58bc2bc9f4a353484f858a7a2e2ba333fe99f7fc00

Contents?: true

Size: 1.07 KB

Versions: 1

Compression:

Stored size: 1.07 KB

Contents

module Sidetree
  module OP
    module Type
      CREATE = "create"
      UPDATE = "update"
      RECOVER = "recover"
      DEACTIVATE = "deactivate"
    end

    # Sidetree patch actions. These are the valid values in the action property of a patch.
    module PatchAction
      REPLACE = "replace"
      ADD_PUBLIC_KEYS = "add-public-keys"
      REMOVE_PUBLIC_KEYS = "remove-public-keys"
      ADD_SERVICES = "add-services"
      REMOVE_SERVICES = "remove-services"
    end

    # DID Document public key purpose.
    module PublicKeyPurpose
      AUTHENTICATION = "authentication"
      ASSERTION_METHOD = "assertionMethod"
      CAPABILITY_INVOCATION = "capabilityInvocation"
      CAPABILITY_DELEGATION = "capabilityDelegation"
      KEY_AGREEMENT = "keyAgreement"

      module_function

      def values
        PublicKeyPurpose.constants.map { |c| PublicKeyPurpose.const_get(c) }
      end
    end

    autoload :Base, "sidetree/op/base"
    autoload :Create, "sidetree/op/create"
    autoload :Recover, "sidetree/op/recover"
    autoload :Deactivate, "sidetree/op/deactivate"
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sidetree-0.1.1 lib/sidetree/op.rb