void IDBConnectionProxy::registerDatabaseConnection(IDBDatabase& database) { Locker<Lock> locker(m_databaseConnectionMapLock); ASSERT(!m_databaseConnectionMap.contains(database.databaseConnectionIdentifier())); m_databaseConnectionMap.set(database.databaseConnectionIdentifier(), &database); }
void IDBConnectionProxy::unregisterDatabaseConnection(IDBDatabase& database) { Locker<Lock> locker(m_databaseConnectionMapLock); ASSERT(!m_databaseConnectionMap.contains(database.databaseConnectionIdentifier()) || m_databaseConnectionMap.get(database.databaseConnectionIdentifier()) == &database); m_databaseConnectionMap.remove(database.databaseConnectionIdentifier()); }
void IDBConnectionProxy::confirmDidCloseFromServer(IDBDatabase& database) { callConnectionOnMainThread(&IDBConnectionToServer::confirmDidCloseFromServer, database.databaseConnectionIdentifier()); }
void IDBConnectionProxy::databaseConnectionClosed(IDBDatabase& database) { callConnectionOnMainThread(&IDBConnectionToServer::databaseConnectionClosed, database.databaseConnectionIdentifier()); }
void IDBConnectionToServer::unregisterDatabaseConnection(IDBDatabase& database) { ASSERT(m_databaseConnectionMap.contains(database.databaseConnectionIdentifier())); ASSERT(m_databaseConnectionMap.get(database.databaseConnectionIdentifier()) == &database); m_databaseConnectionMap.remove(database.databaseConnectionIdentifier()); }
void IDBConnectionToServer::registerDatabaseConnection(IDBDatabase& database) { ASSERT(!m_databaseConnectionMap.contains(database.databaseConnectionIdentifier())); m_databaseConnectionMap.set(database.databaseConnectionIdentifier(), &database); }
void IDBConnectionToServer::databaseConnectionClosed(IDBDatabase& database) { LOG(IndexedDB, "IDBConnectionToServer::databaseConnectionClosed"); m_delegate->databaseConnectionClosed(database.databaseConnectionIdentifier()); }