code: protected String createQueryFragmentForCriteria(Criteria part, @Nullable Class<?> domainType) {
  
  		Criteria criteria = part;
  		StringBuilder queryFragment = new StringBuilder();
  		boolean singeEntryCriteria = (criteria.getPredicates().size() == 1);
  
  		if (criteria instanceof QueryStringHolder) {
  			return ((QueryStringHolder) criteria).getQueryString();
  		}
  
  		String fieldName = getNullsafeFieldName(criteria.getField(), domainType);
  		if (criteria.isNegating()) {
  			fieldName = NOT + fieldName;
  		}
  		if (!StringUtils.isEmpty(fieldName) && !containsFunctionCriteria(criteria.getPredicates())) {
  			queryFragment.append(fieldName);
  			queryFragment.append(DELIMINATOR);
  		}
  
  		// no criteria given is defaulted to not null
  		if (criteria.getPredicates().isEmpty()) {
  			queryFragment.append("[* TO *]");
  			return queryFragment.toString();
  		}
  
  		if (!singeEntryCriteria) {
  			queryFragment.append("(");
  		}
  
  		CriteriaQueryStringValueProvider valueProvider = new CriteriaQueryStringValueProvider(criteria, domainType);
  		while (valueProvider.hasNext()) {
  			queryFragment.append(valueProvider.next());
  			if (valueProvider.hasNext()) {
  				queryFragment.append(CRITERIA_VALUE_SEPERATOR);
  			}
  		}
  
  		if (!singeEntryCriteria) {
  			queryFragment.append(")");
  		}
  		if (!Float.isNaN(criteria.getBoost())) {
  			queryFragment.append(BOOST).append(criteria.getBoost());
  		}
  
  		return queryFragment.toString();
  	}
docs: Creates query string representation of a single critiera.
  
  @param part
  @param domainType
  @return