revokeOthers method

SealdRevokeResult revokeOthers()

Revokes all recipients besides yourself from this session.

Returns a SealdRevokeResult.

Implementation

SealdRevokeResult revokeOthers() {
  final Pointer<Pointer<NativeSealdRevokeResult>> result =
      calloc<Pointer<NativeSealdRevokeResult>>();
  final Pointer<Pointer<NativeSealdError>> err =
      calloc<Pointer<NativeSealdError>>();

  final int resultCode = _bindings.SealdEncryptionSession_RevokeOthers(
      _ptr.pointer(), result, err);

  if (resultCode != 0) {
    calloc.free(result);
    throw SealdException._fromCPtr(err);
  } else {
    final SealdRevokeResult res = SealdRevokeResult._fromC(result.value);
    calloc.free(result);
    calloc.free(err);
    return res;
  }
}