DatabaseFuture
public class DatabaseFuture<Value>A future database value, returned by the DatabaseWriter.concurrentRead(_:) method.
let futureCount: Future<Int> = try writer.writeWithoutTransaction { db in
    try Player(...).insert()
    // Count players concurrently
    return writer.concurrentRead { db in
        return try Player.fetchCount()
    }
}
let count: Int = try futureCount.wait()
- 
                  
                  Blocks the current thread until the value is available, and returns it. It is a programmer error to call this method several times. Throws Any error that prevented the value from becoming available.DeclarationSwift public func wait() throws -> Value
 View on GitHub
View on GitHub Install in Dash
Install in Dash DatabaseFuture Class Reference
        DatabaseFuture Class Reference