Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(502)

Side by Side Diff: components/content_settings/core/common/content_settings_pattern.h

Issue 2614033004: Convert SetContentSettingRules to use mojo, part 2/2. (Closed)
Patch Set: Convert SetContentSettingRules to use mojo, part 2/2. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/renderer/chrome_render_thread_observer.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Patterns used in content setting rules. 5 // Patterns used in content setting rules.
6 6
7 #ifndef COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_ 7 #ifndef COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_
8 #define COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_ 8 #define COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_
9 9
10 #include <string> 10 #include <string>
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 bool operator!=(const ContentSettingsPattern& other) const; 214 bool operator!=(const ContentSettingsPattern& other) const;
215 215
216 // Returns true if the pattern has a lower priority than the |other| pattern. 216 // Returns true if the pattern has a lower priority than the |other| pattern.
217 bool operator<(const ContentSettingsPattern& other) const; 217 bool operator<(const ContentSettingsPattern& other) const;
218 218
219 // Returns true if the pattern has a higher priority than the |other| pattern. 219 // Returns true if the pattern has a higher priority than the |other| pattern.
220 bool operator>(const ContentSettingsPattern& other) const; 220 bool operator>(const ContentSettingsPattern& other) const;
221 221
222 private: 222 private:
223 friend class content_settings::PatternParser; 223 friend class content_settings::PatternParser;
224 friend class ContentSettingsPatternSerializer;
225 friend struct mojo::StructTraits< 224 friend struct mojo::StructTraits<
226 content_settings::mojom::ContentSettingsPatternDataView, 225 content_settings::mojom::ContentSettingsPatternDataView,
227 ContentSettingsPattern>; 226 ContentSettingsPattern>;
228 FRIEND_TEST_ALL_PREFIXES(ContentSettingsPatternParserTest, SerializePatterns); 227 FRIEND_TEST_ALL_PREFIXES(ContentSettingsPatternParserTest, SerializePatterns);
229 228
230 class Builder; 229 class Builder;
231 230
232 static Relation CompareScheme( 231 static Relation CompareScheme(
233 const ContentSettingsPattern::PatternParts& parts, 232 const ContentSettingsPattern::PatternParts& parts,
234 const ContentSettingsPattern::PatternParts& other_parts); 233 const ContentSettingsPattern::PatternParts& other_parts);
(...skipping 11 matching lines...) Expand all
246 const ContentSettingsPattern::PatternParts& other_parts); 245 const ContentSettingsPattern::PatternParts& other_parts);
247 246
248 ContentSettingsPattern(const PatternParts& parts, bool valid); 247 ContentSettingsPattern(const PatternParts& parts, bool valid);
249 248
250 PatternParts parts_; 249 PatternParts parts_;
251 250
252 bool is_valid_; 251 bool is_valid_;
253 }; 252 };
254 253
255 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_ 254 #endif // COMPONENTS_CONTENT_SETTINGS_CORE_COMMON_CONTENT_SETTINGS_PATTERN_H_
OLDNEW
« no previous file with comments | « chrome/renderer/chrome_render_thread_observer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698