Cannot find extension function using 10.x

Martynas Jusevičius <martynas-tyFqBaoSXPC1Z/[email protected]>
Newsgroups gmane.text.xml.saxon.help
Message-ID <CAE35Vmy05NcmVam_eg+kUokwAq9CJ1=KcHxgVA77Q1P0t=XEJA@mail.gmail.com>
Hi,

I've been trying to upgrade to Saxon 10.x and had to implement a few
(simple) extension functions in the process. I've been following this
guide:
https://www.saxonica.com/html/documentation/extensibility/integratedfunctions/ext-simple-J.html

However I get this error message when attempting to use one of them:

Error near {...c:forClass, $ldt:base)/rdf:...} at char 0 in
xsl:apply-templates/@select on line 650 column 135 of layout.xsl:
  XPST0017: Cannot find a 3-argument function named
  Q{https://w3id.org/atomgraph/client#}construct-doc()

I've double-checked the namespaces.

The function is registered on the Processor:

        processor.registerExtensionFunction(new ConstructDocument(processor));

The function itself looks like this:

public class ConstructDocument implements ExtensionFunction
{

    private final Processor processor;

    public ConstructDocument(Processor processor)
    {
        this.processor = processor;
    }

    @Override
    public QName getName()
    {
        return new QName("https://w3id.org/atomgraph/client#", "construct-doc");
   }

    @Override
    public SequenceType getResultType()
    {
        return SequenceType.makeSequenceType(ItemType.DOCUMENT_NODE,
OccurrenceIndicator.ZERO_OR_MORE);
    }

    @Override
    public SequenceType[] getArgumentTypes()
    {
        return new SequenceType[]
        {
            SequenceType.makeSequenceType(ItemType.ANY_URI,
OccurrenceIndicator.ONE),
            SequenceType.makeSequenceType(ItemType.ANY_URI,
OccurrenceIndicator.ZERO_OR_MORE),
            SequenceType.makeSequenceType(ItemType.ANY_URI,
OccurrenceIndicator.ONE),
        };
    }

    @Override
    public XdmValue call(XdmValue[] arguments) throws SaxonApiException
    {
        ...
    }

    public Processor getProcessor()
    {
        return processor;
    }

}

What am I missing here? Thanks.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.