Exception: ViewModel::DeserializationError::DuplicateOwner
- Inherits:
-
InvalidRequest
- Object
- StandardError
- AbstractError
- AbstractErrorWithBlame
- ViewModel::DeserializationError
- InvalidRequest
- ViewModel::DeserializationError::DuplicateOwner
- Defined in:
- lib/view_model/deserialization_error.rb
Instance Attribute Summary collapse
-
#association_name ⇒ Object
readonly
Returns the value of attribute association_name.
Attributes inherited from AbstractErrorWithBlame
Instance Method Summary collapse
- #detail ⇒ Object
-
#initialize(association_name, parents) ⇒ DuplicateOwner
constructor
A new instance of DuplicateOwner.
Methods inherited from ViewModel::DeserializationError
Methods inherited from AbstractErrorWithBlame
Methods inherited from AbstractError
#aggregation?, #causes, #code, #exception, #meta, #status, #title, #to_s, #view
Constructor Details
#initialize(association_name, parents) ⇒ DuplicateOwner
Returns a new instance of DuplicateOwner.
251 252 253 254 |
# File 'lib/view_model/deserialization_error.rb', line 251 def initialize(association_name, parents) @association_name = association_name super(parents) end |
Instance Attribute Details
#association_name ⇒ Object (readonly)
Returns the value of attribute association_name.
249 250 251 |
# File 'lib/view_model/deserialization_error.rb', line 249 def association_name @association_name end |
Instance Method Details
#detail ⇒ Object
256 257 258 |
# File 'lib/view_model/deserialization_error.rb', line 256 def detail "Multiple parents attempted to claim the same owned '#{association_name}' reference: " + nodes.map(&:to_s).join(', ') end |