com.novell.nds.dirxml.driver
Class XdsCommandProcessor

java.lang.Object
  extended by com.novell.nds.dirxml.driver.XdsCommandProcessor

public class XdsCommandProcessor
extends Object

A command processor designed primarily for use within XSLT stylesheets used as rules, or by functions called from an XSLT stylesheet used as a rule.

The DirXML engine passed two stylesheet parameters to an XSLT stylesheet rule. Both parameters are of type XdsCommandProcessor. One is named srcCommandProcessor and will execute the command using source of the current transaction (NDS for subscriber-channel transactions and the app shim for publisher-channel transactions) and the other is named destQueryProcessor and will execute the command using the destination of the current transaction (the app shim for subscriber-channel transactions and NDS for publisher channel transactions).


Constructor Summary
XdsCommandProcessor(com.novell.nds.dirxml.engine.XdsCommandProcessor processor, com.novell.nds.dirxml.engine.VRDExceptionListener listener)
          Create an XdsCommandProcessor.
 
Method Summary
 Document execute(Document executeDoc)
          Execute an XDS command contained in the passed document.
 Document execute(ExpressionValue executeValue)
          Perform an XDS query contained in the passed ExpressionValue.
 Document execute(NodeSet executeSet)
          Execute an XDS command contained in the passed XPath nodeset.
 Document execute(ResultTreeFragment executeFragment)
          Execute an XDS command contained in the passed XSLT result tree fragment.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XdsCommandProcessor

public XdsCommandProcessor(com.novell.nds.dirxml.engine.XdsCommandProcessor processor,
                           com.novell.nds.dirxml.engine.VRDExceptionListener listener)
Create an XdsCommandProcessor. Since the engine version of XdsCommandProcessor can only be created by the engine, this effectively limits instance creation of the command processor to the engine.

Parameters:
processor - The engine query processor that will actually perform the query
listener - The object to notify in case of an exception
Method Detail

execute

public Document execute(Document executeDoc)
                 throws com.novell.nds.dirxml.engine.VRDException
Execute an XDS command contained in the passed document.

Parameters:
executeDoc - The XDS document containing the command to execute.
Returns:
An XDS document with the command results. Note that when command is sent to the driver shim from the Publisher channel that the is queued for execution on the Subscriber channel and success reflects that the command successfully queued and not that it was successfully executed
Throws:
com.novell.nds.dirxml.engine.VRDException

execute

public Document execute(ResultTreeFragment executeFragment)
                 throws com.novell.nds.dirxml.engine.VRDException
Execute an XDS command contained in the passed XSLT result tree fragment.

Parameters:
executeFragment - The XSLT result tree fragment containing the command to execute. This must be a well-formed XDS document from the fragment root down.
Returns:
An XDS document with the command results. Note that when command is sent to the driver shim from the Publisher channel that the is queued for execution on the Subscriber channel and success reflects that the command successfully queued and not that it was successfully executed
Throws:
com.novell.nds.dirxml.engine.VRDException

execute

public Document execute(NodeSet executeSet)
                 throws com.novell.nds.dirxml.engine.VRDException
Execute an XDS command contained in the passed XPath nodeset.

Parameters:
executeSet - The XPath nodeset containing the command to execute. This must be a well-formed XDS document from the fragment root down.
Returns:
An XDS document with the command results. Note that when command is sent to the driver shim from the Publisher channel that the is queued for execution on the Subscriber channel and success reflects that the command successfully queued and not that it was successfully executed
Throws:
com.novell.nds.dirxml.engine.VRDException

execute

public Document execute(ExpressionValue executeValue)
                 throws com.novell.nds.dirxml.engine.VRDException,
                        XPathConversionException
Perform an XDS query contained in the passed ExpressionValue.

Parameters:
executeValue - The NodeSet or ResultTree fragment containing XdsQuery
Returns:
An XDS document with the query results.
Throws:
com.novell.nds.dirxml.engine.VRDException
XPathConversionException