assignOwnership method Null safety
- String source,
- TikiSdkDataTypeEnum type,
- List<
String> contains, - {String? about,
- String? origin}
Assign ownership to a given source
.
The type
identifies which TikiSdkDataTypeEnum the ownership refers to.
The list of items the data contains is described by contains
. Optionally,
a description about this ownership can be giben in about
and the origin
can be overridden for the specific ownership grant.
It returns a base64 url-safe representation of the OwnershipModel.transactionId.
Implementation
Future<String> assignOwnership(
String source, TikiSdkDataTypeEnum type, List<String> contains,
{String? about, String? origin}) async {
OwnershipModel ownershipModel = await _ownershipService.create(
source: source,
type: type,
origin: origin,
about: about,
contains: contains);
return Bytes.base64UrlEncode(ownershipModel.transactionId!);
}