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

Side by Side Diff: chrome/tools/build/generate_policy_source.py

Issue 78763002: Move PolicyMap and its dependencies to components/policy/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: export nested struct Created 7 years 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
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 '''python %prog [options] platform chromium_os_flag template 6 '''python %prog [options] platform chromium_os_flag template
7 7
8 platform specifies which platform source is being generated for 8 platform specifies which platform source is being generated for
9 and can be one of (win, mac, linux) 9 and can be one of (win, mac, linux)
10 chromium_os_flag should be 1 if this is a Chromium OS build 10 chromium_os_flag should be 1 if this is a Chromium OS build
(...skipping 600 matching lines...) Expand 10 before | Expand all | Expand 10 after
611 #include <string> 611 #include <string>
612 612
613 #include "base/basictypes.h" 613 #include "base/basictypes.h"
614 #include "base/callback.h" 614 #include "base/callback.h"
615 #include "base/json/json_reader.h" 615 #include "base/json/json_reader.h"
616 #include "base/logging.h" 616 #include "base/logging.h"
617 #include "base/memory/scoped_ptr.h" 617 #include "base/memory/scoped_ptr.h"
618 #include "base/memory/weak_ptr.h" 618 #include "base/memory/weak_ptr.h"
619 #include "base/values.h" 619 #include "base/values.h"
620 #include "chrome/browser/policy/cloud/cloud_external_data_manager.h" 620 #include "chrome/browser/policy/cloud/cloud_external_data_manager.h"
621 #include "chrome/browser/policy/external_data_fetcher.h" 621 #include "components/policy/core/common/external_data_fetcher.h"
622 #include "chrome/browser/policy/policy_map.h" 622 #include "components/policy/core/common/policy_map.h"
623 #include "policy/policy_constants.h" 623 #include "policy/policy_constants.h"
624 #include "policy/proto/cloud_policy.pb.h" 624 #include "policy/proto/cloud_policy.pb.h"
625 625
626 using google::protobuf::RepeatedPtrField; 626 using google::protobuf::RepeatedPtrField;
627 627
628 namespace policy { 628 namespace policy {
629 629
630 namespace em = enterprise_management; 630 namespace em = enterprise_management;
631 631
632 base::Value* DecodeIntegerValue(google::protobuf::int64 value) { 632 base::Value* DecodeIntegerValue(google::protobuf::int64 value) {
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 def _WriteCloudPolicyDecoder(policies, os, f): 735 def _WriteCloudPolicyDecoder(policies, os, f):
736 f.write(CPP_HEAD) 736 f.write(CPP_HEAD)
737 for policy in policies: 737 for policy in policies:
738 if policy.is_supported and not policy.is_device_only: 738 if policy.is_supported and not policy.is_device_only:
739 _WritePolicyCode(f, policy) 739 _WritePolicyCode(f, policy)
740 f.write(CPP_FOOT) 740 f.write(CPP_FOOT)
741 741
742 742
743 if __name__ == '__main__': 743 if __name__ == '__main__':
744 sys.exit(main()) 744 sys.exit(main())
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698