| Index: webkit/database/database_tracker.h
|
| ===================================================================
|
| --- webkit/database/database_tracker.h (revision 86537)
|
| +++ webkit/database/database_tracker.h (working copy)
|
| @@ -40,7 +40,7 @@
|
| extern const FilePath::CharType kTrackerDatabaseFileName[];
|
|
|
| class DatabasesTable;
|
| -class QuotaTable;
|
| +//class QuotaTable;
|
|
|
| // This class is used to store information about all databases in an origin.
|
| class OriginInfo {
|
| @@ -51,7 +51,7 @@
|
|
|
| const string16& GetOrigin() const { return origin_; }
|
| int64 TotalSize() const { return total_size_; }
|
| - int64 Quota() const { return quota_; }
|
| + //int64 Quota() const { return quota_; }
|
| void GetAllDatabaseNames(std::vector<string16>* databases) const;
|
| int64 GetDatabaseSize(const string16& database_name) const;
|
| string16 GetDatabaseDescription(const string16& database_name) const;
|
| @@ -59,15 +59,15 @@
|
| protected:
|
| typedef std::map<string16, std::pair<int64, string16> > DatabaseInfoMap;
|
|
|
| - OriginInfo(const string16& origin, int64 total_size, int64 quota);
|
| + OriginInfo(const string16& origin, int64 total_size); //, int64 quota);
|
|
|
| string16 origin_;
|
| int64 total_size_;
|
| - int64 quota_;
|
| + //int64 quota_;
|
| DatabaseInfoMap database_info_;
|
| };
|
|
|
| -// This class manages the main database, and keeps track of per origin quotas.
|
| +// This class manages the main database and keeps track of open databases.
|
| //
|
| // The data in this class is not thread-safe, so all methods of this class
|
| // should be called on the same thread. The only exceptions are the ctor(),
|
| @@ -125,9 +125,9 @@
|
|
|
| // TODO(michaeln): remove quota related stuff when quota manager
|
| // integration is complete
|
| - void SetOriginQuota(const string16& origin_identifier, int64 new_quota);
|
| - int64 GetDefaultQuota() { return default_quota_; }
|
| - void SetDefaultQuota(int64 quota); // for testing
|
| + //void SetOriginQuota(const string16& origin_identifier, int64 new_quota);
|
| + //int64 GetDefaultQuota() { return default_quota_; }
|
| + //void SetDefaultQuota(int64 quota); // for testing
|
|
|
| // Safe to call on any thread.
|
| quota::QuotaManagerProxy* quota_manager_proxy() const {
|
| @@ -185,9 +185,9 @@
|
|
|
| class CachedOriginInfo : public OriginInfo {
|
| public:
|
| - CachedOriginInfo() : OriginInfo(string16(), 0, 0) {}
|
| + CachedOriginInfo() : OriginInfo(string16(), 0) {}
|
| void SetOrigin(const string16& origin) { origin_ = origin; }
|
| - void SetQuota(int64 new_quota) { quota_ = new_quota; }
|
| + //void SetQuota(int64 new_quota) { quota_ = new_quota; }
|
| void SetDatabaseSize(const string16& database_name, int64 new_size) {
|
| int64 old_size = 0;
|
| if (database_info_.find(database_name) != database_info_.end())
|
| @@ -223,11 +223,11 @@
|
|
|
| int64 GetDBFileSize(const string16& origin_identifier,
|
| const string16& database_name);
|
| + int64 SeedOpenDatabaseSize(const string16& origin_identifier,
|
| + const string16& database_name);
|
| + int64 UpdateOpenDatabaseSizeAndNotify(const string16& origin_identifier,
|
| + const string16& database_name);
|
|
|
| - int64 GetOriginSpaceAvailable(const string16& origin_identifier);
|
| -
|
| - int64 UpdateCachedDatabaseFileSize(const string16& origin_identifier,
|
| - const string16& database_name);
|
| void ScheduleDatabaseForDeletion(const string16& origin_identifier,
|
| const string16& database_name);
|
| // Schedule a set of open databases for deletion. If non-null, callback is
|
| @@ -245,7 +245,7 @@
|
| const FilePath db_dir_;
|
| scoped_ptr<sql::Connection> db_;
|
| scoped_ptr<DatabasesTable> databases_table_;
|
| - scoped_ptr<QuotaTable> quota_table_;
|
| + //scoped_ptr<QuotaTable> quota_table_;
|
| scoped_ptr<sql::MetaTable> meta_table_;
|
| ObserverList<Observer, true> observers_;
|
| std::map<string16, CachedOriginInfo> origins_info_map_;
|
| @@ -256,7 +256,7 @@
|
| PendingCompletionMap deletion_callbacks_;
|
|
|
| // Default quota for all origins; changed only by tests
|
| - int64 default_quota_;
|
| + //int64 default_quota_;
|
|
|
| // Apps and Extensions can have special rights.
|
| scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_;
|
|
|