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

Side by Side Diff: chrome/browser/policy/policy_namespace.cc

Issue 16254003: WIP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/policy/policy_namespace.h ('k') | chrome/browser/policy/policy_service.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/policy/policy_namespace.h"
6
7 namespace policy {
8
9 PolicyNamespace::PolicyNamespace() {}
10
11 PolicyNamespace::PolicyNamespace(PolicyDomain domain,
12 const std::string& component_id)
13 : domain(domain),
14 component_id(component_id) {}
15
16 PolicyNamespace::PolicyNamespace(const PolicyNamespace& other)
17 : domain(other.domain),
18 component_id(other.component_id) {}
19
20 PolicyNamespace::~PolicyNamespace() {}
21
22 PolicyNamespace& PolicyNamespace::operator=(const PolicyNamespace& other) {
23 domain = other.domain;
24 component_id = other.component_id;
25 return *this;
26 }
27
28 bool PolicyNamespace::operator<(const PolicyNamespace& other) const {
29 return domain < other.domain ||
30 (domain == other.domain && component_id < other.component_id);
31 }
32
33 bool PolicyNamespace::operator==(const PolicyNamespace& other) const {
34 return domain == other.domain && component_id == other.component_id;
35 }
36
37 bool PolicyNamespace::operator!=(const PolicyNamespace& other) const {
38 return !(*this == other);
39 }
40
41 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/policy/policy_namespace.h ('k') | chrome/browser/policy/policy_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698