diff options
author | aa@google.com <aa@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-05 17:58:26 +0000 |
---|---|---|
committer | aa@google.com <aa@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-05 17:58:26 +0000 |
commit | 2000d10fec4a6e85cf410e129d5fe8939c4193bf (patch) | |
tree | e86f10ed4536cad0c3e6b1bcac7a90d92321e6d7 /webkit | |
parent | d89d9f0acc91fdbb0b90e137c19de0f328c0a40a (diff) | |
download | chromium_src-2000d10fec4a6e85cf410e129d5fe8939c4193bf.zip chromium_src-2000d10fec4a6e85cf410e129d5fe8939c4193bf.tar.gz chromium_src-2000d10fec4a6e85cf410e129d5fe8939c4193bf.tar.bz2 |
Missing files from r1785.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1786 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r-- | webkit/port/storage/DatabaseTracker.cpp | 88 | ||||
-rw-r--r-- | webkit/port/storage/OriginQuotaManager.cpp | 59 |
2 files changed, 147 insertions, 0 deletions
diff --git a/webkit/port/storage/DatabaseTracker.cpp b/webkit/port/storage/DatabaseTracker.cpp new file mode 100644 index 0000000..ff059cd --- /dev/null +++ b/webkit/port/storage/DatabaseTracker.cpp @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include "config.h" +#include "DatabaseTracker.h" +#include "OriginQuotaManager.h" + +using namespace std; + +namespace WebCore { + +OriginQuotaManager& DatabaseTracker::originQuotaManager() +{ + return *m_quotaManager; +} + +DatabaseTracker& DatabaseTracker::tracker() +{ + static DatabaseTracker tracker; + return tracker; +} + +DatabaseTracker::DatabaseTracker() + : m_client(0) + , m_proposedDatabase(0) +#ifndef NDEBUG + , m_thread(currentThread()) +#endif +{ +} + +bool DatabaseTracker::canEstablishDatabase(Document* document, const String& name, const String& displayName, unsigned long estimatedSize) +{ + return true; +} + +String DatabaseTracker::fullPathForDatabase(SecurityOrigin* origin, const String& name, bool createIfNotExists) +{ + return ""; +} + +void DatabaseTracker::setDatabaseDetails(SecurityOrigin* origin, const String& name, const String& displayName, unsigned long estimatedSize) +{ +} + +void DatabaseTracker::addOpenDatabase(Database* database) +{ +} + +void DatabaseTracker::removeOpenDatabase(Database* database) +{ +} + +unsigned long long DatabaseTracker::quotaForOrigin(SecurityOrigin* origin) +{ + return 0; +} + +void DatabaseTracker::scheduleNotifyDatabaseChanged(SecurityOrigin* origin, const String& name) +{ +} + +} diff --git a/webkit/port/storage/OriginQuotaManager.cpp b/webkit/port/storage/OriginQuotaManager.cpp new file mode 100644 index 0000000..09af45d --- /dev/null +++ b/webkit/port/storage/OriginQuotaManager.cpp @@ -0,0 +1,59 @@ +/* + * Copyright (C) 2008 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include "config.h" +#include "OriginQuotaManager.h" + +#include "Database.h" +#include "OriginUsageRecord.h" + +namespace WebCore { + +OriginQuotaManager::OriginQuotaManager() +{ +} + +void OriginQuotaManager::lock() +{ + m_usageRecordGuard.lock(); +} + +void OriginQuotaManager::unlock() +{ + m_usageRecordGuard.unlock(); +} + +void OriginQuotaManager::markDatabase(Database* database) +{ +} + +unsigned long long OriginQuotaManager::diskUsage(SecurityOrigin* origin) const +{ + return 0; +} + +} |