org.teiid.query.sql.symbol
Class WindowFunction

java.lang.Object
  extended by org.teiid.query.sql.symbol.Symbol
      extended by org.teiid.query.sql.symbol.SingleElementSymbol
          extended by org.teiid.query.sql.symbol.WindowFunction
All Implemented Interfaces:
java.lang.Cloneable, LanguageObject, Expression, SelectSymbol

public class WindowFunction
extends SingleElementSymbol


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.teiid.query.sql.LanguageObject
LanguageObject.Util
 
Field Summary
 
Fields inherited from class org.teiid.query.sql.symbol.SingleElementSymbol
SEPARATOR
 
Fields inherited from class org.teiid.query.sql.symbol.Symbol
outputName
 
Constructor Summary
  WindowFunction(java.lang.String name)
           
protected WindowFunction(java.lang.String name, java.lang.String canonical)
           
 
Method Summary
 void acceptVisitor(LanguageVisitor visitor)
          Method for accepting a visitor.
 WindowFunction clone()
          Return a copy of this object.
 boolean equals(java.lang.Object obj)
          Compare the symbol based ONLY on name.
 AggregateSymbol getFunction()
           
 java.lang.Class<?> getType()
          Get the return type of this expression.
 WindowSpecification getWindowSpecification()
           
 int hashCode()
          Return a hash code for this symbol.
 boolean isResolved()
          Returns true if this symbol has been completely resolved with respect to actual runtime metadata.
 void setFunction(AggregateSymbol expression)
           
 void setWindowSpecification(WindowSpecification windowSpecification)
           
 java.lang.String toString()
          Returns string representation of this symbol.
 
Methods inherited from class org.teiid.query.sql.symbol.SingleElementSymbol
getShortName
 
Methods inherited from class org.teiid.query.sql.symbol.Symbol
getCanonical, getCanonicalName, getName, getOutputName, getShortCanonicalName, getShortName, setName, setOutputName, setShortCanonicalName, setShortName
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WindowFunction

public WindowFunction(java.lang.String name)

WindowFunction

protected WindowFunction(java.lang.String name,
                         java.lang.String canonical)
Method Detail

getFunction

public AggregateSymbol getFunction()

setFunction

public void setFunction(AggregateSymbol expression)

getWindowSpecification

public WindowSpecification getWindowSpecification()

setWindowSpecification

public void setWindowSpecification(WindowSpecification windowSpecification)

getType

public java.lang.Class<?> getType()
Description copied from interface: Expression
Get the return type of this expression. This method will not necessarily work right before resolution (Expression.isResolved() returns true).

Returns:
Java class name

isResolved

public boolean isResolved()
Description copied from class: Symbol
Returns true if this symbol has been completely resolved with respect to actual runtime metadata. A resolved symbol has been validated that it refers to actual metadata and will have references to the real metadata IDs if necessary. Different types of symbols determine their resolution in different ways, so this method is abstract and must be implemented by subclasses.

Specified by:
isResolved in interface Expression
Specified by:
isResolved in class Symbol
Returns:
True if resolved with runtime metadata

acceptVisitor

public void acceptVisitor(LanguageVisitor visitor)
Description copied from interface: LanguageObject
Method for accepting a visitor. It is the responsibility of the language object to call back on the visitor.

Parameters:
visitor - Visitor being used

hashCode

public int hashCode()
Description copied from class: Symbol
Return a hash code for this symbol.

Overrides:
hashCode in class Symbol
Returns:
Hash code

equals

public boolean equals(java.lang.Object obj)
Description copied from class: Symbol
Compare the symbol based ONLY on name. Symbols are not compared based on their underlying physical metadata IDs but rather on their representation in the context of a particular query. Case is not important when comparing symbol names.

Overrides:
equals in class Symbol
Parameters:
obj - Other object
Returns:
True if other obj is a Symbol (or subclass) and name is equal

clone

public WindowFunction clone()
Description copied from class: Symbol
Return a copy of this object.

Specified by:
clone in interface LanguageObject
Specified by:
clone in class Symbol
Returns:
Deep clone of this object

toString

public java.lang.String toString()
Description copied from class: Symbol
Returns string representation of this symbol.

Overrides:
toString in class Symbol
Returns:
String representing the symbol


Copyright © 2011. All Rights Reserved.