summaryrefslogtreecommitdiffstats
path: root/src/graph.h
diff options
context:
space:
mode:
authorEvan Martin <martine@danga.com>2011-12-07 17:38:10 (GMT)
committerEvan Martin <martine@danga.com>2011-12-07 17:38:10 (GMT)
commitd58d918bafb26af9fd0c65cd61058ad29c5d2f4b (patch)
tree163351351c3f4cad33cb3331e0ffc1721e8b8491 /src/graph.h
parent48526b9c08f22ddcf7e36ca02fde0202312920fa (diff)
downloadNinja-d58d918bafb26af9fd0c65cd61058ad29c5d2f4b.zip
Ninja-d58d918bafb26af9fd0c65cd61058ad29c5d2f4b.tar.gz
Ninja-d58d918bafb26af9fd0c65cd61058ad29c5d2f4b.tar.bz2
make Node::out_edges_ private
Diffstat (limited to 'src/graph.h')
-rw-r--r--src/graph.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/graph.h b/src/graph.h
index b6f5139..6756417 100644
--- a/src/graph.h
+++ b/src/graph.h
@@ -71,6 +71,9 @@ struct Node {
Edge* in_edge() const { return in_edge_; }
void set_in_edge(Edge* edge) { in_edge_ = edge; }
+ const vector<Edge*>& out_edges() const { return out_edges_; }
+ void AddOutEdge(Edge* edge) { out_edges_.push_back(edge); }
+
private:
string path_;
/// Possible values of mtime_:
@@ -88,9 +91,7 @@ private:
/// known edge to produce it.
Edge* in_edge_;
- // TODO: make these private as well. But don't just blindly add
- // setters/getters, instead pay attention to the proper API.
-public:
+ /// All Edges that use this Node as an input.
vector<Edge*> out_edges_;
};