updateObject method

void updateObject(
  1. Map<String, dynamic> data
)

UpdateObject

update the object referred to by object.

Add or replace an existing object. You must set the objectID attribute to indicate the object to update. Equivalent to Add/update an object by ID.

Implementation

void updateObject(Map<String, dynamic> data) {
  if (!_committed) {
    _actions.add(AlgoliaBatchRequest(action: 'updateObject', body: data));
  } else {
    throw StateError(
        'This batch has been committed and can no longer be changed.');
  }
}