001package gudusoft.gsqlparser.nodes; 002 003/** 004 * List of {@link TConstraint}. 005 * 006. */ 007 008public class TConstraintList extends TParseTreeNodeList <TConstraint> { 009 public TConstraintList() 010 { 011 } 012 013 public void addConstraint(TConstraint def) 014 { 015 addElement(def); 016 } 017 018 public TConstraint getConstraint(int position) 019 { 020 if (position < size()) 021 { 022 return (TConstraint)elementAt(position); 023 }else{ 024 return null; 025 } 026 } 027 028 void addParseTreeNode(Object arg1){ 029 addConstraint((TConstraint)arg1); 030 } 031 032 public void accept(TParseTreeVisitor v){ 033 v.preVisit(this); 034 v.postVisit(this); 035 } 036// 037// public void acceptChildren(TParseTreeVisitor v){ 038// v.preVisit(this); 039// for(int i=0;i<this.size();i++){ 040// this.getConstraint(i).acceptChildren(v); 041// } 042// v.postVisit(this); 043// } 044}