Sha256: 12f533dcfb7a65a982002fd3551decee4b62a8ef1dd161035c35429e89b3f0b4

Contents?: true

Size: 722 Bytes

Versions: 3

Compression:

Stored size: 722 Bytes

Contents

# frozen_string_literal: true

require_relative 'immutable_object'

module Upgrow
  # An Error is an all-purpose object that represents a failure in the
  # performance of an Action. Errors are present in failure Results.
  #
  # Error contains a code, which is a machine-friendly unique key that
  # represents the type of error returned. Error also contain a message, which
  # is the human-readable text explaining the particular failure that happened.
  # Optinally Error might also have an attribute value, which is the attribute
  # that caused the failure, in case the error was originated from an Input.
  class Error < ImmutableObject
    attribute :code
    attribute :message
    attribute :attribute
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
upgrow-0.0.5 lib/upgrow/error.rb
upgrow-0.0.4 lib/upgrow/error.rb
upgrow-0.0.3 lib/upgrow/error.rb