Class StandardBuilder
java.lang.Object
org.apache.torque.sql.whereclausebuilder.AbstractWhereClausePsPartBuilder
org.apache.torque.sql.whereclausebuilder.StandardBuilder
- All Implemented Interfaces:
WhereClausePsPartBuilder
Builds a PreparedStatementPart from a WhereClauseExpression which
RHS and LHS is a simple value.
- Version:
- $Id: StandardBuilder.java 1839288 2018-08-27 09:48:33Z tv $
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuildPs(WhereClauseExpression whereClausePart, boolean ignoreCase, Query query, Adapter adapter) Builds a PreparedStatementPart from a WhereClauseExpression which RHS and LHS is a simple value.booleanisApplicable(WhereClauseExpression whereClauseExpression, Adapter adapter) Returns whether this WhereClausePsPartBuilder is applicable for a given WhereClauseExpression.Methods inherited from class org.apache.torque.sql.whereclausebuilder.AbstractWhereClausePsPartBuilder
getObjectOrColumnPsPartBuilder, setObjectOrColumnPsPartBuilder
-
Constructor Details
-
StandardBuilder
public StandardBuilder()
-
-
Method Details
-
buildPs
public PreparedStatementPart buildPs(WhereClauseExpression whereClausePart, boolean ignoreCase, Query query, Adapter adapter) throws TorqueException Builds a PreparedStatementPart from a WhereClauseExpression which RHS and LHS is a simple value.- Parameters:
whereClausePart- the part of the where clause to build. Can be modified in this method.ignoreCase- If true and columns represent Strings, the appropriate function defined for the database will be used to ignore differences in case.query- the query which is currently builtadapter- The adapter for the database for which the SQL should be created, not null.- Returns:
- the rendered SQL for the WhereClauseExpression
- Throws:
TorqueException- when rendering fails.
-
isApplicable
Returns whether this WhereClausePsPartBuilder is applicable for a given WhereClauseExpression.- Parameters:
whereClauseExpression- the WhereClauseExpression in question.adapter- The adapter for the database for which the SQL should be created, not null.- Returns:
- true if applicable, false otherwise.
-