int lhsColumnSpan, int rhsColumnSpan ) {
String[] lhsElementTexts = extractMutationTexts( getLeftHandOperand(),
lhsColumnSpan );
Node rhsNode = (Node) getInList().getFirstChild();
ParameterSpecification lhsEmbeddedCompositeParameterSpecification = getLeftHandOperand() == null
|| ( !ParameterNode.class.isInstance( getLeftHandOperand() ) ) ? null
: ( (ParameterNode) getLeftHandOperand() )
.getHqlParameterSpecification();
/**
* only one element in "in" cluster, e.g.
* <code> where (a,b) in ( (1,2) ) </code> this will be mutated to
* <code>where a=1 and b=2 </code>
*/
if ( rhsNode != null && rhsNode.getNextSibling() == null ) {
String[] rhsElementTexts = extractMutationTexts( rhsNode,
rhsColumnSpan );
setType( HqlSqlTokenTypes.AND );
setText( "AND" );
ParameterSpecification rhsEmbeddedCompositeParameterSpecification = rhsNode == null
|| ( !ParameterNode.class.isInstance( rhsNode ) ) ? null
: ( (ParameterNode) rhsNode )
.getHqlParameterSpecification();
translate( lhsColumnSpan, HqlSqlTokenTypes.EQ, "=", lhsElementTexts,
rhsElementTexts,
lhsEmbeddedCompositeParameterSpecification,
rhsEmbeddedCompositeParameterSpecification, this );
} else {
List andElementsNodeList = new ArrayList();
while ( rhsNode != null ) {
String[] rhsElementTexts = extractMutationTexts( rhsNode,
rhsColumnSpan );
AST and = getASTFactory().create( HqlSqlTokenTypes.AND, "AND" );
ParameterSpecification rhsEmbeddedCompositeParameterSpecification = rhsNode == null
|| ( !ParameterNode.class.isInstance( rhsNode ) ) ? null
: ( (ParameterNode) rhsNode )
.getHqlParameterSpecification();
translate( lhsColumnSpan, HqlSqlTokenTypes.EQ, "=",
lhsElementTexts, rhsElementTexts,