update abstract method
Future<Map<String, dynamic> >
update(
- Map<
String, dynamic> map, - DbPrincipal principal, {
- UpdatePolicy? updatePolicy,
- RepositoryTransaction? transaction,
Update an entity in the collection contained in the map
parameter.
This method expects a principal
parameter, which
identifies the user performing the request. Implementations
are advised to confirm if the entity being updated belongs to
a tenant related to the principal
.
If a non-empty value is passed to the permission
parameter,
the implementation of this method is expected to validate
if the user represented by the principal
does have the
permission before actually updating the entity. Otherwise,
an error is thrown.
Implementation
Future<Map<String, dynamic>> update(
Map<String, dynamic> map,
DbPrincipal principal, {
UpdatePolicy? updatePolicy,
RepositoryTransaction? transaction,
});