It makes sense to combine the advantages of XQuery and Java packages by providing : * Instead of directly calling Java code, a wrapper module can be provided. This module contains functions for that invoke the Java classfunctions. XQuery * These functions can be properly typed; this reduces the danger of erroneous or unexpected conversions between XQuery and Java code.