org.hibernate.sql.Select class, but changed up slightly to better meet needs
of building a SQL SELECT statement from a LoadPlan
| Modifier and Type | Field and Description |
|---|---|
| private String | |
| public final Dialect | |
| private StringBuilder | |
| private int | |
| private LockOptions | |
| private StringBuilder | |
| private String | |
| private String | |
| private StringBuilder | |
| private StringBuilder |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void | appendFromClauseFragment(String
The table name. tableName, String The table alias. alias)Appends the specified table name and alias as a from clause fragment. |
| public void | appendOrderByFragment(String
The "order by" fragment to append. ordering)Appends the "order by" fragment, prefixed by a comma if the "order by" fragment already exists. |
| public void | appendRestrictions(String
The restrictions. restrictions)Appends the specified restrictions after "cleaning" the specified value (by trimming and removing 'and ' from beginning and ' and' from the end). |
| public void | |
| private String | |
| private boolean | |
| private boolean | |
| public void | |
| public void | |
| public void | setLockOptions(LockOptions
The lock options. lockOptions)Sets the lock options for the select statement. |
| public void | setOuterJoins(String
The outer join fragment to be appended to the "from" clause. outerJoinsAfterFrom, String The outer join fragment to be appended to the "where" clause. outerJoinsAfterWhere)Sets the outer join fragments to be added to the "from" and "where" clauses. |
| public String | Returns: the SQL SELECT statement.Construct an SQL SELECT statement from the given clauses. |
| comment | back to summary |
|---|---|
| private String comment | |
| dialect | back to summary |
|---|---|
| public final Dialect dialect | |
| fromClause | back to summary |
|---|---|
| private StringBuilder fromClause | |
| guesstimatedBufferSize | back to summary |
|---|---|
| private int guesstimatedBufferSize | |
| lockOptions | back to summary |
|---|---|
| private LockOptions lockOptions | |
| orderByClause | back to summary |
|---|---|
| private StringBuilder orderByClause | |
| outerJoinsAfterFrom | back to summary |
|---|---|
| private String outerJoinsAfterFrom | |
| outerJoinsAfterWhere | back to summary |
|---|---|
| private String outerJoinsAfterWhere | |
| selectClause | back to summary |
|---|---|
| private StringBuilder selectClause | |
| whereClause | back to summary |
|---|---|
| private StringBuilder whereClause | |
| SelectStatementBuilder | back to summary |
|---|---|
| public SelectStatementBuilder(Dialect dialect) Constructs a select statement builder object.
| |
| appendFromClauseFragment | back to summary |
|---|---|
| public void appendFromClauseFragment(String fragment) Appends the from clause fragment.
| |
| appendFromClauseFragment | back to summary |
|---|---|
| public void appendFromClauseFragment(String tableName, String alias) Appends the specified table name and alias as a from clause fragment. | |
| appendOrderByFragment | back to summary |
|---|---|
| public void appendOrderByFragment(String ordering) Appends the "order by" fragment, prefixed by a comma if the "order by" fragment already exists.
| |
| appendRestrictions | back to summary |
|---|---|
| public void appendRestrictions(String restrictions) Appends the specified restrictions after "cleaning" the specified value (by trimming and removing 'and ' from beginning and ' and' from the end). If the where clause already exists, this method ensure that ' and ' prefixes the cleaned restrictions.
| |
| appendSelectClauseFragment | back to summary |
|---|---|
| public void appendSelectClauseFragment(String selection) Appends a select clause fragment
| |
| cleanRestrictions | back to summary |
|---|---|
| private String cleanRestrictions(String restrictions) | |
| isNotEmpty | back to summary |
|---|---|
| private boolean isNotEmpty(String string) | |
| isNotEmpty | back to summary |
|---|---|
| private boolean isNotEmpty(StringBuilder builder) | |
| setComment | back to summary |
|---|---|
| public void setComment(String comment) Sets the comment for the select statement.
| |
| setLockMode | back to summary |
|---|---|
| public void setLockMode(LockMode lockMode) Sets the lock mode for the select statement.
| |
| setLockOptions | back to summary |
|---|---|
| public void setLockOptions(LockOptions lockOptions) Sets the lock options for the select statement.
| |
| setOuterJoins | back to summary |
|---|---|
| public void setOuterJoins(String outerJoinsAfterFrom, String outerJoinsAfterWhere) Sets the outer join fragments to be added to the "from" and "where" clauses. | |
| toStatementString | back to summary |
|---|---|
| public String toStatementString() Construct an SQL SELECT statement from the given clauses.
| |