summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/storage/StorageNamespaceImpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/storage/StorageNamespaceImpl.cpp')
-rw-r--r--Source/WebCore/storage/StorageNamespaceImpl.cpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/Source/WebCore/storage/StorageNamespaceImpl.cpp b/Source/WebCore/storage/StorageNamespaceImpl.cpp
index 68508a7..c6279ed 100644
--- a/Source/WebCore/storage/StorageNamespaceImpl.cpp
+++ b/Source/WebCore/storage/StorageNamespaceImpl.cpp
@@ -32,6 +32,7 @@
#include "StorageAreaImpl.h"
#include "StorageMap.h"
#include "StorageSyncManager.h"
+#include "StorageTracker.h"
#include <wtf/StdLibExtras.h>
#include <wtf/text/StringHash.h>
@@ -167,6 +168,32 @@ void StorageNamespaceImpl::unlock()
// Because there's a single event loop per-process, this is a no-op.
}
+void StorageNamespaceImpl::clearOriginForDeletion(SecurityOrigin* origin)
+{
+ ASSERT(isMainThread());
+
+ RefPtr<StorageAreaImpl> storageArea = m_storageAreaMap.get(origin);
+ if (storageArea)
+ storageArea->clearForOriginDeletion();
+}
+
+void StorageNamespaceImpl::clearAllOriginsForDeletion()
+{
+ ASSERT(isMainThread());
+
+ StorageAreaMap::iterator end = m_storageAreaMap.end();
+ for (StorageAreaMap::iterator it = m_storageAreaMap.begin(); it != end; ++it)
+ it->second->clearForOriginDeletion();
+}
+
+void StorageNamespaceImpl::sync()
+{
+ ASSERT(isMainThread());
+ StorageAreaMap::iterator end = m_storageAreaMap.end();
+ for (StorageAreaMap::iterator it = m_storageAreaMap.begin(); it != end; ++it)
+ it->second->sync();
+}
+
} // namespace WebCore
#endif // ENABLE(DOM_STORAGE)