EclipseLink 2.4.2, build 'v20130514-5956486' API Reference

org.eclipse.persistence.jpa.jpql.model
Class AbstractSelectExpressionStateObjectBuilder

java.lang.Object
  extended by org.eclipse.persistence.jpa.jpql.model.AbstractStateObjectBuilder
      extended by org.eclipse.persistence.jpa.jpql.model.AbstractScalarExpressionStateObjectBuilder<ISelectExpressionStateObjectBuilder>
          extended by org.eclipse.persistence.jpa.jpql.model.AbstractSelectExpressionStateObjectBuilder
All Implemented Interfaces:
IScalarExpressionStateObjectBuilder<ISelectExpressionStateObjectBuilder>, ISelectExpressionStateObjectBuilder
Direct Known Subclasses:
AbstractEclipseLinkSelectExpressionStateObjectBuilder, DefaultSelectExpressionStateObjectBuilder

public abstract class AbstractSelectExpressionStateObjectBuilder
extends AbstractScalarExpressionStateObjectBuilder<ISelectExpressionStateObjectBuilder>
implements ISelectExpressionStateObjectBuilder

Version:
2.4
Author:
Pascal Filion
Since:
2.4

Field Summary
protected  java.util.List<StateObject> stateObjectList
          The list of select items, which were added by invoking #append(ISelectExpressionStateObjectBuilder).
 
Constructor Summary
protected AbstractSelectExpressionStateObjectBuilder(SelectClauseStateObject parent)
          Creates a new AbstractSelectExpressionStateObjectBuilder.
 
Method Summary
 ISelectExpressionStateObjectBuilder append()
          Appends the previously created select item and starts a new stack to create a new select item.
 void commit()
          Pushes the changes created by this builder to the state object.
protected  SelectClauseStateObject getParent()
          Returns the parent of the expression to build, which is only required when a JPQL fragment needs to be parsed.
 ISelectExpressionStateObjectBuilder new_(java.lang.String className, ISelectExpressionStateObjectBuilder... parameters)
          Creates the expression NEW constructor_name(identification_variable).
 ISelectExpressionStateObjectBuilder object(java.lang.String identificationVariable)
          Creates the expression OBJECT(identification_variable).
 ISelectExpressionStateObjectBuilder resultVariable(java.lang.String resultVariable)
          Defines the current state object with the given result variable.
protected  void resultVariable(java.lang.String resultVariable, boolean as)
           
 ISelectExpressionStateObjectBuilder resultVariableAs(java.lang.String resultVariable)
          Defines the current state object with the given result variable.
 ISelectExpressionStateObjectBuilder variable(java.lang.String variable)
          Creates the expression representing an identification variable.
 
Methods inherited from class org.eclipse.persistence.jpa.jpql.model.AbstractScalarExpressionStateObjectBuilder
abs, add, arithmetic, avg, avg, avgDistinct, buildCollectionPath, buildIdentificationVariable, buildInputParameter, buildNumeric, buildNumeric, buildStateFieldPath, buildStringLiteral, case_, coalesce, concat, count, count, countDistinct, currentDate, currentTime, currentTimestamp, date, divide, entityType, enumLiteral, function, function, getCaseBuilder, index, length, literal, literals, locate, locate, max, max, maxDistinct, min, min, minDistinct, minus, mod, multiply, nullIf, numeric, numeric, parameter, path, plus, size, sqrt, stateObjects, stateObjects, string, sub, subtract, sum, sum, sumDistinct, type
 
Methods inherited from class org.eclipse.persistence.jpa.jpql.model.AbstractStateObjectBuilder
add, checkBuilder, checkBuilders, hasStateObjects, pop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.persistence.jpa.jpql.model.IScalarExpressionStateObjectBuilder
abs, add, avg, avgDistinct, case_, coalesce, concat, count, countDistinct, currentDate, currentTime, currentTimestamp, date, divide, entityType, enumLiteral, function, function, getCaseBuilder, index, length, locate, locate, max, maxDistinct, min, minDistinct, minus, mod, multiply, nullIf, numeric, numeric, parameter, path, plus, size, sqrt, string, sub, subtract, sum, sumDistinct, type
 

Field Detail

stateObjectList

protected java.util.List<StateObject> stateObjectList
The list of select items, which were added by invoking #append(ISelectExpressionStateObjectBuilder).

Constructor Detail

AbstractSelectExpressionStateObjectBuilder

protected AbstractSelectExpressionStateObjectBuilder(SelectClauseStateObject parent)
Creates a new AbstractSelectExpressionStateObjectBuilder.

Parameters:
parent - The select clause for which this builder can create a select expression
Method Detail

append

public ISelectExpressionStateObjectBuilder append()
Appends the previously created select item and starts a new stack to create a new select item.

Specified by:
append in interface ISelectExpressionStateObjectBuilder
Returns:
This builder

commit

public void commit()
Pushes the changes created by this builder to the state object.

Specified by:
commit in interface ISelectExpressionStateObjectBuilder

getParent

protected SelectClauseStateObject getParent()
Returns the parent of the expression to build, which is only required when a JPQL fragment needs to be parsed.

Overrides:
getParent in class AbstractScalarExpressionStateObjectBuilder<ISelectExpressionStateObjectBuilder>
Returns:
The parent

new_

public ISelectExpressionStateObjectBuilder new_(java.lang.String className,
                                                ISelectExpressionStateObjectBuilder... parameters)
Creates the expression NEW constructor_name(identification_variable).

Specified by:
new_ in interface ISelectExpressionStateObjectBuilder
Parameters:
className - The fully qualified class name
parameters - The parameters of the constructor
Returns:
This builder

object

public ISelectExpressionStateObjectBuilder object(java.lang.String identificationVariable)
Creates the expression OBJECT(identification_variable).

Specified by:
object in interface ISelectExpressionStateObjectBuilder
Parameters:
identificationVariable - The identification variable
Returns:
This builder

resultVariable

public ISelectExpressionStateObjectBuilder resultVariable(java.lang.String resultVariable)
Defines the current state object with the given result variable.

Specified by:
resultVariable in interface ISelectExpressionStateObjectBuilder
Parameters:
resultVariable - The variable identifying the current select expression
Returns:
This builder

resultVariable

protected void resultVariable(java.lang.String resultVariable,
                              boolean as)

resultVariableAs

public ISelectExpressionStateObjectBuilder resultVariableAs(java.lang.String resultVariable)
Defines the current state object with the given result variable.

Specified by:
resultVariableAs in interface ISelectExpressionStateObjectBuilder
Parameters:
resultVariable - The variable identifying the current select expression
Returns:
This builder

variable

public ISelectExpressionStateObjectBuilder variable(java.lang.String variable)
Creates the expression representing an identification variable.

Specified by:
variable in interface ISelectExpressionStateObjectBuilder
Parameters:
variable - The identification variable
Returns:
This builder

EclipseLink 2.4.2, build 'v20130514-5956486' API Reference