OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ | 5 #ifndef COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ |
6 #define COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ | 6 #define COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <set> | 10 #include <set> |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 RegexMap regexes_; | 68 RegexMap regexes_; |
69 // Mapping of RE2IDs from FilteredRE2 (which are assigned in order) | 69 // Mapping of RE2IDs from FilteredRE2 (which are assigned in order) |
70 // to regex StringPattern::IDs. | 70 // to regex StringPattern::IDs. |
71 RE2IDMap re2_id_map_; | 71 RE2IDMap re2_id_map_; |
72 | 72 |
73 std::unique_ptr<re2::FilteredRE2> filtered_re2_; | 73 std::unique_ptr<re2::FilteredRE2> filtered_re2_; |
74 std::unique_ptr<SubstringSetMatcher> substring_matcher_; | 74 std::unique_ptr<SubstringSetMatcher> substring_matcher_; |
75 | 75 |
76 // The substring patterns from FilteredRE2, which are used in | 76 // The substring patterns from FilteredRE2, which are used in |
77 // |substring_matcher_| but whose lifetime is managed here. | 77 // |substring_matcher_| but whose lifetime is managed here. |
78 std::vector<const StringPattern*> substring_patterns_; | 78 std::vector<std::unique_ptr<StringPattern>> substring_patterns_; |
79 }; | 79 }; |
80 | 80 |
81 } // namespace url_matcher | 81 } // namespace url_matcher |
82 | 82 |
83 #endif // COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ | 83 #endif // COMPONENTS_URL_MATCHER_REGEX_SET_MATCHER_H_ |
OLD | NEW |