Chromium Code Reviews| Index: net/sqlite/special_storage_policy_delegate.h |
| diff --git a/net/sqlite/special_storage_policy_delegate.h b/net/sqlite/special_storage_policy_delegate.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..536267e60721022d89ab40dd40e7139c383f28ce |
| --- /dev/null |
| +++ b/net/sqlite/special_storage_policy_delegate.h |
| @@ -0,0 +1,29 @@ |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef NET_SQLITE_SPECIAL_STORAGE_POLICY_DELEGATE_H_ |
| +#define NET_SQLITE_SPECIAL_STORAGE_POLICY_DELEGATE_H_ |
| + |
| +#include "base/memory/ref_counted.h" |
| + |
| +namespace net { |
| + |
| +// Encapsulates methods of WebKit SpecialStoragePolicy used by net/sqlite. |
|
Ryan Sleevi
2014/07/10 20:20:25
So, we would never mention this in a //net comment
mef
2014/07/11 13:29:23
Done.
|
| +class SpecialStoragePolicyDelegate |
| + : public base::RefCountedThreadSafe<SpecialStoragePolicyDelegate>{ |
|
Ryan Sleevi
2014/07/10 20:20:25
1) Why ref-counted? Make ownership explicit
mef
2014/07/11 13:29:24
Done.
|
| + public: |
| + // Some origins are only allowed to store session-only data which is deleted |
| + // when the session ends. |
| + virtual bool IsStorageSessionOnly(const GURL& origin) = 0; |
| + |
| + // Returns true if some origins are only allowed session-only storage. |
| + virtual bool HasSessionOnlyOrigins() = 0; |
|
Ryan Sleevi
2014/07/10 20:20:25
I'm not sure I grok how this fits into //net, but
mef
2014/07/11 13:29:23
Ack. I've thrown this as straight copy of SpecialS
|
| + protected: |
| + friend class base::RefCountedThreadSafe<SpecialStoragePolicyDelegate>; |
| + virtual ~SpecialStoragePolicyDelegate() {} |
| +}; |
| + |
| +} // namespace net |
| + |
| +#endif // NET_SQLITE_SPECIAL_STORAGE_POLICY_DELEGATE_H_ |