OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ |
7 #pragma once | |
8 | 7 |
9 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
10 | 9 |
11 class FilePath; | 10 class FilePath; |
12 | 11 |
13 // Determines which files should be included in a packaged extension. | 12 // Determines which files should be included in a packaged extension. |
14 // Designed specifically to operate with the callback in chrome/common/zip. | 13 // Designed specifically to operate with the callback in chrome/common/zip. |
15 class ExtensionCreatorFilter | 14 class ExtensionCreatorFilter |
16 : public base::RefCounted<ExtensionCreatorFilter> { | 15 : public base::RefCounted<ExtensionCreatorFilter> { |
17 public: | 16 public: |
18 ExtensionCreatorFilter() {} | 17 ExtensionCreatorFilter() {} |
19 | 18 |
20 // Returns true if the given FilePath should be included in a | 19 // Returns true if the given FilePath should be included in a |
21 // packed extension. | 20 // packed extension. |
22 bool ShouldPackageFile(const FilePath& file_path); | 21 bool ShouldPackageFile(const FilePath& file_path); |
23 | 22 |
24 private: | 23 private: |
25 friend class base::RefCounted<ExtensionCreatorFilter>; | 24 friend class base::RefCounted<ExtensionCreatorFilter>; |
26 ~ExtensionCreatorFilter() {} | 25 ~ExtensionCreatorFilter() {} |
27 DISALLOW_COPY_AND_ASSIGN(ExtensionCreatorFilter); | 26 DISALLOW_COPY_AND_ASSIGN(ExtensionCreatorFilter); |
28 }; | 27 }; |
29 | 28 |
30 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ | 29 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CREATOR_FILTER_H_ |
OLD | NEW |