OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 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 | 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 TOOLS_GN_BUILDER_RECORD_H_ | 5 #ifndef TOOLS_GN_BUILDER_RECORD_H_ |
6 #define TOOLS_GN_BUILDER_RECORD_H_ | 6 #define TOOLS_GN_BUILDER_RECORD_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <set> | 9 #include <set> |
10 #include <utility> | 10 #include <utility> |
(...skipping 17 matching lines...) Expand all Loading... |
28 // You can also have null item pointers when the target is not required for | 28 // You can also have null item pointers when the target is not required for |
29 // the current build (should_generate is false). | 29 // the current build (should_generate is false). |
30 class BuilderRecord { | 30 class BuilderRecord { |
31 public: | 31 public: |
32 typedef std::set<BuilderRecord*> BuilderRecordSet; | 32 typedef std::set<BuilderRecord*> BuilderRecordSet; |
33 | 33 |
34 enum ItemType { | 34 enum ItemType { |
35 ITEM_UNKNOWN, | 35 ITEM_UNKNOWN, |
36 ITEM_TARGET, | 36 ITEM_TARGET, |
37 ITEM_CONFIG, | 37 ITEM_CONFIG, |
38 ITEM_TOOLCHAIN | 38 ITEM_TOOLCHAIN, |
| 39 ITEM_POOL |
39 }; | 40 }; |
40 | 41 |
41 BuilderRecord(ItemType type, const Label& label); | 42 BuilderRecord(ItemType type, const Label& label); |
42 ~BuilderRecord(); | 43 ~BuilderRecord(); |
43 | 44 |
44 ItemType type() const { return type_; } | 45 ItemType type() const { return type_; } |
45 const Label& label() const { return label_; } | 46 const Label& label() const { return label_; } |
46 | 47 |
47 // Returns a user-ready name for the given type. e.g. "target". | 48 // Returns a user-ready name for the given type. e.g. "target". |
48 static const char* GetNameForType(ItemType type); | 49 static const char* GetNameForType(ItemType type); |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 bool resolved_; | 104 bool resolved_; |
104 | 105 |
105 BuilderRecordSet all_deps_; | 106 BuilderRecordSet all_deps_; |
106 BuilderRecordSet unresolved_deps_; | 107 BuilderRecordSet unresolved_deps_; |
107 BuilderRecordSet waiting_on_resolution_; | 108 BuilderRecordSet waiting_on_resolution_; |
108 | 109 |
109 DISALLOW_COPY_AND_ASSIGN(BuilderRecord); | 110 DISALLOW_COPY_AND_ASSIGN(BuilderRecord); |
110 }; | 111 }; |
111 | 112 |
112 #endif // TOOLS_GN_BUILDER_RECORD_H_ | 113 #endif // TOOLS_GN_BUILDER_RECORD_H_ |
OLD | NEW |