### Question:
StructuredQuery extends Query { @Override public QueryType queryType() { return QueryType.STRUCTURED; }  @Override QueryType queryType();  }### Answer:
@Test public void shouldBeStructuredQuery() { final RangeQuery range = new RangeQuery(Randoms.randomString(), Randoms.randomDateTime(), Randoms.randomDateTime(), Randoms.randomBoolean(), Randoms.randomBoolean()); assertEquals(QueryType.STRUCTURED, range.queryType()); final TermQuery term = new TermQuery(Randoms.randomString(), Randoms.randomString()); assertEquals(QueryType.STRUCTURED, term.queryType()); final Collection<StructuredQuery> queries = new HashSet<StructuredQuery>(); queries.add(range); queries.add(term); assertEquals(QueryType.STRUCTURED, new AndQuery(queries).queryType()); assertEquals(QueryType.STRUCTURED, new OrQuery(queries).queryType()); }