| 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 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 if (!m_transaction->isActive()) { | 173 if (!m_transaction->isActive()) { |
| 174 exceptionState.throwDOMException(TransactionInactiveError, IDBDatabase::
transactionInactiveErrorMessage); | 174 exceptionState.throwDOMException(TransactionInactiveError, IDBDatabase::
transactionInactiveErrorMessage); |
| 175 return 0; | 175 return 0; |
| 176 } | 176 } |
| 177 if (m_transaction->isReadOnly()) { | 177 if (m_transaction->isReadOnly()) { |
| 178 exceptionState.throwDOMException(ReadOnlyError, IDBDatabase::transaction
ReadOnlyErrorMessage); | 178 exceptionState.throwDOMException(ReadOnlyError, IDBDatabase::transaction
ReadOnlyErrorMessage); |
| 179 return 0; | 179 return 0; |
| 180 } | 180 } |
| 181 | 181 |
| 182 Vector<WebBlobInfo> blobInfo; | 182 Vector<WebBlobInfo> blobInfo; |
| 183 RefPtr<SerializedScriptValue> serializedValue = SerializedScriptValueFactory
::instance().create(value, &blobInfo, exceptionState, scriptState->isolate()); | 183 RefPtr<SerializedScriptValue> serializedValue = SerializedScriptValueFactory
::instance().create(scriptState->isolate(), value, &blobInfo, exceptionState); |
| 184 if (exceptionState.hadException()) | 184 if (exceptionState.hadException()) |
| 185 return 0; | 185 return 0; |
| 186 | 186 |
| 187 // Keys that need to be extracted must be taken from a clone so that | 187 // Keys that need to be extracted must be taken from a clone so that |
| 188 // side effects (i.e. getters) are not triggered. Construct the | 188 // side effects (i.e. getters) are not triggered. Construct the |
| 189 // clone lazily since the operation may be expensive. | 189 // clone lazily since the operation may be expensive. |
| 190 ScriptValue clone; | 190 ScriptValue clone; |
| 191 | 191 |
| 192 const IDBKeyPath& keyPath = m_metadata.keyPath; | 192 const IDBKeyPath& keyPath = m_metadata.keyPath; |
| 193 const bool usesInLineKeys = !keyPath.isNull(); | 193 const bool usesInLineKeys = !keyPath.isNull(); |
| (...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 670 } | 670 } |
| 671 return IDBIndexMetadata::InvalidId; | 671 return IDBIndexMetadata::InvalidId; |
| 672 } | 672 } |
| 673 | 673 |
| 674 WebIDBDatabase* IDBObjectStore::backendDB() const | 674 WebIDBDatabase* IDBObjectStore::backendDB() const |
| 675 { | 675 { |
| 676 return m_transaction->backendDB(); | 676 return m_transaction->backendDB(); |
| 677 } | 677 } |
| 678 | 678 |
| 679 } // namespace blink | 679 } // namespace blink |
| OLD | NEW |