Method that gets called when a model is changed. This serves
        to do the actual index writing.
353993
def on_commit(self, changes):
        
        if _get_config(self)['enable_indexing'] is False:
            return None

        for wh in self.whoosheers:
            if not wh.auto_update:
                continue
            writer = None
            for change in changes:
                if change[0].__class__ in wh.models:
                    method_name = '{0}_{1}'.format(change[1], change[0].__class__.__name__.lower())
                    method = getattr(wh, method_name, None)
                    if method:
                        if not writer:
                            writer = type(self).get_or_create_index(_get_app(self), wh).\
                                writer(timeout=_get_config(self)['writer_timeout'])
                        method(writer, change[0])
            if writer:
                writer.commit()
522607
def _on_model_save(sender, **kwargs):
    """"""
    instance = kwargs.pop("instance")
    update_fields = kwargs.pop("update_fields")
    for index in instance.search_indexes:
        try:
            _update_search_index(
                instance=instance, index=index, update_fields=update_fields
            )
        except Exception:
            logger.exception("Error handling 'on_save' signal for %s", instance)
678997
@Override
  public final void handleModelChanged(final ReplicationAccMethod pModel) {
    if (this.replicationMethod != null
      && this.replicationMethod.getItsId().equals(pModel.getItsId())) {
      this.replicationMethod = null;
    }
  }
1208626
def _update(self):
        """"""
        self.dataChanged.emit(self.createIndex(0, 0), self.createIndex(
            len(self.collection), len(self.header)))
1208407
def dispatch(self, receiver):
        ''' 

        '''
        super(ColumnDataChangedEvent, self).dispatch(receiver)
        if hasattr(receiver, '_column_data_changed'):
            receiver._column_data_changed(self)
650602
void onItemsChanged(boolean structureChanged) {
        if (!mPreventDispatchingItemsChanged) {
            if (structureChanged) {
                mIsVisibleItemsStale = true;
                mIsActionItemsStale = true;
            }

            dispatchPresenterUpdate(structureChanged);
        } else {
            mItemsChangedWhileDispatchPrevented = true;
        }
    }
246967
private void handleChange(Object propertyId) {

        if (!m_saveBtn.isEnabled()) {
            m_saveBtn.setEnabled(true);
            m_saveExitBtn.setEnabled(true);
        }
        m_model.handleChange(propertyId);

    }
38233
def refresh(self):
        
        self._changed = False
        self.es.indices.refresh(index=self.index)
490235
function (model, options) {
        this._index(model);
        if (!model.collection) model.collection = this;
        if (model.on) model.on('all', this._onModelEvent, this);
    }
1355069
def record_changed?(reflection, record, key)
        record.new_record? ||
          association_foreign_key_changed?(reflection, record, key) ||
          record.will_save_change_to_attribute?(reflection.foreign_key)
      end
727196
@MustBeLocked (ELockType.WRITE)
  protected final void markAsChanged ()
  {
    // Just remember that something changed
    internalSetPendingChanges (true);
    if (internalIsAutoSaveEnabled ())
    {
      // Auto save
      if (_writeToFile ().isSuccess ())
        internalSetPendingChanges (false);
      else
      {
        if (LOGGER.isErrorEnabled ())
          LOGGER.error ("The DAO of class " +
                        getClass ().getName () +
                        " still has pending changes after markAsChanged!");
      }
    }
  }
1128420
protected void onWrappedValueChanged() {
        if (logger.isDebugEnabled()) {
            logger.debug("Wrapped model value has changed; new value is '" + wrappedModel.getValue() + "'");
        }
        setValue(wrappedModel.getValue());
    }
183588
protected void setChangedInLastRequest(final boolean changed) {
		if (isChangedInLastRequest() != changed) {
			InputModel model = getOrCreateComponentModel();
			model.changedInLastRequest = changed;
		}
	}
335952
public void updateIndex(ChangesHolder changes, ChangesHolder parentChanges)
   {
      // pass lists to search manager 
      if (searchManager != null && changes != null)
      {
         try
         {
            searchManager.apply(changes);
         }
         catch (RepositoryException e)
         {
            log.error("Error indexing changes " + e, e);
         }
         catch (IOException e)
         {
            log.error("Error indexing changes " + e, e);
            try
            {
               handler.logErrorChanges(new HashSet<String>(changes.getRemove()), new HashSet<String>(changes
                  .getAddIds()));
            }
            catch (IOException ioe)
            {
               log.warn("Exception occure when errorLog writed. Error log is not complete. " + ioe, ioe);
            }
         }
      }
      // pass lists to parent search manager 
      if (parentSearchManager != null && parentChanges != null)
      {
         try
         {
            parentSearchManager.apply(parentChanges);
         }
         catch (RepositoryException e)
         {
            log.error("Error indexing changes " + e, e);
         }
         catch (IOException e)
         {
            log.error("Error indexing changes " + e, e);
            try
            {
               parentHandler.logErrorChanges(new HashSet<String>(parentChanges.getRemove()), new HashSet<String>(
                  parentChanges.getAddIds()));
            }
            catch (IOException ioe)
            {
               log.warn("Exception occure when errorLog writed. Error log is not complete. " + ioe, ioe);
            }
         }
      }
   }
1287829
function (view) {
			if (this._onTextModelChanged && this._view) {
				this._view.removeEventListener("ModelChanged", this._listener.onTextModelChanged); //$NON-NLS-0$
			}
			this._view = view;
			if (this._onTextModelChanged && this._view) {
				this._view.addEventListener("ModelChanged", this._listener.onTextModelChanged); //$NON-NLS-0$
			}
		}
20016
def refresh(self):
        
        self.client.indices.refresh(index=self.model.search_objects.mapping.index)
838951
protected void onLegendDataChanged() {

        int   legendCount = mLegendList.size();
        float margin = (mGraphWidth / legendCount);
        float currentOffset = 0;

        for (LegendModel model : mLegendList) {
            model.setLegendBounds(new RectF(currentOffset, 0, currentOffset + margin, mLegendHeight));
            currentOffset += margin;
        }

        Utils.calculateLegendInformation(mLegendList, 0, mGraphWidth, mLegendPaint);

        invalidateGlobal();
    }