net.sf.jsqlparser.util.deparser
Class SelectDeParser

java.lang.Object
  extended by net.sf.jsqlparser.util.deparser.SelectDeParser
All Implemented Interfaces:
ColumnReferenceVisitor, FromItemVisitor, OrderByVisitor, SelectItemVisitor, SelectVisitor

public class SelectDeParser
extends java.lang.Object
implements SelectVisitor, OrderByVisitor, SelectItemVisitor, FromItemVisitor, ColumnReferenceVisitor

A class to de-parse (that is, tranform from JSqlParser hierarchy into a string) a Select


Field Summary
protected  java.lang.StringBuffer buffer
           
protected  ExpressionVisitor expressionVisitor
           
 
Constructor Summary
SelectDeParser()
           
SelectDeParser(ExpressionVisitor expressionVisitor, java.lang.StringBuffer buffer)
           
 
Method Summary
 void deparseJoin(Join join)
           
 void deparseLimit(Limit limit)
           
 void deparseOrderBy(java.util.List orderByElements)
           
 java.lang.StringBuffer getBuffer()
           
 ExpressionVisitor getExpressionVisitor()
           
 void setBuffer(java.lang.StringBuffer buffer)
           
 void setExpressionVisitor(ExpressionVisitor visitor)
           
 void visit(AllColumns allColumns)
           
 void visit(AllTableColumns allTableColumns)
           
 void visit(Column column)
           
 void visit(ColumnIndex columnIndex)
           
 void visit(OrderByElement orderBy)
           
 void visit(PlainSelect plainSelect)
           
 void visit(SelectExpressionItem selectExpressionItem)
           
 void visit(SubJoin subjoin)
           
 void visit(SubSelect subSelect)
           
 void visit(Table tableName)
           
 void visit(Union union)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

buffer

protected java.lang.StringBuffer buffer

expressionVisitor

protected ExpressionVisitor expressionVisitor
Constructor Detail

SelectDeParser

public SelectDeParser()

SelectDeParser

public SelectDeParser(ExpressionVisitor expressionVisitor,
                      java.lang.StringBuffer buffer)
Parameters:
expressionVisitor - a ExpressionVisitor to de-parse expressions. It has to share the same
StringBuffer (buffer parameter) as this object in order to work
buffer - the buffer that will be filled with the select
Method Detail

visit

public void visit(PlainSelect plainSelect)
Specified by:
visit in interface SelectVisitor

visit

public void visit(Union union)
Specified by:
visit in interface SelectVisitor

visit

public void visit(OrderByElement orderBy)
Specified by:
visit in interface OrderByVisitor

visit

public void visit(Column column)
Specified by:
visit in interface ColumnReferenceVisitor

visit

public void visit(ColumnIndex columnIndex)
Specified by:
visit in interface ColumnReferenceVisitor

visit

public void visit(AllColumns allColumns)
Specified by:
visit in interface SelectItemVisitor

visit

public void visit(AllTableColumns allTableColumns)
Specified by:
visit in interface SelectItemVisitor

visit

public void visit(SelectExpressionItem selectExpressionItem)
Specified by:
visit in interface SelectItemVisitor

visit

public void visit(SubSelect subSelect)
Specified by:
visit in interface FromItemVisitor

visit

public void visit(Table tableName)
Specified by:
visit in interface FromItemVisitor

deparseOrderBy

public void deparseOrderBy(java.util.List orderByElements)

deparseLimit

public void deparseLimit(Limit limit)

getBuffer

public java.lang.StringBuffer getBuffer()

setBuffer

public void setBuffer(java.lang.StringBuffer buffer)

getExpressionVisitor

public ExpressionVisitor getExpressionVisitor()

setExpressionVisitor

public void setExpressionVisitor(ExpressionVisitor visitor)

visit

public void visit(SubJoin subjoin)
Specified by:
visit in interface FromItemVisitor

deparseJoin

public void deparseJoin(Join join)