public class FunctionExpression extends Expression
| Modifier and Type | Field and Description |
|---|---|
protected Expression |
baseExpression |
protected java.util.Vector |
children |
protected ExpressionOperator |
operator |
protected ExpressionOperator |
platformOperator |
protected java.lang.Class |
resultType |
currentAlias, lastTable, selectIfOrderedBy| Constructor and Description |
|---|
FunctionExpression() |
| Modifier and Type | Method and Description |
|---|---|
void |
addChild(Expression child) |
DatabaseTable |
aliasForTable(DatabaseTable table)
INTERNAL:
Find the alias for a given table
|
Expression |
create(Expression base,
java.lang.Object singleArgument,
ExpressionOperator operator)
INTERNAL:
|
Expression |
create(Expression base,
java.util.Vector arguments,
ExpressionOperator operator)
INTERNAL:
|
Expression |
createWithBaseLast(Expression base,
java.lang.Object singleArgument,
ExpressionOperator anOperator)
INTERNAL:
added for Trim support.
|
java.lang.String |
descriptionOfNodeType()
INTERNAL:
Used for debug printing.
|
boolean |
doesConform(java.lang.Object object,
AbstractSession session,
AbstractRecord translationRow,
InMemoryQueryIndirectionPolicy valueHolderPolicy,
boolean isObjectUnregistered)
INTERNAL:
Check if the object conforms to the expression in memory.
|
Expression |
getBaseExpression() |
ExpressionBuilder |
getBuilder()
Return the expression builder which is the ultimate base of this expression, or
null if there isn't one (shouldn't happen if we start from a root)
|
java.util.Vector |
getChildren() |
java.util.Vector |
getFields()
INTERNAL: Not to be confused with the public getField(String)
This returns a collection of all fields associated with this object.
|
ExpressionOperator |
getOperator()
INTERNAL:
Most expression have operators, so this is just a convenience method.
|
ExpressionOperator |
getPlatformOperator(DatabasePlatform platform) |
java.lang.Class |
getResultType() |
boolean |
hasResultType() |
void |
initializePlatformOperator(DatabasePlatform platform)
INTERNAL:
|
boolean |
isFunctionExpression()
INTERNAL:
|
protected boolean |
isObjectComparison()
INTERNAL:
Return if the represents an object comparison.
|
void |
iterateOn(ExpressionIterator iterator)
INTERNAL:
For iterating using an inner class
|
Expression |
normalize(ExpressionNormalizer normalizer)
INTERNAL:
Normalize into a structure that is printable.
|
protected void |
postCopyIn(java.util.Dictionary alreadyDone)
INTERNAL:
Used for cloning.
|
void |
printInCollection(java.util.Vector items,
ExpressionSQLPrinter printer,
ExpressionOperator operator)
INTERNAL: Print the collection in "IN" onto the SQL stream.
|
void |
printJava(ExpressionJavaPrinter printer)
INTERNAL:
Print java for project class generation
|
void |
printSQL(ExpressionSQLPrinter printer)
INTERNAL:
Print SQL
|
Expression |
rebuildOn(Expression newBase)
INTERNAL:
This expression is built on a different base than the one we want.
|
void |
setBaseExpression(Expression expression)
Sets the base of the expression
Added to allow creation of functions which take the column name
as something other than the first option.
|
void |
setLocalBase(Expression exp)
INTERNAL:
Set the local base expression, ie the one on the other side of the operator
Most types will ignore this, since they don't need it.
|
void |
setOperator(ExpressionOperator theOperator) |
void |
setResultType(java.lang.Class resultType) |
Expression |
twistedForBaseAndContext(Expression newBase,
Expression context)
INTERNAL:
Rebuild myself against the base, with the values of parameters supplied by the context
expression.
|
java.lang.Object |
valueFromObject(java.lang.Object object,
AbstractSession session,
AbstractRecord translationRow,
InMemoryQueryIndirectionPolicy valueHolderPolicy,
boolean isObjectUnregistered)
INTERNAL:
Return the value for in memory comparison.
|
void |
writeDescriptionOn(java.io.BufferedWriter writer)
INTERNAL:
Used to print a debug form of the expression tree.
|
void |
writeFields(ExpressionSQLPrinter printer,
java.util.Vector newFields,
SQLSelectStatement statement)
INTERNAL: called from SQLSelectStatement.writeFieldsFromExpression(...)
|
void |
writeSubexpressionsTo(java.io.BufferedWriter writer,
int indent)
INTERNAL:
Used in SQL printing.
|
addDate, addDate, addMonths, addMonths, all, all, all, all, all, all, all, all, all, all, all, all, allOf, and, any, any, any, any, any, any, any, any, any, any, any, any, anyOf, anyOfAllowingNone, ascending, asciiValue, assignAlias, assignTableAliasesStartingAt, average, between, between, between, between, between, between, between, between, between, caseStatement, clone, cloneUsing, concat, containsAllKeyWords, containsAnyKeyWords, containsSubstring, containsSubstring, containsSubstringIgnoringCase, containsSubstringIgnoringCase, convertNodeToUseOuterJoin, convertToUseOuterJoin, copiedVersionFrom, count, currentDate, currentDateDate, currentTime, currentTimeStamp, dateDifference, dateDifference, dateName, datePart, dateToString, decode, descending, detectExpression, difference, distinct, doesConform, equal, equal, equal, equal, equal, equal, equal, equal, equal, equal, equalOuterJoin, equalOuterJoin, equalsIgnoreCase, equalsIgnoreCase, exists, existsNode, extract, extractPrimaryKeyValues, extractValue, from, fromConstant, fromLiteral, get, get, getAllowingNull, getAllowingNull, getClonedField, getField, getField, getFieldValue, getFunction, getFunction, getFunction, getFunction, getFunctionWithArguments, getName, getNumberVal, getOperator, getOwnedTables, getParameter, getParameter, getParameter, getSession, getStringVal, getTable, getTable, getTableAliases, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, greaterThanEqual, hasAsOfClause, hasBeenAliased, hexToRaw, ifNull, in, in, in, in, in, in, in, in, in, in, in, in, indexOf, isCompoundExpression, isConstantExpression, isDataExpression, isEmpty, isExpressionBuilder, isFieldExpression, isFragment, isLiteralExpression, isLogicalExpression, isNull, isObjectExpression, isParameterExpression, isQueryKeyExpression, isRelationExpression, isTableExpression, isValueExpression, lastDay, leftPad, leftPad, leftTrim, leftTrim, length, lessThan, lessThan, lessThan, lessThan, lessThan, lessThan, lessThan, lessThan, lessThan, lessThan, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, lessThanEqual, like, like, like, like, likeIgnoreCase, likeIgnoreCase, literal, locate, locate, locate, maximum, minimum, monthsBetween, newTime, nextDay, noneOf, not, notBetween, notBetween, notBetween, notBetween, notBetween, notBetween, notBetween, notBetween, notBetween, notEmpty, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notExists, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notIn, notLike, notLike, notNull, or, performOperator, postfixSQL, prefixSQL, printSQLWithoutConversion, ref, registerIn, replace, replicate, replicate, resetCache, reverse, right, right, rightPad, rightPad, rightTrim, rightTrim, roundDate, selectIfOrderedBy, setSelectIfOrderedBy, shallowClone, size, some, some, some, some, some, some, some, some, some, some, some, some, standardDeviation, subQuery, substring, substring, sum, toChar, toChar, toCharacter, toDate, toLowerCase, toNumber, toString, toString, toUpperCase, toUppercaseCasedWords, translate, trim, trim, truncateDate, twist, validateNode, value, value, value, value, value, value, value, value, value, value, valueFromObject, variance, writeFieldprotected Expression baseExpression
protected java.util.Vector children
protected ExpressionOperator operator
protected transient ExpressionOperator platformOperator
protected java.lang.Class resultType
public void addChild(Expression child)
public DatabaseTable aliasForTable(DatabaseTable table)
aliasForTable in class Expressionpublic Expression create(Expression base, java.lang.Object singleArgument, ExpressionOperator operator)
create in class Expressionpublic Expression createWithBaseLast(Expression base, java.lang.Object singleArgument, ExpressionOperator anOperator)
createWithBaseLast in class Expressionpublic Expression create(Expression base, java.util.Vector arguments, ExpressionOperator operator)
create in class Expressionpublic java.lang.String descriptionOfNodeType()
descriptionOfNodeType in class Expressionpublic boolean doesConform(java.lang.Object object,
AbstractSession session,
AbstractRecord translationRow,
InMemoryQueryIndirectionPolicy valueHolderPolicy,
boolean isObjectUnregistered)
doesConform in class Expressionpublic Expression getBaseExpression()
public ExpressionBuilder getBuilder()
getBuilder in class Expressionpublic java.util.Vector getChildren()
public java.util.Vector getFields()
getFields in class Expressionpublic ExpressionOperator getOperator()
ExpressiongetOperator in class Expressionpublic ExpressionOperator getPlatformOperator(DatabasePlatform platform)
public java.lang.Class getResultType()
public boolean hasResultType()
public void initializePlatformOperator(DatabasePlatform platform)
public boolean isFunctionExpression()
ExpressionisFunctionExpression in class Expressionprotected boolean isObjectComparison()
public void iterateOn(ExpressionIterator iterator)
iterateOn in class Expressionpublic Expression normalize(ExpressionNormalizer normalizer)
normalize in class Expressionprotected void postCopyIn(java.util.Dictionary alreadyDone)
postCopyIn in class Expressionpublic void printSQL(ExpressionSQLPrinter printer)
printSQL in class Expressionpublic void printInCollection(java.util.Vector items,
ExpressionSQLPrinter printer,
ExpressionOperator operator)
public void printJava(ExpressionJavaPrinter printer)
printJava in class Expressionpublic Expression rebuildOn(Expression newBase)
rebuildOn in class ExpressionExpression.cloneUsing(Expression newBase)public void setBaseExpression(Expression expression)
expression - oracle.toplink.essentials.expressions.Expressionpublic void setLocalBase(Expression exp)
ExpressionsetLocalBase in class Expressionpublic void setOperator(ExpressionOperator theOperator)
public void setResultType(java.lang.Class resultType)
public Expression twistedForBaseAndContext(Expression newBase, Expression context)
twistedForBaseAndContext in class Expressionpublic java.lang.Object valueFromObject(java.lang.Object object,
AbstractSession session,
AbstractRecord translationRow,
InMemoryQueryIndirectionPolicy valueHolderPolicy,
boolean isObjectUnregistered)
valueFromObject in class Expressionpublic void writeDescriptionOn(java.io.BufferedWriter writer)
throws java.io.IOException
writeDescriptionOn in class Expressionjava.io.IOExceptionpublic void writeFields(ExpressionSQLPrinter printer, java.util.Vector newFields, SQLSelectStatement statement)
writeFields in class Expressionpublic void writeSubexpressionsTo(java.io.BufferedWriter writer,
int indent)
throws java.io.IOException
writeSubexpressionsTo in class Expressionjava.io.IOException