net.sf.saffron.sql
Class SqlIdentifier

java.lang.Object
  |
  +--net.sf.saffron.sql.SqlNode
        |
        +--net.sf.saffron.sql.SqlIdentifier

public class SqlIdentifier
extends SqlNode

A SqlIdentifier is an identifier, possibly compound.


Nested Class Summary
 
Nested classes inherited from class net.sf.saffron.sql.SqlNode
SqlNode.DatabaseMetaDataInvocationHandler
 
Field Summary
(package private)  Object extra
          Extra information (such as a table) which is not displayed.
 String[] names
           
 
Constructor Summary
SqlIdentifier(String name)
          Creates a simple identifier, for example foo.
SqlIdentifier(String[] names, Object extra)
          Creates a compound identifier, for example foo.bar.
 
Method Summary
 Object clone()
           
 Object getExtra()
           
 SqlKind getKind()
          Returns the type of node this is, or SqlKind.Other if it's nothing special.
 String toString()
           
 void unparse(SqlWriter writer, int leftPrec, int rightPrec)
          Writes a SQL representation of this node to a writer.
 
Methods inherited from class net.sf.saffron.sql.SqlNode
cloneArray, isA, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

names

public final String[] names

extra

final Object extra
Extra information (such as a table) which is not displayed.

Constructor Detail

SqlIdentifier

public SqlIdentifier(String[] names,
                     Object extra)
Creates a compound identifier, for example foo.bar.

Parameters:
names - Parts of the identifier, length >= 1
extra - Extra information, may be null

SqlIdentifier

public SqlIdentifier(String name)
Creates a simple identifier, for example foo.

Method Detail

getKind

public SqlKind getKind()
Description copied from class: SqlNode
Returns the type of node this is, or SqlKind.Other if it's nothing special.

Overrides:
getKind in class SqlNode
Returns:
a SqlKind value, never null

clone

public Object clone()
Specified by:
clone in class SqlNode

toString

public String toString()
Overrides:
toString in class SqlNode

unparse

public void unparse(SqlWriter writer,
                    int leftPrec,
                    int rightPrec)
Description copied from class: SqlNode
Writes a SQL representation of this node to a writer.

Specified by:
unparse in class SqlNode

getExtra

public Object getExtra()

SourceForge.net_Logo