public <T extends PropertyContainer>List<SearchMatch<T>> search(String query,Class<T> clazz){
  SearchResult result=doQuery(query,clazz);
  List<SearchMatch<T>> matches=buildSearchMatches(result);
  @SuppressWarnings("unchecked") Function<SearchMatch,T> resolver=(Function<SearchMatch,T>)(clazz.equals(Node.class) ? getNodeResolver() : getRelationshipResolver());
  return resolveMatchItems(matches,resolver);
}

public < T extends PropertyContainer > List < SearchMatch < T > > search ( String query , Class < T > clazz ) { SearchResult result = doQuery ( query , clazz ) ; List < SearchMatch < T > > matches = buildSearchMatches ( result ) ; @ SuppressWarnings ( "unchecked" ) Function < SearchMatch , T > resolver = ( Function < SearchMatch , T > ) ( clazz . equals ( Node . class ) ? getNodeResolver ( ) : getRelationshipResolver ( ) ) ; return resolveMatchItems ( matches , resolver ) ; }
search for nodes or relationships
