Fix tabbing.... Please fix your editors so they do tabbing correctly!!! (Spaces...
[IRC.git] / Robust / src / IR / Tree / SwitchBlockNode.java
1 package IR.Tree;
2
3 import java.util.Vector;
4
5 public class SwitchBlockNode extends BlockStatementNode {
6   Vector<SwitchLabelNode> switch_conds;
7   BlockNode switch_st;
8
9   public SwitchBlockNode(Vector<SwitchLabelNode> switch_conds, BlockNode switch_st) {
10     this.switch_conds = switch_conds;
11     this.switch_st = switch_st;
12   }
13
14   public Vector<SwitchLabelNode> getSwitchConditions() {
15     return this.switch_conds;
16   }
17
18   public BlockNode getSwitchBlockStatement() {
19     return this.switch_st;
20   }
21
22   public String printNode(int indent) {
23     String result = "";
24     for(int i = 0; i < this.switch_conds.size(); i++) {
25       result += this.switch_conds.elementAt(i).printNode(indent);
26     }
27     result += this.switch_st.printNode(indent);
28     return result;
29   }
30
31   public int kind() {
32     return Kind.SwitchBlockNode;
33   }
34 }