Interface CollectionFinder

  • All Known Implementing Classes:
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    public interface CollectionFinder
    An instance of CollectionFinder can be registered with the Saxon configuration; it is called in response to calls on the fn:collection() and fn:uri-collection() functions. When these functions are called, the findCollection(XPathContext, String) method is called to get a ResourceCollection object representing the collection of resources identified by the supplied collection URI.
    9.7: Supersedes CollectionURIResolver. The interface was changed to return Resource objects, to allow streamed processing of the documents in a collection; and to pass a properties object that can be used to indicate whether the collection is stable (that is, repeated requests return the same result)
    • Method Detail

      • findCollection

        ResourceCollection findCollection​(XPathContext context,
                                          java.lang.String collectionURI)
                                   throws XPathException
        Locate the collection of resources corresponding to a collection URI.
        context - The XPath dynamic evaluation context
        collectionURI - The collection URI: an absolute URI, formed by resolving the argument supplied to the fn:collection or fn:uri-collection against the static base URI
        a ResourceCollection object representing the resources in the collection identified by this collection URI. Result should not be null.
        XPathException - if the collection was not found