private Condition eq(final ExpressionTerm term) {
        final List<T> list = getValues(term.getValue());
        if (NullSafe.isEmptyCollection(list)) {
            return field.isNull();
        } else if (list.size() > 1) {
            return field.in(list);
        } else {
            final T t = list.getFirst();
            if (t instanceof final String string) {
                if (string.contains(ASTERISK)) {
                    final String like = ASTERISK_PATTERN.matcher(string).replaceAll(PERCENT);
                    return field.like(like);
                }
            }
            return field.equal(t);
        }
    }
Get an identifier for the passed docRef. term is only used for logging.
docRef may be the same as term.getDocRef() or a descendant of it, as in 'in folder'.

@return The name of the doc or its uuid depending on how the {@link TermHandler} is
configured.
stroom-db-util/src/main/java/stroom/db/util/TermHandler.java