Top Description Fields Constructors Methods
org.h2.expression.function.table

public abstract Class TableFunction

extends Object
implements HasSQL, NamedExpression, ExpressionWithVariableParameters
Class Inheritance
All Implemented Interfaces
org.h2.expression.ExpressionWithVariableParameters, org.h2.expression.function.NamedExpression, org.h2.util.HasSQL
Known Direct Subclasses
org.h2.expression.function.table.ArrayTableFunction, org.h2.expression.function.table.CSVReadFunction, org.h2.expression.function.table.JavaTableFunction, org.h2.expression.function.table.LinkSchemaFunction
Imports
java.util.Arrays, org.h2.engine.SessionLocal, org.h2.expression.Expression, .ExpressionWithVariableParameters, org.h2.expression.function.NamedExpression, org.h2.message.DbException, org.h2.result.ResultInterface, org.h2.util.HasSQL

A table value function.

Field Summary

Modifier and TypeField and Description
protected Expression[]
private int

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public void
addParameter(Expression
the expression
param
)

Implements org.h2.expression.ExpressionWithVariableParameters.addParameter.

Adds the parameter expression.

public void
doneWithParameters()

Implements org.h2.expression.ExpressionWithVariableParameters.doneWithParameters.

This method must be called after all the parameters have been set.

public StringBuilder
getSQL(StringBuilder
string builder
builder
,
int
formatting flags
sqlFlags
)

Implements org.h2.util.HasSQL.getSQL.

Appends the SQL statement of this object to the specified builder.

public abstract ResultInterface

Returns:

the result
getValue
(SessionLocal
the session
session
)

Get a result with.

public abstract ResultInterface

Returns:

the empty result
getValueTemplate
(SessionLocal
the session
session
)

Get an empty result with the column names set.

public abstract boolean

Returns:

true if it does
isDeterministic
()

Whether the function always returns the same result for the same parameters.

public void
optimize(SessionLocal
the session
session
)

Try to optimize this table function

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

argsback to summary
protected Expression[] args
argsCountback to summary
private int argsCount

Constructor Detail

TableFunctionback to summary
protected TableFunction(Expression[] args)

Method Detail

addParameterback to summary
public void addParameter(Expression param)

Implements org.h2.expression.ExpressionWithVariableParameters.addParameter.

Doc from org.h2.expression.ExpressionWithVariableParameters.addParameter.

Adds the parameter expression.

Parameters
param:Expression

the expression

Annotations
@Override
doneWithParametersback to summary
public void doneWithParameters() throws DbException

Implements org.h2.expression.ExpressionWithVariableParameters.doneWithParameters.

Doc from org.h2.expression.ExpressionWithVariableParameters.doneWithParameters.

This method must be called after all the parameters have been set. It checks if the parameter count is correct when required by the implementation.

Annotations
@Override
Exceptions
DbException:
if the parameter count is incorrect.
getSQLback to summary
public StringBuilder getSQL(StringBuilder builder, int sqlFlags)

Implements org.h2.util.HasSQL.getSQL.

Doc from org.h2.util.HasSQL.getSQL.

Appends the SQL statement of this object to the specified builder.

Parameters
builder:StringBuilder

string builder

sqlFlags:int

formatting flags

Returns:StringBuilder

the specified string builder

Annotations
@Override
getValueback to summary
public abstract ResultInterface getValue(SessionLocal session)

Get a result with.

Parameters
session:SessionLocal

the session

Returns:ResultInterface

the result

getValueTemplateback to summary
public abstract ResultInterface getValueTemplate(SessionLocal session)

Get an empty result with the column names set.

Parameters
session:SessionLocal

the session

Returns:ResultInterface

the empty result

isDeterministicback to summary
public abstract boolean isDeterministic()

Whether the function always returns the same result for the same parameters.

Returns:boolean

true if it does

optimizeback to summary
public void optimize(SessionLocal session)

Try to optimize this table function

Parameters
session:SessionLocal

the session