I wrote a custom URIResolver and I'm attaching it to th configuration
and the dynamic as follows
        Configuration config = new Configuration();
        config.setURIResolver(new MyURIResolver());
        final StaticQueryContext sqc = new StaticQueryContext(config);
        final DynamicQueryContext dynamicContext = new
        dynamicContext.setURIResolver(new MyURIResolver());

When saxon tries to resolve a uri given to the doc function, my custom
URI is being activated currectly. However, it is never activated for
resolving the module URI
Any ideas ?

Second question: What do I need to do if I want the resolver to be
called for protocols other than http://, https:// or file:// ?