| 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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 ~IDBIndex(); | 51 ~IDBIndex(); |
| 52 void trace(Visitor*); | 52 void trace(Visitor*); |
| 53 | 53 |
| 54 // Implement the IDL | 54 // Implement the IDL |
| 55 const String& name() const { return m_metadata.name; } | 55 const String& name() const { return m_metadata.name; } |
| 56 IDBObjectStore* objectStore() const { return m_objectStore.get(); } | 56 IDBObjectStore* objectStore() const { return m_objectStore.get(); } |
| 57 ScriptValue keyPath(ScriptState*) const; | 57 ScriptValue keyPath(ScriptState*) const; |
| 58 bool unique() const { return m_metadata.unique; } | 58 bool unique() const { return m_metadata.unique; } |
| 59 bool multiEntry() const { return m_metadata.multiEntry; } | 59 bool multiEntry() const { return m_metadata.multiEntry; } |
| 60 | 60 |
| 61 PassRefPtrWillBeRawPtr<IDBRequest> openCursor(ExecutionContext*, const Scrip
tValue& key, const String& direction, ExceptionState&); | 61 PassRefPtrWillBeRawPtr<IDBRequest> openCursor(ScriptState*, const ScriptValu
e& key, const String& direction, ExceptionState&); |
| 62 PassRefPtrWillBeRawPtr<IDBRequest> openKeyCursor(ExecutionContext*, const Sc
riptValue& range, const String& direction, ExceptionState&); | 62 PassRefPtrWillBeRawPtr<IDBRequest> openKeyCursor(ScriptState*, const ScriptV
alue& range, const String& direction, ExceptionState&); |
| 63 PassRefPtrWillBeRawPtr<IDBRequest> count(ExecutionContext*, const ScriptValu
e& range, ExceptionState&); | 63 PassRefPtrWillBeRawPtr<IDBRequest> count(ScriptState*, const ScriptValue& ra
nge, ExceptionState&); |
| 64 PassRefPtrWillBeRawPtr<IDBRequest> get(ExecutionContext*, const ScriptValue&
key, ExceptionState&); | 64 PassRefPtrWillBeRawPtr<IDBRequest> get(ScriptState*, const ScriptValue& key,
ExceptionState&); |
| 65 PassRefPtrWillBeRawPtr<IDBRequest> getKey(ExecutionContext*, const ScriptVal
ue& key, ExceptionState&); | 65 PassRefPtrWillBeRawPtr<IDBRequest> getKey(ScriptState*, const ScriptValue& k
ey, ExceptionState&); |
| 66 | 66 |
| 67 void markDeleted() { m_deleted = true; } | 67 void markDeleted() { m_deleted = true; } |
| 68 bool isDeleted() const; | 68 bool isDeleted() const; |
| 69 | 69 |
| 70 // Used internally and by InspectorIndexedDBAgent: | 70 // Used internally and by InspectorIndexedDBAgent: |
| 71 PassRefPtrWillBeRawPtr<IDBRequest> openCursor(ExecutionContext*, PassRefPtrW
illBeRawPtr<IDBKeyRange>, blink::WebIDBCursor::Direction); | 71 PassRefPtrWillBeRawPtr<IDBRequest> openCursor(ScriptState*, PassRefPtrWillBe
RawPtr<IDBKeyRange>, blink::WebIDBCursor::Direction); |
| 72 | 72 |
| 73 blink::WebIDBDatabase* backendDB() const; | 73 blink::WebIDBDatabase* backendDB() const; |
| 74 | 74 |
| 75 private: | 75 private: |
| 76 IDBIndex(const IDBIndexMetadata&, IDBObjectStore*, IDBTransaction*); | 76 IDBIndex(const IDBIndexMetadata&, IDBObjectStore*, IDBTransaction*); |
| 77 | 77 |
| 78 PassRefPtrWillBeRawPtr<IDBRequest> getInternal(ExecutionContext*, const Scri
ptValue& key, ExceptionState&, bool keyOnly); | 78 PassRefPtrWillBeRawPtr<IDBRequest> getInternal(ScriptState*, const ScriptVal
ue& key, ExceptionState&, bool keyOnly); |
| 79 | 79 |
| 80 IDBIndexMetadata m_metadata; | 80 IDBIndexMetadata m_metadata; |
| 81 RefPtrWillBeMember<IDBObjectStore> m_objectStore; | 81 RefPtrWillBeMember<IDBObjectStore> m_objectStore; |
| 82 RefPtrWillBeMember<IDBTransaction> m_transaction; | 82 RefPtrWillBeMember<IDBTransaction> m_transaction; |
| 83 bool m_deleted; | 83 bool m_deleted; |
| 84 }; | 84 }; |
| 85 | 85 |
| 86 } // namespace WebCore | 86 } // namespace WebCore |
| 87 | 87 |
| 88 #endif // IDBIndex_h | 88 #endif // IDBIndex_h |
| OLD | NEW |