Index: Source/WebCore/Modules/indexeddb/IDBAny.h |
=================================================================== |
--- Source/WebCore/Modules/indexeddb/IDBAny.h (revision 132816) |
+++ Source/WebCore/Modules/indexeddb/IDBAny.h (working copy) |
@@ -28,7 +28,6 @@ |
#if ENABLE(INDEXED_DATABASE) |
-#include "ScriptValue.h" |
#include <wtf/PassRefPtr.h> |
#include <wtf/RefCounted.h> |
#include <wtf/RefPtr.h> |
@@ -46,6 +45,7 @@ |
class IDBKeyPath; |
class IDBObjectStore; |
class IDBTransaction; |
+class SerializedScriptValue; |
class IDBAny : public RefCounted<IDBAny> { |
public: |
@@ -59,11 +59,10 @@ |
any->set(idbObject); |
return any.release(); |
} |
- template<typename T> |
- static PassRefPtr<IDBAny> create(const T& idbObject) |
+ static PassRefPtr<IDBAny> create(const IDBKeyPath& keyPath) |
{ |
RefPtr<IDBAny> any = IDBAny::createInvalid(); |
- any->set(idbObject); |
+ any->set(keyPath); |
return any.release(); |
} |
template<typename T> |
@@ -73,12 +72,6 @@ |
any->set(idbObject); |
return any.release(); |
} |
- static PassRefPtr<IDBAny> create(int64_t value) |
- { |
- RefPtr<IDBAny> any = IDBAny::createInvalid(); |
- any->set(value); |
- return any.release(); |
- } |
~IDBAny(); |
enum Type { |
@@ -93,8 +86,7 @@ |
IDBKeyType, |
IDBObjectStoreType, |
IDBTransactionType, |
- ScriptValueType, |
- IntegerType, |
+ SerializedScriptValueType, |
StringType, |
}; |
@@ -109,8 +101,7 @@ |
PassRefPtr<IDBKey> idbKey(); |
PassRefPtr<IDBObjectStore> idbObjectStore(); |
PassRefPtr<IDBTransaction> idbTransaction(); |
- ScriptValue scriptValue(); |
- int64_t integer(); |
+ PassRefPtr<SerializedScriptValue> serializedScriptValue(); |
const String& string(); |
// Set can only be called once. |
@@ -124,10 +115,9 @@ |
void set(PassRefPtr<IDBKey>); |
void set(PassRefPtr<IDBObjectStore>); |
void set(PassRefPtr<IDBTransaction>); |
+ void set(PassRefPtr<SerializedScriptValue>); |
void set(const IDBKeyPath&); |
void set(const String&); |
- void set(const ScriptValue&); |
- void set(int64_t); |
private: |
IDBAny(); |
@@ -144,9 +134,8 @@ |
RefPtr<IDBKey> m_idbKey; |
RefPtr<IDBObjectStore> m_idbObjectStore; |
RefPtr<IDBTransaction> m_idbTransaction; |
- ScriptValue m_scriptValue; |
+ RefPtr<SerializedScriptValue> m_serializedScriptValue; |
String m_string; |
- int64_t m_integer; |
}; |
} // namespace WebCore |