@Test void testGetQueryFieldName() { String fieldName = "MyFieldId"; Attribute attribute = mock(Attribute.class); when(documentIdGenerator.generateId(attribute)).thenReturn(fieldName); assertEquals(fieldName, queryGenerator.getQueryFieldName(attribute)); }
String getQueryFieldName(List<Attribute> attributePath) { return attributePath.stream() .map(this::getQueryFieldName) .collect(joining(ATTRIBUTE_SEPARATOR)); }
BaseQueryClauseGenerator implements QueryClauseGenerator { String getQueryFieldName(List<Attribute> attributePath) { return attributePath.stream() .map(this::getQueryFieldName) .collect(joining(ATTRIBUTE_SEPARATOR)); } }
BaseQueryClauseGenerator implements QueryClauseGenerator { String getQueryFieldName(List<Attribute> attributePath) { return attributePath.stream() .map(this::getQueryFieldName) .collect(joining(ATTRIBUTE_SEPARATOR)); } BaseQueryClauseGenerator(DocumentIdGenerator documentIdGenerator, Operator operator); }
BaseQueryClauseGenerator implements QueryClauseGenerator { String getQueryFieldName(List<Attribute> attributePath) { return attributePath.stream() .map(this::getQueryFieldName) .collect(joining(ATTRIBUTE_SEPARATOR)); } BaseQueryClauseGenerator(DocumentIdGenerator documentIdGenerator, Operator operator); @Override Operator getOperator(); @Override QueryBuilder createQueryClause(QueryRule queryRule, EntityType entityType); }
BaseQueryClauseGenerator implements QueryClauseGenerator { String getQueryFieldName(List<Attribute> attributePath) { return attributePath.stream() .map(this::getQueryFieldName) .collect(joining(ATTRIBUTE_SEPARATOR)); } BaseQueryClauseGenerator(DocumentIdGenerator documentIdGenerator, Operator operator); @Override Operator getOperator(); @Override QueryBuilder createQueryClause(QueryRule queryRule, EntityType entityType);  }