Contents

requestOwnership(timeout:_:)

Requests ownership of the entity.

Declaration

@MainActor @preconcurrency func requestOwnership(timeout: TimeInterval = 15, _ callback: @escaping (SynchronizationComponent.OwnershipTransferCompletionResult) -> Void)

Parameters

  • timeout:

    A time in seconds to wait before giving up.

  • callback:

    A closure that the method calls when the request completes or times out.

Discussion

Requesting ownership isn’t guaranteed to succeed.

See Also

Managing ownership