Chromium Code Reviews| Index: components/offline_pages/client_policies.h |
| diff --git a/components/offline_pages/client_policies.h b/components/offline_pages/client_policies.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..cc95b93c88042ab72d16b42f7866e309bad3c451 |
| --- /dev/null |
| +++ b/components/offline_pages/client_policies.h |
| @@ -0,0 +1,26 @@ |
| +// Copyright 2016 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. |
| + |
| +#undef kUnlimitedPages |
| +#define kUnlimitedPages 0 |
| + |
| +/** |
| + * This macro is used to define client policies. |
| + * For some details please see offline_page_client_policy.h |
| + * |
| + * Use Example: |
| + * POLICY(name_space, // The name_space of this policy. |
| + * type, // TEMPORARY/PERSISTENT, defined in LifetimePolicy |
| + * expire_days, // Number of days before expire of pages, in days. |
| + * page_limit, // As defined in client policy. Use kUnlimitedPages |
| + * // for unlimited number. |
| + */ |
| + |
| +#undef CLIENT_POLICIES |
| +#define CLIENT_POLICIES \ |
|
fgorski
2016/05/02 23:10:31
no let's have a static method instead of a macro f
romax
2016/05/03 00:29:24
Done.
|
| + POLICY(bookmark, TEMPORARY, 7, kUnlimitedPages) \ |
| + POLICY(last_n, TEMPORARY, 2, 20) \ |
| + POLICY(defaultPolicy, TEMPORARY, 1, kUnlimitedPages) |
| + |
| +#undef kUnlimitedPages |