## net.sf.saxon.functions
Class ExtensionFunctionFactory

    java.lang.Object
      net.sf.saxon.functions.ExtensionFunctionFactory

All Implemented Interfaces:
  java.io.Serializable

public class ExtensionFunctionFactory
extends java.lang.Object
implements java.io.Serializable

This class acts as a factory for creating expressions that call extension functions. A different factory may be registered with the Configuration in order to customize the behaviour. Alternatively, this factory class can be customized by calling setExtensionFunctionClass to nominate a subclass of ExtensionFunctionCall to be used to implement calls on extension functions.

See Also:
  Serialized Form

Constructor Summary
`ExtensionFunctionFactory()`

Method Summary
`Expression` `makeExtensionFunctionCall(int nameCode, java.lang.Class theClass, java.lang.reflect.AccessibleObject method, Expression[] arguments)` Factory method to create an expression that calls a Java extension function.
`void` `setExtensionFunctionClass(java.lang.Class subclass)` Set the class to be used to represent extension function calls.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ExtensionFunctionFactory

    public ExtensionFunctionFactory()

Method Detail

### setExtensionFunctionClass

    public void setExtensionFunctionClass(java.lang.Class subclass)

  Set the class to be used to represent extension function calls. This must be a subclass of `ExtensionFunctionCall`

  Parameters:
    `subclass` - the subclass of ExtensionFunctionCall to be used

### makeExtensionFunctionCall

    public Expression makeExtensionFunctionCall(int nameCode,
                                                java.lang.Class theClass,
                                                java.lang.reflect.AccessibleObject method,
                                                Expression[] arguments)

  Factory method to create an expression that calls a Java extension function. This is always called at XPath compile time.

  Parameters:
    `nameCode` - the name of the function name, as represented in the name pool
    `theClass` - the Java class containing the extension function
    `method` - The "accessibleObject" representing a constructor, method, or field corresponding to the extension function
    `arguments` - Array containing the expressions supplied as arguments to the function call.
  Returns:
    the constructed ExtensionFunctionCall object (a subclass might return any expression representing the extension function call).