@Test public void testGetBindVariableMap() { StatementBuilder statementBuilder = new StatementBuilder() .where("number = :number and bool = :bool") .withBindVariableValue("number", 1) .withBindVariableValue("bool", false); Map<String, Value> map = statementBuilder.getBindVariableMap(); assertEquals(2, map.size()); assertEquals(NumberValue.class, map.get("number").getClass()); assertEquals(BooleanValue.class, map.get("bool").getClass()); assertEquals("1", ((NumberValue) map.get("number")).getValue()); assertEquals(false, ((BooleanValue) map.get("bool")).getValue()); }
public Map<String, Value> getBindVariableMap() { return queryBuilder.getBindVariableMap(); }
StatementBuilder { public Map<String, Value> getBindVariableMap() { return queryBuilder.getBindVariableMap(); } }
StatementBuilder { public Map<String, Value> getBindVariableMap() { return queryBuilder.getBindVariableMap(); } StatementBuilder(); @VisibleForTesting  StatementBuilder(QueryBuilderInterface<Value> queryBuilder); }
StatementBuilder { public Map<String, Value> getBindVariableMap() { return queryBuilder.getBindVariableMap(); } StatementBuilder(); @VisibleForTesting  StatementBuilder(QueryBuilderInterface<Value> queryBuilder); StatementBuilder withBindVariableValue(String key, Object value); StatementBuilder withBindVariableValue(String key, Value value); Statement toStatement(); StatementBuilder select(String columns); StatementBuilder from(String table); StatementBuilder where(String conditions); StatementBuilder limit(Integer count); StatementBuilder offset(Integer count); StatementBuilder increaseOffsetBy(Integer amount); Integer getOffset(); StatementBuilder removeLimitAndOffset(); StatementBuilder orderBy(String orderBy); Map<String, Value> getBindVariableMap(); String buildQuery(); }
StatementBuilder { public Map<String, Value> getBindVariableMap() { return queryBuilder.getBindVariableMap(); } StatementBuilder(); @VisibleForTesting  StatementBuilder(QueryBuilderInterface<Value> queryBuilder); StatementBuilder withBindVariableValue(String key, Object value); StatementBuilder withBindVariableValue(String key, Value value); Statement toStatement(); StatementBuilder select(String columns); StatementBuilder from(String table); StatementBuilder where(String conditions); StatementBuilder limit(Integer count); StatementBuilder offset(Integer count); StatementBuilder increaseOffsetBy(Integer amount); Integer getOffset(); StatementBuilder removeLimitAndOffset(); StatementBuilder orderBy(String orderBy); Map<String, Value> getBindVariableMap(); String buildQuery(); static final int SUGGESTED_PAGE_LIMIT; }