Logo Search packages:      
Sourcecode: sablecc version File versions  Download package

X1PProd.java

/* This file was generated by SableCC (http://www.sablecc.org/). */

package org.sablecc.sablecc.node;

import org.sablecc.sablecc.analysis.*;

public final class X1PProd extends XPProd
{
  private XPProd _xPProd_;
  private PProd _pProd_;

  public X1PProd()
  {}

  public X1PProd(
    XPProd _xPProd_,
    PProd _pProd_)
  {
    setXPProd(_xPProd_);
    setPProd(_pProd_);
  }

  public Object clone()
  {
    throw new RuntimeException("Unsupported Operation");
  }

  public void apply(Switch sw)
  {
    throw new RuntimeException("Switch not supported.");
  }

  public XPProd getXPProd()
  {
    return _xPProd_;
  }

  public void setXPProd(XPProd node)
  {
    if(_xPProd_ != null)
    {
      _xPProd_.parent(null);
    }

    if(node != null)
    {
      if(node.parent() != null)
      {
        node.parent().removeChild(node);
      }

      node.parent(this);
    }

    _xPProd_ = node;
  }

  public PProd getPProd()
  {
    return _pProd_;
  }

  public void setPProd(PProd node)
  {
    if(_pProd_ != null)
    {
      _pProd_.parent(null);
    }

    if(node != null)
    {
      if(node.parent() != null)
      {
        node.parent().removeChild(node);
      }

      node.parent(this);
    }

    _pProd_ = node;
  }

  void removeChild(Node child)
  {
    if(_xPProd_ == child)
    {
      _xPProd_ = null;
    }

    if(_pProd_ == child)
    {
      _pProd_ = null;
    }
  }

  void replaceChild(Node oldChild, Node newChild)
  {}

  public String toString()
  {
    return "" +
           toString(_xPProd_) +
           toString(_pProd_);
  }
}

Generated by  Doxygen 1.6.0   Back to index