KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > soot > jimple > parser > node > X2PStatement


1 /* This file was generated by SableCC (http://www.sablecc.org/). */
2
3 package soot.jimple.parser.node;
4
5 import soot.jimple.parser.analysis.*;
6
7 public final class X2PStatement extends XPStatement
8 {
9     private PStatement _pStatement_;
10
11     public X2PStatement()
12     {
13     }
14
15     public X2PStatement(
16         PStatement _pStatement_)
17     {
18         setPStatement(_pStatement_);
19     }
20
21     public Object JavaDoc clone()
22     {
23         throw new RuntimeException JavaDoc("Unsupported Operation");
24     }
25
26     public void apply(Switch sw)
27     {
28         throw new RuntimeException JavaDoc("Switch not supported.");
29     }
30
31     public PStatement getPStatement()
32     {
33         return _pStatement_;
34     }
35
36     public void setPStatement(PStatement node)
37     {
38         if(_pStatement_ != null)
39         {
40             _pStatement_.parent(null);
41         }
42
43         if(node != null)
44         {
45             if(node.parent() != null)
46             {
47                 node.parent().removeChild(node);
48             }
49
50             node.parent(this);
51         }
52
53         _pStatement_ = node;
54     }
55
56     void removeChild(Node child)
57     {
58         if(_pStatement_ == child)
59         {
60             _pStatement_ = null;
61         }
62     }
63
64     void replaceChild(Node oldChild, Node newChild)
65     {
66     }
67
68     public String JavaDoc toString()
69     {
70         return "" +
71             toString(_pStatement_);
72     }
73 }
74
Popular Tags