| 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 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 return 0; | 155 return 0; |
| 156 } | 156 } |
| 157 | 157 |
| 158 ScriptState* state = ScriptState::current(); | 158 ScriptState* state = ScriptState::current(); |
| 159 RefPtr<SerializedScriptValue> serializedValue = value.serialize(state); | 159 RefPtr<SerializedScriptValue> serializedValue = value.serialize(state); |
| 160 if (state->hadException()) { | 160 if (state->hadException()) { |
| 161 ec = IDBDatabaseException::IDB_DATA_CLONE_ERR; | 161 ec = IDBDatabaseException::IDB_DATA_CLONE_ERR; |
| 162 return 0; | 162 return 0; |
| 163 } | 163 } |
| 164 | 164 |
| 165 if (serializedValue->blobURLs().size() > 0) { | 165 if (serializedValue->containsBlobs()) { |
| 166 // FIXME: Add Blob/File/FileList support | 166 // FIXME: Add Blob/File/FileList support |
| 167 ec = IDBDatabaseException::IDB_DATA_CLONE_ERR; | 167 ec = IDBDatabaseException::IDB_DATA_CLONE_ERR; |
| 168 return 0; | 168 return 0; |
| 169 } | 169 } |
| 170 | 170 |
| 171 const IDBKeyPath& keyPath = m_metadata.keyPath; | 171 const IDBKeyPath& keyPath = m_metadata.keyPath; |
| 172 const bool usesInLineKeys = !keyPath.isNull(); | 172 const bool usesInLineKeys = !keyPath.isNull(); |
| 173 const bool hasKeyGenerator = autoIncrement(); | 173 const bool hasKeyGenerator = autoIncrement(); |
| 174 | 174 |
| 175 if (putMode != IDBObjectStoreBackendInterface::CursorUpdate && usesInLineKey
s && key) { | 175 if (putMode != IDBObjectStoreBackendInterface::CursorUpdate && usesInLineKey
s && key) { |
| (...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 547 ASSERT(m_transaction->isFinished()); | 547 ASSERT(m_transaction->isFinished()); |
| 548 | 548 |
| 549 // Break reference cycles. | 549 // Break reference cycles. |
| 550 m_indexMap.clear(); | 550 m_indexMap.clear(); |
| 551 } | 551 } |
| 552 | 552 |
| 553 | 553 |
| 554 } // namespace WebCore | 554 } // namespace WebCore |
| 555 | 555 |
| 556 #endif // ENABLE(INDEXED_DATABASE) | 556 #endif // ENABLE(INDEXED_DATABASE) |
| OLD | NEW |