| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 | 41 |
| 42 IDBIndex::IDBIndex(const IDBIndexMetadata& metadata, IDBObjectStore* objectStore
, IDBTransaction* transaction) | 42 IDBIndex::IDBIndex(const IDBIndexMetadata& metadata, IDBObjectStore* objectStore
, IDBTransaction* transaction) |
| 43 : m_metadata(metadata) | 43 : m_metadata(metadata) |
| 44 , m_objectStore(objectStore) | 44 , m_objectStore(objectStore) |
| 45 , m_transaction(transaction) | 45 , m_transaction(transaction) |
| 46 , m_deleted(false) | 46 , m_deleted(false) |
| 47 { | 47 { |
| 48 ASSERT(m_objectStore); | 48 ASSERT(m_objectStore); |
| 49 ASSERT(m_transaction); | 49 ASSERT(m_transaction); |
| 50 ASSERT(m_metadata.id != IDBIndexMetadata::InvalidId); | 50 ASSERT(m_metadata.id != IDBIndexMetadata::InvalidId); |
| 51 ScriptWrappable::init(this); |
| 51 } | 52 } |
| 52 | 53 |
| 53 IDBIndex::~IDBIndex() | 54 IDBIndex::~IDBIndex() |
| 54 { | 55 { |
| 55 } | 56 } |
| 56 | 57 |
| 57 PassRefPtr<IDBRequest> IDBIndex::openCursor(ScriptExecutionContext* context, Pas
sRefPtr<IDBKeyRange> keyRange, const String& directionString, ExceptionCode& ec) | 58 PassRefPtr<IDBRequest> IDBIndex::openCursor(ScriptExecutionContext* context, Pas
sRefPtr<IDBKeyRange> keyRange, const String& directionString, ExceptionCode& ec) |
| 58 { | 59 { |
| 59 IDB_TRACE("IDBIndex::openCursor"); | 60 IDB_TRACE("IDBIndex::openCursor"); |
| 60 if (m_deleted) { | 61 if (m_deleted) { |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 199 backendDB()->get(m_transaction->id(), m_objectStore->id(), m_metadata.id, ke
yRange, true, request); | 200 backendDB()->get(m_transaction->id(), m_objectStore->id(), m_metadata.id, ke
yRange, true, request); |
| 200 return request; | 201 return request; |
| 201 } | 202 } |
| 202 | 203 |
| 203 IDBDatabaseBackendInterface* IDBIndex::backendDB() const | 204 IDBDatabaseBackendInterface* IDBIndex::backendDB() const |
| 204 { | 205 { |
| 205 return m_transaction->backendDB(); | 206 return m_transaction->backendDB(); |
| 206 } | 207 } |
| 207 | 208 |
| 208 } // namespace WebCore | 209 } // namespace WebCore |
| OLD | NEW |