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 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 int64_t findObjectStoreId(const String& name) const; | 100 int64_t findObjectStoreId(const String& name) const; |
101 bool containsObjectStore(const String& name) const | 101 bool containsObjectStore(const String& name) const |
102 { | 102 { |
103 return findObjectStoreId(name) != IDBObjectStoreMetadata::InvalidId; | 103 return findObjectStoreId(name) != IDBObjectStoreMetadata::InvalidId; |
104 } | 104 } |
105 | 105 |
106 IDBDatabaseBackendInterface* backend() const { return m_backend.get(); } | 106 IDBDatabaseBackendInterface* backend() const { return m_backend.get(); } |
107 | 107 |
108 static int64_t nextTransactionId(); | 108 static int64_t nextTransactionId(); |
109 | 109 |
110 static const char notFoundErrorMessage[]; | 110 static const char indexDeletedErrorMessage[]; |
| 111 static const char isKeyCursorErrorMessage[]; |
| 112 static const char noKeyOrKeyRangeErrorMessage[]; |
| 113 static const char noSuchIndexErrorMessage[]; |
| 114 static const char noSuchObjectStoreErrorMessage[]; |
| 115 static const char notGotValueErrorMessage[]; |
| 116 static const char notValidKeyErrorMessage[]; |
| 117 static const char notVersionChangeTransactionErrorMessage[]; |
| 118 static const char objectStoreDeletedErrorMessage[]; |
| 119 static const char requestNotFinishedErrorMessage[]; |
| 120 static const char sourceDeletedErrorMessage[]; |
| 121 static const char transactionFinishedErrorMessage[]; |
111 | 122 |
112 using RefCounted<IDBDatabase>::ref; | 123 using RefCounted<IDBDatabase>::ref; |
113 using RefCounted<IDBDatabase>::deref; | 124 using RefCounted<IDBDatabase>::deref; |
114 | 125 |
115 private: | 126 private: |
116 IDBDatabase(ScriptExecutionContext*, PassRefPtr<IDBDatabaseBackendInterface>
, PassRefPtr<IDBDatabaseCallbacks>); | 127 IDBDatabase(ScriptExecutionContext*, PassRefPtr<IDBDatabaseBackendInterface>
, PassRefPtr<IDBDatabaseCallbacks>); |
117 | 128 |
118 // EventTarget | 129 // EventTarget |
119 virtual void refEventTarget() { ref(); } | 130 virtual void refEventTarget() { ref(); } |
120 virtual void derefEventTarget() { deref(); } | 131 virtual void derefEventTarget() { deref(); } |
(...skipping 16 matching lines...) Expand all Loading... |
137 // Keep track of the versionchange events waiting to be fired on this | 148 // Keep track of the versionchange events waiting to be fired on this |
138 // database so that we can cancel them if the database closes. | 149 // database so that we can cancel them if the database closes. |
139 Vector<RefPtr<Event> > m_enqueuedEvents; | 150 Vector<RefPtr<Event> > m_enqueuedEvents; |
140 | 151 |
141 RefPtr<IDBDatabaseCallbacks> m_databaseCallbacks; | 152 RefPtr<IDBDatabaseCallbacks> m_databaseCallbacks; |
142 }; | 153 }; |
143 | 154 |
144 } // namespace WebCore | 155 } // namespace WebCore |
145 | 156 |
146 #endif // IDBDatabase_h | 157 #endif // IDBDatabase_h |
OLD | NEW |