put method

  1. @override
Future<Id> put(
  1. OBJ object
)
override

Insert or update an object. Returns the id of the new or updated object.

If the object has an non-final id property, it will be set to the assigned id. Otherwise you should use the returned id to update the object.

Implementation

@override
Future<Id> put(OBJ object) {
  return _spanHelper.asyncWrapInSpan(
    'put',
    () {
      return _isarCollection.put(object);
    },
    dbName: _dbName,
    collectionName: name,
  );
}