Class: LedgerSync::ResourceAttribute::Reference::One
- Inherits:
-
LedgerSync::ResourceAttribute::Reference
- Object
- LedgerSync::ResourceAttribute
- LedgerSync::ResourceAttribute::Reference
- LedgerSync::ResourceAttribute::Reference::One
- Defined in:
- lib/ledger_sync/resource_attribute/reference/one.rb
Defined Under Namespace
Modules: Mixin
Instance Attribute Summary
Attributes inherited from LedgerSync::ResourceAttribute
#name, #reference, #type, #value
Instance Method Summary collapse
-
#initialize(name:, to:) ⇒ One
constructor
A new instance of One.
Methods inherited from LedgerSync::ResourceAttribute
#cast, #reference?, #references_many?, #valid_with?
Constructor Details
#initialize(name:, to:) ⇒ One
Returns a new instance of One.
24 25 26 27 28 29 |
# File 'lib/ledger_sync/resource_attribute/reference/one.rb', line 24 def initialize(name:, to:) super( name: name, type: Type::ReferenceOne.new(resource_class: to) ) end |