예제 #1
0
IDBResultData IDBResultData::openDatabaseSuccess(const IDBResourceIdentifier& requestIdentifier, IDBServer::UniqueIDBDatabaseConnection& connection)
{
    IDBResultData result(requestIdentifier);
    result.m_type = IDBResultType::OpenDatabaseSuccess;
    result.m_databaseConnectionIdentifier = connection.identifier();
    result.m_databaseInfo = std::make_unique<IDBDatabaseInfo>(connection.database().info());
    return WTF::move(result);
}
예제 #2
0
void InProcessIDBServer::fireVersionChangeEvent(IDBServer::UniqueIDBDatabaseConnection& connection, uint64_t requestedVersion)
{
    RefPtr<InProcessIDBServer> self(this);
    uint64_t databaseConnectionIdentifier = connection.identifier();
    RunLoop::current().dispatch([this, self, databaseConnectionIdentifier, requestedVersion] {
        m_connectionToServer->fireVersionChangeEvent(databaseConnectionIdentifier, requestedVersion);
    });
}