Main Page   Packages   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

AStrongExpCastExp.java

00001 package edu.ksu.cis.bandera.specification.predicate.node;
00002 
00003 /* This file was generated by SableCC (http://www.sable.mcgill.ca/sablecc/). */
00004 
00005 import java.util.*;
00006 import edu.ksu.cis.bandera.specification.predicate.analysis.*;
00007 
00008 public final class AStrongExpCastExp extends PCastExp
00009 {
00010     private TLParen _lParen_;
00011     private PExp _exp_;
00012     private TRParen _rParen_;
00013     private PUnaryNotPlusMinusExp _unaryNotPlusMinusExp_;
00014 
00015     public AStrongExpCastExp()
00016     {
00017     }
00018     public AStrongExpCastExp(
00019         TLParen _lParen_,
00020         PExp _exp_,
00021         TRParen _rParen_,
00022         PUnaryNotPlusMinusExp _unaryNotPlusMinusExp_)
00023     {
00024         setLParen(_lParen_);
00025 
00026         setExp(_exp_);
00027 
00028         setRParen(_rParen_);
00029 
00030         setUnaryNotPlusMinusExp(_unaryNotPlusMinusExp_);
00031 
00032     }
00033     public void apply(Switch sw)
00034     {
00035         ((Analysis) sw).caseAStrongExpCastExp(this);
00036     }
00037     public Object clone()
00038     {
00039         return new AStrongExpCastExp(
00040             (TLParen) cloneNode(_lParen_),
00041             (PExp) cloneNode(_exp_),
00042             (TRParen) cloneNode(_rParen_),
00043             (PUnaryNotPlusMinusExp) cloneNode(_unaryNotPlusMinusExp_));
00044     }
00045     public PExp getExp()
00046     {
00047         return _exp_;
00048     }
00049     public TLParen getLParen()
00050     {
00051         return _lParen_;
00052     }
00053     public TRParen getRParen()
00054     {
00055         return _rParen_;
00056     }
00057     public PUnaryNotPlusMinusExp getUnaryNotPlusMinusExp()
00058     {
00059         return _unaryNotPlusMinusExp_;
00060     }
00061     void removeChild(Node child)
00062     {
00063         if(_lParen_ == child)
00064         {
00065             _lParen_ = null;
00066             return;
00067         }
00068 
00069         if(_exp_ == child)
00070         {
00071             _exp_ = null;
00072             return;
00073         }
00074 
00075         if(_rParen_ == child)
00076         {
00077             _rParen_ = null;
00078             return;
00079         }
00080 
00081         if(_unaryNotPlusMinusExp_ == child)
00082         {
00083             _unaryNotPlusMinusExp_ = null;
00084             return;
00085         }
00086 
00087     }
00088     void replaceChild(Node oldChild, Node newChild)
00089     {
00090         if(_lParen_ == oldChild)
00091         {
00092             setLParen((TLParen) newChild);
00093             return;
00094         }
00095 
00096         if(_exp_ == oldChild)
00097         {
00098             setExp((PExp) newChild);
00099             return;
00100         }
00101 
00102         if(_rParen_ == oldChild)
00103         {
00104             setRParen((TRParen) newChild);
00105             return;
00106         }
00107 
00108         if(_unaryNotPlusMinusExp_ == oldChild)
00109         {
00110             setUnaryNotPlusMinusExp((PUnaryNotPlusMinusExp) newChild);
00111             return;
00112         }
00113 
00114     }
00115     public void setExp(PExp node)
00116     {
00117         if(_exp_ != null)
00118         {
00119             _exp_.parent(null);
00120         }
00121 
00122         if(node != null)
00123         {
00124             if(node.parent() != null)
00125             {
00126                 node.parent().removeChild(node);
00127             }
00128 
00129             node.parent(this);
00130         }
00131 
00132         _exp_ = node;
00133     }
00134     public void setLParen(TLParen node)
00135     {
00136         if(_lParen_ != null)
00137         {
00138             _lParen_.parent(null);
00139         }
00140 
00141         if(node != null)
00142         {
00143             if(node.parent() != null)
00144             {
00145                 node.parent().removeChild(node);
00146             }
00147 
00148             node.parent(this);
00149         }
00150 
00151         _lParen_ = node;
00152     }
00153     public void setRParen(TRParen node)
00154     {
00155         if(_rParen_ != null)
00156         {
00157             _rParen_.parent(null);
00158         }
00159 
00160         if(node != null)
00161         {
00162             if(node.parent() != null)
00163             {
00164                 node.parent().removeChild(node);
00165             }
00166 
00167             node.parent(this);
00168         }
00169 
00170         _rParen_ = node;
00171     }
00172     public void setUnaryNotPlusMinusExp(PUnaryNotPlusMinusExp node)
00173     {
00174         if(_unaryNotPlusMinusExp_ != null)
00175         {
00176             _unaryNotPlusMinusExp_.parent(null);
00177         }
00178 
00179         if(node != null)
00180         {
00181             if(node.parent() != null)
00182             {
00183                 node.parent().removeChild(node);
00184             }
00185 
00186             node.parent(this);
00187         }
00188 
00189         _unaryNotPlusMinusExp_ = node;
00190     }
00191     public String toString()
00192     {
00193         return ""
00194             + toString(_lParen_)
00195             + toString(_exp_)
00196             + toString(_rParen_)
00197             + toString(_unaryNotPlusMinusExp_);
00198     }
00199 }

Generated at Thu Feb 7 06:40:01 2002 for Bandera by doxygen1.2.10 written by Dimitri van Heesch, © 1997-2001