| 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 19 matching lines...) Expand all Loading... |
| 30 | 30 |
| 31 #include "wtf/PassRefPtr.h" | 31 #include "wtf/PassRefPtr.h" |
| 32 #include "wtf/RefCounted.h" | 32 #include "wtf/RefCounted.h" |
| 33 #include "wtf/text/WTFString.h" | 33 #include "wtf/text/WTFString.h" |
| 34 | 34 |
| 35 namespace WebCore { | 35 namespace WebCore { |
| 36 | 36 |
| 37 class IDBCallbacks; | 37 class IDBCallbacks; |
| 38 class IDBDatabase; | 38 class IDBDatabase; |
| 39 class IDBDatabaseCallbacks; | 39 class IDBDatabaseCallbacks; |
| 40 class SecurityOrigin; | |
| 41 class ScriptExecutionContext; | 40 class ScriptExecutionContext; |
| 42 | 41 |
| 43 typedef int ExceptionCode; | 42 typedef int ExceptionCode; |
| 44 | 43 |
| 45 // This class is shared by IDBFactory (async) and IDBFactorySync (sync). | 44 // This class is shared by IDBFactory (async) and IDBFactorySync (sync). |
| 46 // This is implemented by IDBFactoryBackendImpl and optionally others (in order
to proxy | 45 // This is implemented by IDBFactoryBackendImpl and optionally others (in order
to proxy |
| 47 // calls across process barriers). All calls to these classes should be non-bloc
king and | 46 // calls across process barriers). All calls to these classes should be non-bloc
king and |
| 48 // trigger work on a background thread if necessary. | 47 // trigger work on a background thread if necessary. |
| 49 class IDBFactoryBackendInterface : public RefCounted<IDBFactoryBackendInterface>
{ | 48 class IDBFactoryBackendInterface : public RefCounted<IDBFactoryBackendInterface>
{ |
| 50 public: | 49 public: |
| 51 static PassRefPtr<IDBFactoryBackendInterface> create(); | 50 static PassRefPtr<IDBFactoryBackendInterface> create(); |
| 52 virtual ~IDBFactoryBackendInterface() { } | 51 virtual ~IDBFactoryBackendInterface() { } |
| 53 | 52 |
| 54 virtual void getDatabaseNames(PassRefPtr<IDBCallbacks>, PassRefPtr<SecurityO
rigin>, ScriptExecutionContext*, const String& dataDir) = 0; | 53 virtual void getDatabaseNames(PassRefPtr<IDBCallbacks>, const String& databa
seIdentifier, ScriptExecutionContext*, const String& dataDir) = 0; |
| 55 virtual void open(const String& name, int64_t version, int64_t transactionId
, PassRefPtr<IDBCallbacks>, PassRefPtr<IDBDatabaseCallbacks>, PassRefPtr<Securit
yOrigin>, ScriptExecutionContext*, const String& dataDir) = 0; | 54 virtual void open(const String& name, int64_t version, int64_t transactionId
, PassRefPtr<IDBCallbacks>, PassRefPtr<IDBDatabaseCallbacks>, const String& data
baseIdentifier, ScriptExecutionContext*, const String& dataDir) = 0; |
| 56 virtual void deleteDatabase(const String& name, PassRefPtr<IDBCallbacks>, Pa
ssRefPtr<SecurityOrigin>, ScriptExecutionContext*, const String& dataDir) = 0; | 55 virtual void deleteDatabase(const String& name, PassRefPtr<IDBCallbacks>, co
nst String& databaseIdentifier, ScriptExecutionContext*, const String& dataDir)
= 0; |
| 57 }; | 56 }; |
| 58 | 57 |
| 59 } // namespace WebCore | 58 } // namespace WebCore |
| 60 | 59 |
| 61 #endif // IDBFactoryBackendInterface_h | 60 #endif // IDBFactoryBackendInterface_h |
| OLD | NEW |