Xalan-Java: Interface ExtensionFunctionHandler.ExtensionLiaison

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.xalan.xpath
Interface ExtensionFunctionHandler.ExtensionLiaison

All Known Implementing Classes:
  XSLTJavaClassEngine

public static interface ExtensionFunctionHandler.ExtensionLiaison

**For internal use only** Interface for connecting extension functions to xalan. Based on ExtensionFunctionHandler

Method Summary
`java.lang.Object` | `callFunction(java.lang.String funcName, java.util.Vector args, java.lang.Object methodKey, java.lang.Class javaClass)` Process a call to a function.
`java.lang.Object` | `callJava(java.lang.Object object, java.lang.String method, java.lang.Object[] args, java.lang.Object methodKey)` call the named method on the object that was loaded by eval.
`void` | `checkInit()` Make sure the component is initialized
`void` | `setScript(java.lang.String lang, java.lang.String srcURL, java.lang.String scriptSrc)` Set the script data for this extension NS.
`void` | `startupComponent(java.lang.Class classObj)` Start the component up by executing any script that needs to run at startup time.

Method Detail

### checkInit

    public void checkInit()
                   throws XPathProcessorException

  Make sure the component is initialized

### startupComponent

    public void startupComponent(java.lang.Class classObj)
                          throws XPathProcessorException

  Start the component up by executing any script that needs to run at startup time. This needs to happen before any functions can be called on the component.
  Throws:
    XPathProcessorException - if something bad happens.

### callFunction

    public java.lang.Object callFunction(java.lang.String funcName,
                                         java.util.Vector args,
                                         java.lang.Object methodKey,
                                         java.lang.Class javaClass)
                                  throws XPathException

  Process a call to a function.
  Parameters:
    `funcName` - Function name.
    `args` - The arguments of the function call.
  Returns:
    the return value of the function evaluation.
  Throws:
    XSLProcessorException - thrown if something goes wrong while running the extension handler.
    java.net.MalformedURLException - if loading trouble
    java.io.FileNotFoundException - if loading trouble
    java.io.IOException - if loading trouble
    org.xml.sax.SAXException - if parsing trouble

### callJava

    public java.lang.Object callJava(java.lang.Object object,
                                     java.lang.String method,
                                     java.lang.Object[] args,
                                     java.lang.Object methodKey)
                              throws XPathException

  call the named method on the object that was loaded by eval. The method selection stuff is very XSLT-specific, hence the custom engine.
  Parameters:
    `object` - ignored - should always be null

### setScript

    public void setScript(java.lang.String lang,
                          java.lang.String srcURL,
                          java.lang.String scriptSrc)

  Set the script data for this extension NS. If srcURL is !null then the script body is read from that URL. If not the scriptSrc is used as the src. This method does not actually execute anything - that's done when the component is first hit by the user by an element or a function call.
  Parameters:
    `lang` - language of the script.
    `srcURL` - value of src attribute (if any) - treated as a URL or a classname depending on the value of lang. If srcURL is not null, then scriptSrc is ignored.
    `scriptSrc` - the actual script code (if any)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000 Apache XML Project. All Rights Reserved.