Class: Sink::Resources::ModelReferencedInParentAndChild
- Inherits:
-
Object
- Object
- Sink::Resources::ModelReferencedInParentAndChild
- Defined in:
- lib/sink/resources/model_referenced_in_parent_and_child.rb,
lib/sink/resources/model_referenced_in_parent_and_child/child.rb
Defined Under Namespace
Classes: Child
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(client:) ⇒ ModelReferencedInParentAndChild
constructor
A new instance of ModelReferencedInParentAndChild.
- #retrieve(opts = {}) ⇒ Sink::Models::ModelReferencedInParentAndChild
Constructor Details
#initialize(client:) ⇒ ModelReferencedInParentAndChild
Returns a new instance of ModelReferencedInParentAndChild.
10 11 12 13 |
# File 'lib/sink/resources/model_referenced_in_parent_and_child.rb', line 10 def initialize(client:) @client = client @child = Sink::Resources::ModelReferencedInParentAndChild::Child.new(client: client) end |
Instance Attribute Details
#child ⇒ Sink::Resources::ModelReferencedInParentAndChild::Child (readonly)
7 8 9 |
# File 'lib/sink/resources/model_referenced_in_parent_and_child.rb', line 7 def child @child end |
Instance Method Details
#retrieve(opts = {}) ⇒ Sink::Models::ModelReferencedInParentAndChild
18 19 20 21 22 23 24 25 |
# File 'lib/sink/resources/model_referenced_in_parent_and_child.rb', line 18 def retrieve(opts = {}) req = { method: :get, path: "/model_referenced_in_parent_and_child", model: Sink::Models::ModelReferencedInParentAndChild } @client.request(req, opts) end |