Class: Sequencescape::Api::Associations::BelongsTo::AssociationProxy

Inherits:
Sequencescape::Api::Associations::Base show all
Includes:
CommonBehaviour
Defined in:
lib/sequencescape-api/associations/belongs_to.rb

Instance Method Summary collapse

Methods included from CommonBehaviour

#as_json, included, #respond_to?

Methods included from Sequencescape::Api::Associations::Base::InstanceMethods

included, #proxy_present?

Constructor Details

#initialize(*args, &block) ⇒ AssociationProxy

Returns a new instance of AssociationProxy.



87
88
89
90
# File 'lib/sequencescape-api/associations/belongs_to.rb', line 87

def initialize(*args, &block)
  super
  @loaded = false
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Sequencescape::Api::Associations::BelongsTo::CommonBehaviour

Instance Method Details

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


107
108
109
# File 'lib/sequencescape-api/associations/belongs_to.rb', line 107

def eql?(other)
  uuid == other.uuid
end

#uuid_only?Boolean

Returns:

  • (Boolean)


101
102
103
# File 'lib/sequencescape-api/associations/belongs_to.rb', line 101

def uuid_only?
  @object.__send__(:uuid_only?)
end