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 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
161 } | 161 } |
162 if (!m_transaction->isActive()) { | 162 if (!m_transaction->isActive()) { |
163 exceptionState.throwDOMException(TransactionInactiveError, IDBDatabase::
transactionInactiveErrorMessage); | 163 exceptionState.throwDOMException(TransactionInactiveError, IDBDatabase::
transactionInactiveErrorMessage); |
164 return nullptr; | 164 return nullptr; |
165 } | 165 } |
166 if (m_transaction->isReadOnly()) { | 166 if (m_transaction->isReadOnly()) { |
167 exceptionState.throwDOMException(ReadOnlyError, IDBDatabase::transaction
ReadOnlyErrorMessage); | 167 exceptionState.throwDOMException(ReadOnlyError, IDBDatabase::transaction
ReadOnlyErrorMessage); |
168 return nullptr; | 168 return nullptr; |
169 } | 169 } |
170 | 170 |
171 RefPtr<SerializedScriptValue> serializedValue = SerializedScriptValue::creat
e(value, exceptionState, state); | 171 RefPtr<SerializedScriptValue> serializedValue = SerializedScriptValue::creat
e(value, 0, exceptionState, state); |
172 if (exceptionState.hadException()) | 172 if (exceptionState.hadException()) |
173 return nullptr; | 173 return nullptr; |
174 | 174 |
175 if (serializedValue->containsBlobs()) { | 175 if (serializedValue->containsBlobs()) { |
176 // FIXME: Add Blob/File/FileList support | 176 // FIXME: Add Blob/File/FileList support |
177 exceptionState.throwDOMException(DataCloneError, "The object store curre
ntly does not support blob values."); | 177 exceptionState.throwDOMException(DataCloneError, "The object store curre
ntly does not support blob values."); |
178 return nullptr; | 178 return nullptr; |
179 } | 179 } |
180 | 180 |
181 const IDBKeyPath& keyPath = m_metadata.keyPath; | 181 const IDBKeyPath& keyPath = m_metadata.keyPath; |
(...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
618 } | 618 } |
619 return IDBIndexMetadata::InvalidId; | 619 return IDBIndexMetadata::InvalidId; |
620 } | 620 } |
621 | 621 |
622 WebIDBDatabase* IDBObjectStore::backendDB() const | 622 WebIDBDatabase* IDBObjectStore::backendDB() const |
623 { | 623 { |
624 return m_transaction->backendDB(); | 624 return m_transaction->backendDB(); |
625 } | 625 } |
626 | 626 |
627 } // namespace WebCore | 627 } // namespace WebCore |
OLD | NEW |