public abstract class AbstractDomainObject extends AbstractPath implements DomainObject
_operator, _owner, _parent, _part2CLOSE_BRACE, COMMA, EMPTY, OPEN_BRACE, SPACE| Modifier | Constructor and Description |
|---|---|
protected |
AbstractDomainObject(QueryDefinitionImpl owner,
AbstractPath parent,
PathOperator op,
Object part2) |
| Modifier and Type | Method and Description |
|---|---|
DomainObject |
addRoot(Class cls)
Adding a root adds a root domain to the owning query.
|
DomainObject |
addSubqueryRoot(PathExpression path)
Adding a query root adds a subquery to the owning query.
|
Subquery |
all()
Derives this path as ALL(subquery) to its owning query.
|
Subquery |
any()
Adds this path as ANY(subquery) to its owning query.
|
Expression |
coalesce(Calendar... exp)
coalesce This is equivalent to a case expression that returns null if all
its arguments evaluate to null, and the value of its first non-null
argument otherwise.
|
Expression |
coalesce(Date... exp)
coalesce This is equivalent to a case expression that returns null if all
its arguments evaluate to null, and the value of its first non-null
argument otherwise.
|
Expression |
coalesce(Expression... exp)
coalesce This is equivalent to a case expression that returns null if all
its arguments evaluate to null, and the value of its first non-null
argument otherwise.
|
Expression |
coalesce(String... exp)
coalesce This is equivalent to a case expression that returns null if all
its arguments evaluate to null, and the value of its first non-null
argument otherwise.
|
Expression |
currentDate()
Create an Expression corresponding to the current date on the database
server at the time of query execution.
|
Expression |
currentTime()
Create an Expression corresponding to the current time on the database
server at the time of query execution.
|
Expression |
currentTimestamp()
Create an Expression corresponding to the current timestamp on the
database server at the time of query execution.
|
SelectItem |
entry()
Derives by ENTRY() operation on this path.
|
Predicate |
exists()
Adds this path as EXISTS(subquery) to its owning query.
|
CaseExpression |
generalCase()
Create an empty general case expression.
|
PathExpression |
get(String attr)
Derives a path from this path by navigating through the given field.
|
QueryDefinition |
groupBy(List<PathExpression> pathExprList)
Specify the items that are used to form groups over the query results.
|
QueryDefinition |
groupBy(PathExpression... pathExprs)
Specify the items that are used to form groups over the query results.
|
QueryDefinition |
having(Predicate predicate)
Specify the restrictions over the groups of a query.
|
Expression |
index()
Derives by INDEX() operation on this path.
|
DomainObject |
join(String attr)
Derives a path from this path by joining the given field.
|
FetchJoinObject |
joinFetch(String attr)
Derives a path from this path by fetch joining the given field.
|
PathExpression |
key()
Derives by KEY() operation on this path.
|
DomainObject |
leftJoin(String attr)
Derives a path from this path by outer joining the given field.
|
FetchJoinObject |
leftJoinFetch(String attr)
Derives a path from this path by fetch joining the given field.
|
Expression |
literal(boolean b)
Create an Expression corresponding to a boolean value.
|
Expression |
literal(Calendar c)
Create an Expression corresponding to a Calendar value.
|
Expression |
literal(char c)
Create an Expression corresponding to a character value.
|
Expression |
literal(Class cls)
Create an Expression corresponding to an entity class.
|
Expression |
literal(Date d)
Create an Expression corresponding to a Date value.
|
Expression |
literal(Enum<?> e)
Create an Expression corresponding to an enum.
|
Expression |
literal(Number n)
Create an Expression corresponding to a numeric value.
|
Expression |
literal(String s)
Create an Expression corresponding to a String value.
|
SelectItem |
newInstance(Class cls,
SelectItem... args)
Specify that a constructor for the given class is to be applied to the
corresponding query results after the query is executed.
|
Expression |
nullif(Calendar arg1,
Calendar arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(Class arg1,
Class arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(Date arg1,
Date arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(Enum<?> arg1,
Enum<?> arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(Expression exp1,
Expression exp2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(Number arg1,
Number arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullif(String arg1,
String arg2)
nullif This is equivalent to a case expression that tests whether its
arguments are equal, returning null if they are and the value of the
first expression if they are not.
|
Expression |
nullLiteral()
Create an Expression corresponding to a null value.
|
QueryDefinition |
orderBy(List<OrderByItem> orderByItemList)
Specify the items of the select list that are used in ordering the query
results.
|
QueryDefinition |
orderBy(OrderByItem... orderByItems)
Specify the items of the select list that are used in ordering the query
results.
|
Expression |
param(String name)
Specify use of a parameter of the given name.
|
Predicate |
predicate(boolean b)
Create a predicate value from the given boolean.
|
QueryDefinition |
select(List<SelectItem> selectItemList)
Specify the objects / values to be returned.
|
QueryDefinition |
select(SelectItem... selectItems)
Specify the objects / values to be returned.
|
QueryDefinition |
selectDistinct(List<SelectItem> selectItemList)
Specify the objects / values to be returned.
|
QueryDefinition |
selectDistinct(SelectItem... selectItems)
Specify the objects / values to be returned.
|
CaseExpression |
simpleCase(Calendar caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(Class caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(Date caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(Enum<?> caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(Expression caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(Number caseOperand)
Create a simple case expression with the given case operand.
|
CaseExpression |
simpleCase(String caseOperand)
Create a simple case expression with the given case operand.
|
Subquery |
some()
Adds this path as SOME(subquery) to its owning query.
|
PathExpression |
value()
Derives a path by VALUE() operation on this path.
|
QueryDefinition |
where(Predicate predicate)
Modifies the query definition to restrict the result of the query
according to the specified predicate.
|
avg, count, getLastSegment, getOperator, getOwner, getParent, isEmpty, max, min, size, split, sum, typeabs, asc, between, between, between, between, between, between, between, between, between, between, between, between, between, concat, concat, desc, dividedBy, dividedBy, equal, equal, equal, equal, equal, equal, equal, equal, getAliasHint, greaterEqual, greaterEqual, greaterEqual, greaterEqual, greaterEqual, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, in, in, in, in, in, in, isNull, length, lessEqual, lessEqual, lessEqual, lessEqual, lessEqual, lessThan, lessThan, lessThan, lessThan, lessThan, like, like, like, like, like, like, locate, locate, locate, locate, locate, locate, lower, member, minus, minus, minus, mod, mod, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, plus, plus, sqrt, substring, substring, substring, substring, substring, substring, times, times, trim, trim, trim, trim, trim, trim, upperasExpression, asJoinable, asProjectionclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitavg, count, isEmpty, max, min, size, sum, typeabs, concat, concat, dividedBy, dividedBy, in, in, in, in, in, in, isNull, length, locate, locate, locate, locate, locate, locate, lower, member, minus, minus, minus, mod, mod, plus, plus, sqrt, substring, substring, substring, substring, substring, substring, times, times, trim, trim, trim, trim, trim, trim, upperasc, descbetween, between, between, between, between, between, between, between, between, between, between, between, between, equal, equal, equal, equal, equal, equal, equal, equal, greaterEqual, greaterEqual, greaterEqual, greaterEqual, greaterEqual, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, lessEqual, lessEqual, lessEqual, lessEqual, lessEqual, lessThan, lessThan, lessThan, lessThan, lessThan, like, like, like, like, like, like, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqual, notEqualasExpression, asJoinable, asProjectionprotected AbstractDomainObject(QueryDefinitionImpl owner, AbstractPath parent, PathOperator op, Object part2)
public DomainObject addRoot(Class cls)
addRoot in interface QueryDefinitioncls - -
an entity classpublic DomainObject addSubqueryRoot(PathExpression path)
addSubqueryRoot in interface QueryDefinitionpath - -
path expression corresponding to the domain object used to
derive the subquery root.public PathExpression get(String attr)
get in interface PathExpressionattr - -
name of the referenced attributepublic DomainObject join(String attr)
join in interface DomainObjectattr - -
name of the attribute that references the target of the
joinpublic DomainObject leftJoin(String attr)
leftJoin in interface DomainObjectattr - -
name of the attribute that references the target of the
joinpublic FetchJoinObject joinFetch(String attr)
joinFetch in interface DomainObjectattr - -
name of the attribute that references the target of the
joinpublic FetchJoinObject leftJoinFetch(String attr)
leftJoinFetch in interface DomainObjectattr - -
name of the attribute that references the target of the
joinpublic PathExpression key()
key in interface DomainObjectpublic SelectItem entry()
entry in interface DomainObjectpublic Expression index()
index in interface DomainObjectpublic PathExpression value()
value in interface DomainObjectpublic Subquery all()
all in interface QueryDefinitionpublic Subquery any()
any in interface QueryDefinitionpublic Subquery some()
some in interface QueryDefinitionpublic Predicate exists()
exists in interface QueryDefinitionpublic Expression coalesce(Expression... exp)
QueryDefinitioncoalesce in interface QueryDefinitionexp - -
expressions to be used for testing against nullpublic Expression coalesce(String... exp)
QueryDefinitioncoalesce in interface QueryDefinitionexp - -
expressions to be used for testing against nullpublic Expression coalesce(Date... exp)
QueryDefinitioncoalesce in interface QueryDefinitionexp - -
expressions to be used for testing against nullpublic Expression coalesce(Calendar... exp)
QueryDefinitioncoalesce in interface QueryDefinitionexp - -
expressions to be used for testing against nullpublic Expression currentDate()
QueryDefinitioncurrentDate in interface QueryDefinitionpublic Expression currentTime()
QueryDefinitioncurrentTime in interface QueryDefinitionpublic Expression currentTimestamp()
QueryDefinitioncurrentTimestamp in interface QueryDefinitionpublic CaseExpression generalCase()
QueryDefinitiongeneralCase in interface QueryDefinitionpublic QueryDefinition groupBy(PathExpression... pathExprs)
QueryDefinitiongroupBy in interface QueryDefinitionpublic QueryDefinition groupBy(List<PathExpression> pathExprList)
QueryDefinitiongroupBy in interface QueryDefinitionpublic QueryDefinition having(Predicate predicate)
QueryDefinitionhaving in interface QueryDefinitionpublic Expression literal(String s)
QueryDefinitionliteral in interface QueryDefinitions - -
string valuepublic Expression literal(Number n)
QueryDefinitionliteral in interface QueryDefinitionn - -
numeric valuepublic Expression literal(boolean b)
QueryDefinitionliteral in interface QueryDefinitionb - -
boolean valuepublic Expression literal(Calendar c)
QueryDefinitionliteral in interface QueryDefinitionc - -
Calendar valuepublic Expression literal(Date d)
QueryDefinitionliteral in interface QueryDefinitiond - -
Date valuepublic Expression literal(char c)
QueryDefinitionliteral in interface QueryDefinitionpublic Expression literal(Class cls)
QueryDefinitionliteral in interface QueryDefinitioncls - -
entity classpublic Expression literal(Enum<?> e)
QueryDefinitionliteral in interface QueryDefinitione - -
enumpublic SelectItem newInstance(Class cls, SelectItem... args)
QueryDefinitionnewInstance in interface QueryDefinitioncls - -
a class with the correponding constructorargs - -
select items that correspond to result types that are valid
as arguments to the constructorpublic Expression nullLiteral()
QueryDefinitionnullLiteral in interface QueryDefinitionpublic Expression nullif(Expression exp1, Expression exp2)
QueryDefinitionnullif in interface QueryDefinitionpublic Expression nullif(Number arg1, Number arg2)
QueryDefinitionnullif in interface QueryDefinitionpublic Expression nullif(String arg1, String arg2)
QueryDefinitionnullif in interface QueryDefinitionarg2 - Criteria API Java Persistence 2.0, Public Review Draft
Criteria API Interfaces 10/31/08 158 JSR-317 Public Review
Draft Sun Microsystems, Inc.public Expression nullif(Date arg1, Date arg2)
QueryDefinitionnullif in interface QueryDefinitionpublic Expression nullif(Calendar arg1, Calendar arg2)
QueryDefinitionnullif in interface QueryDefinitionpublic Expression nullif(Class arg1, Class arg2)
QueryDefinitionnullif in interface QueryDefinitionpublic Expression nullif(Enum<?> arg1, Enum<?> arg2)
QueryDefinitionnullif in interface QueryDefinitionpublic QueryDefinition orderBy(OrderByItem... orderByItems)
QueryDefinitionorderBy in interface QueryDefinitionorderByItems - -
one or more OrderByItem instancespublic QueryDefinition orderBy(List<OrderByItem> orderByItemList)
QueryDefinitionorderBy in interface QueryDefinitionorderByItemList - -
a list containing one or more OrderByItem
instancespublic Expression param(String name)
QueryDefinitionparam in interface QueryDefinitionpublic Predicate predicate(boolean b)
QueryDefinitionpredicate in interface QueryDefinitionb - boolean valuepublic QueryDefinition select(SelectItem... selectItems)
QueryDefinitionselect in interface QueryDefinitionselectItems - -
one or more SelectItem instancespublic QueryDefinition select(List<SelectItem> selectItemList)
QueryDefinitionselect in interface QueryDefinitionselectItemList - -
a list containing one or more SelectItem instancespublic QueryDefinition selectDistinct(SelectItem... selectItems)
QueryDefinitionselectDistinct in interface QueryDefinitionselectItems - -
one or more SelectItem instancespublic QueryDefinition selectDistinct(List<SelectItem> selectItemList)
QueryDefinitionselectDistinct in interface QueryDefinitionselectItemList - -
a list containing one or more SelectItem instancespublic CaseExpression simpleCase(Expression caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
expression used for testing against the when scalar
expressionspublic CaseExpression simpleCase(Number caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
numeric value used for testing against the when scalar
expressionspublic CaseExpression simpleCase(String caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
value used for testing against the when scalar
expressionspublic CaseExpression simpleCase(Date caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
value used for testing against the when scalar
expressionspublic CaseExpression simpleCase(Calendar caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
value used for testing against the when scalar
expressionspublic CaseExpression simpleCase(Class caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
value used for testing against the when scalar
expressionspublic CaseExpression simpleCase(Enum<?> caseOperand)
QueryDefinitionsimpleCase in interface QueryDefinitioncaseOperand - -
value used for testing against the when scalar
expressionspublic QueryDefinition where(Predicate predicate)
QueryDefinitionwhere in interface QueryDefinitionpredicate - -
a simple or compound conditional predicateCopyright © 2006–2013 Apache Software Foundation. All rights reserved.