static Optional<String> getQuotedPart(final String key, final String href, final String quotes) {
        final String match = key + "=" + quotes;
        int start = href.indexOf(match);
        if (start != -1) {
            start = start + match.length();
            int end = href.indexOf(quotes + ",", start);
            if (end == -1) {
                end = href.indexOf(quotes + " ", start);
                if (end == -1) {
                    if (quotes.length() > 0) {
                        end = href.indexOf(quotes, start);
                    }
                    if (end == -1) {
                        end = href.length();
                    }
                }
            }
            return Optional.of(href.substring(start, end));
        }
        return Optional.empty();
    }
Called by the processor when it encounters an xsl:include, xsl:import, or
document() function.

@param href An href attribute, which may be relative or absolute.
@param base The base URI against which the first argument will be made
            absolute if the absolute URI is required.
@return A Source object, or null if the href cannot be resolved, and the
processor should try to resolve the URI itself.
@throws TransformerException Thrown if the referenced resource cannot be found.
stroom-pipeline/src/main/java/stroom/pipeline/xslt/CustomURIResolver.java