Module: Elastictastic::Dirty::EmbeddedDocumentMethods

Defined in:
lib/elastictastic/dirty.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#nesting_association=(value) ⇒ Object (writeonly)

Sets the attribute nesting_association

Parameters:

  • value

    the value to set the attribute nesting_association to.



106
107
108
# File 'lib/elastictastic/dirty.rb', line 106

def nesting_association=(value)
  @nesting_association = value
end

#nesting_document=(value) ⇒ Object (writeonly)

Sets the attribute nesting_document

Parameters:

  • value

    the value to set the attribute nesting_document to.



106
107
108
# File 'lib/elastictastic/dirty.rb', line 106

def nesting_document=(value)
  @nesting_document = value
end

Instance Method Details

#attribute_may_change!(field) ⇒ Object



108
109
110
111
112
113
114
115
116
# File 'lib/elastictastic/dirty.rb', line 108

def attribute_may_change!(field)
  if @nesting_document
    @nesting_document.attribute_may_change!(@nesting_association) do
      super
    end
  else
    super
  end
end