private static boolean equalsAsBoolean(final Boolean value, final String text) {
        try {
            final Boolean val2 = Boolean.parseBoolean(text);
            return value.equals(val2);
        } catch (NumberFormatException e) {
            // We know the xpath returned a number so if we can't parse the user value to a number
            // it is not a match
            return false;
        }
    }
@return value as a string, trimmed and, if ignoreCase is true, converted to lower case
stroom-pipeline/src/main/java/stroom/pipeline/filter/SAXEventRecorder.java