Exception: ActiveFacts::API::DuplicateIdentifyingValueException
- Inherits:
-
RuntimeException
- Object
- StandardError
- ActiveFactsException
- RuntimeException
- ActiveFacts::API::DuplicateIdentifyingValueException
- Defined in:
- lib/activefacts/api/exceptions.rb
Instance Method Summary collapse
-
#initialize(klass, role_name, value) ⇒ DuplicateIdentifyingValueException
constructor
A new instance of DuplicateIdentifyingValueException.
Constructor Details
#initialize(klass, role_name, value) ⇒ DuplicateIdentifyingValueException
Returns a new instance of DuplicateIdentifyingValueException.
85 86 87 88 89 |
# File 'lib/activefacts/api/exceptions.rb', line 85 def initialize(klass, role_name, value) super("Illegal attempt to assert #{klass.basename} having identifying value" + " (#{role_name} is #{value.verbalise})," + " when #{value.respond_to?(:related_entities) ? value.(false).map(&:verbalise).join(", ") : 'an equivalent entity'} already exists") end |