/** * Check input parameter. * * @param expression * the expression * @return the string */ private String checkInputParameter(Expression expression) { return (expression instanceof InputParameter) ? kunderaQuery.getParametersMap() .get((expression).toParsedText()).toString() : expression.toParsedText().toString(); }
Object inValues = kunderaQuery.getParametersMap().get(inClauseValues.toParsedText()); log.debug(inClauseValues.toParsedText() + "named parameter found in query, Replacing parameter with " + inValues); : (Collection) kunderaQuery.getParametersMap().get(inClauseValues.toParsedText());
/** * Populate like query. * * @param likeExpression * the like expression * @param metadata * the metadata * @return the filter builder */ private QueryBuilder populateLikeQuery(LikeExpression likeExpression, EntityMetadata metadata) { Expression patternValue = likeExpression.getPatternValue(); String field = likeExpression.getStringExpression().toString(); String likePattern = (patternValue instanceof InputParameter) ? kunderaQuery.getParametersMap() .get((patternValue).toParsedText()).toString() : patternValue.toParsedText().toString(); String jpaField = getField(field); log.debug("Pattern value for field " + field + " is: " + patternValue); QueryBuilder filterBuilder = getQueryBuilder(kunderaQuery.new FilterClause(jpaField, Expression.LIKE, likePattern, field), metadata); return filterBuilder; }
if (kunderaQuery.getParametersMap().containsKey(ip.getParameter())) return kunderaQuery.getParametersMap().get(ip.getParameter());
|| boundExpression instanceof InputParameter) Object value = (boundExpression instanceof InputParameter) ? kunderaQuery.getParametersMap().get( (boundExpression).toParsedText()) : boundExpression.toParsedText(); return value.toString();
if (right.startsWith(POSITIONAL_PREFIX) || right.startsWith(PARAMETERIZED_PREFIX)) right = kunderaQuery.getParametersMap().get(right) + "";
Object items = getKunderaQuery().getParametersMap().get(param);
/** * Populate filter clause. * * @param conditionalExpression * the conditional expression * @return the filter clause */ private FilterClause populateFilterClause(ComparisonExpression conditionalExpression) { String property = ((StateFieldPathExpression) conditionalExpression.getLeftExpression()).getPath(1); String condition = conditionalExpression.getComparisonOperator(); Expression rightExpression = conditionalExpression.getRightExpression(); Object value = (rightExpression instanceof InputParameter) ? kunderaQuery.getParametersMap().get( (rightExpression).toParsedText()) : rightExpression.toParsedText(); return (condition != null && property != null) ? kunderaQuery.new FilterClause(property, condition, value, property) : null; }
if (right.startsWith(POSITIONAL_PREFIX) || right.startsWith(PARAMETERIZED_PREFIX)) right = kunderaQuery.getParametersMap().get(right) + "";
|| right.startsWith(CouchbaseConstants.PARAMETERIZED_PREFIX)) right = kunderaQuery.getParametersMap().get(right) + "";
/** * Check input parameter. * * @param expression * the expression * @return the string */ private String checkInputParameter(Expression expression) { return (expression instanceof InputParameter) ? kunderaQuery.getParametersMap() .get((expression).toParsedText()).toString() : expression.toParsedText().toString(); }
Object inValues = kunderaQuery.getParametersMap().get(inClauseValues.toParsedText()); log.debug(inClauseValues.toParsedText() + "named parameter found in query, Replacing parameter with " + inValues); : (Collection) kunderaQuery.getParametersMap().get(inClauseValues.toParsedText());
/** * Populate like query. * * @param likeExpression * the like expression * @param metadata * the metadata * @return the filter builder */ private QueryBuilder populateLikeQuery(LikeExpression likeExpression, EntityMetadata metadata) { Expression patternValue = likeExpression.getPatternValue(); String field = likeExpression.getStringExpression().toString(); String likePattern = (patternValue instanceof InputParameter) ? kunderaQuery.getParametersMap() .get((patternValue).toParsedText()).toString() : patternValue.toParsedText().toString(); String jpaField = getField(field); log.debug("Pattern value for field " + field + " is: " + patternValue); QueryBuilder filterBuilder = getQueryBuilder(kunderaQuery.new FilterClause(jpaField, Expression.LIKE, likePattern, field), metadata); return filterBuilder; }
|| boundExpression instanceof InputParameter) Object value = (boundExpression instanceof InputParameter) ? kunderaQuery.getParametersMap().get( (boundExpression).toParsedText()) : boundExpression.toParsedText(); return value.toString();
/** * Populate filter clause. * * @param conditionalExpression * the conditional expression * @return the filter clause */ private FilterClause populateFilterClause(ComparisonExpression conditionalExpression) { String property = ((StateFieldPathExpression) conditionalExpression.getLeftExpression()).getPath(1); String condition = conditionalExpression.getComparisonOperator(); Expression rightExpression = conditionalExpression.getRightExpression(); Object value = (rightExpression instanceof InputParameter) ? kunderaQuery.getParametersMap().get( (rightExpression).toParsedText()) : rightExpression.toParsedText(); return (condition != null && property != null) ? kunderaQuery.new FilterClause(property, condition, value, property) : null; }