OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 class StorageQuotaCallback; | 48 class StorageQuotaCallback; |
49 | 49 |
50 class StorageQuotaClient : public WillBeHeapSupplement<Page> { | 50 class StorageQuotaClient : public WillBeHeapSupplement<Page> { |
51 WTF_MAKE_NONCOPYABLE(StorageQuotaClient); | 51 WTF_MAKE_NONCOPYABLE(StorageQuotaClient); |
52 public: | 52 public: |
53 StorageQuotaClient() { } | 53 StorageQuotaClient() { } |
54 virtual ~StorageQuotaClient() { } | 54 virtual ~StorageQuotaClient() { } |
55 | 55 |
56 virtual void requestQuota(ExecutionContext*, WebStorageQuotaType, unsigned l
ong long newQuotaInBytes, StorageQuotaCallback*, StorageErrorCallback*) = 0; | 56 virtual void requestQuota(ExecutionContext*, WebStorageQuotaType, unsigned l
ong long newQuotaInBytes, StorageQuotaCallback*, StorageErrorCallback*) = 0; |
57 virtual ScriptPromise requestPersistentQuota(ScriptState*, unsigned long lon
g newQuotaInBytes) = 0; | 57 virtual ScriptPromise requestPersistentQuota(ScriptState*, unsigned long lon
g newQuotaInBytes) = 0; |
| 58 virtual ScriptPromise requestDurability(ScriptState*) = 0; |
58 | 59 |
59 static const char* supplementName(); | 60 static const char* supplementName(); |
60 static StorageQuotaClient* from(ExecutionContext*); | 61 static StorageQuotaClient* from(ExecutionContext*); |
61 }; | 62 }; |
62 | 63 |
63 MODULES_EXPORT void provideStorageQuotaClientTo(Page&, PassOwnPtrWillBeRawPtr<St
orageQuotaClient>); | 64 MODULES_EXPORT void provideStorageQuotaClientTo(Page&, PassOwnPtrWillBeRawPtr<St
orageQuotaClient>); |
64 | 65 |
65 } // namespace blink | 66 } // namespace blink |
66 | 67 |
67 #endif // StorageQuotaClient_h | 68 #endif // StorageQuotaClient_h |
OLD | NEW |