Generic Function

withTransaction(_:_:)

Executes a closure with this transaction set as the thread’s current transaction and returns the result.

Declaration

func withTransaction<Result>(_ transaction: Transaction, _ body: () throws -> Result) rethrows -> Result