Lines Matching refs:label
35 private String label;
42 protected GraphNode(String label) {
43 this.label = label;
48 String result = "\n" + this.label + " -> ";
55 return label;
100 public boolean addNode(String label) {
101 if (!this.NodeIn(label)) {
102 nodes.add(new GraphNode(label));
109 protected GraphNode getNode(String label) {
111 if (n.label.equals(label))
113 // throw new NoSuchElementException("Knoten " + label + " nicht gefunden");
116 protected Edge getEdge(GraphNode node, String label) {
118 if (e.getLabel().equals(label)) {
124 public boolean NodeIn(String label) {
125 return getNode(label) != null;
136 public List<String> adjacent(String label) {
138 if (!NodeIn(label)) {
141 GraphNode n = this.getNode(label);
147 public int outDegree(String label) {
148 if (!NodeIn(label)) {
151 GraphNode n = this.getNode(label);
155 public int inDegree(String label) {
156 if (!NodeIn(label)) {
161 if (EdgeIn(n.getLabel(), label)) {
187 public boolean removeNode(String label) {
188 if (!NodeIn(label))
191 if (!n.getLabel().equals(label)) {
192 // "zu label hinfuehrende Kanten"
193 removeEdge(n.getLabel(), label);
201 removeEdge(label, n.getLabel());
204 nodes.remove(getNode(label));