public static String getText(final NodeInfo nodeInfo) {
        try {
            final String path = "//text()";
            final XPathEvaluator xPathEvaluator = new XPathEvaluator(nodeInfo.getConfiguration());

            final XPathExpression xPathExpression = xPathEvaluator.compile(path);
            return (String) xPathExpression.evaluate(nodeInfo, XPathConstants.STRING);

        } catch (final XPathExpressionException | RuntimeException e) {
            throw ProcessException.create(e.getMessage());
        }
    }
Creates an text string from the content events in the event stack
captured for the matched record.
stroom-pipeline/src/main/java/stroom/pipeline/xml/event/EventListUtils.java