com.xml_project.morganaxproc
Class XProcPipeline

java.lang.Object
  extended by com.xml_project.morganaxproc.XProcPipeline

public class XProcPipeline
extends java.lang.Object

This class represents the compiled, i.e. runnable form of an XProc pipeline. To compile an XProc pipeline call compile() from an XProcCompiler.

Objects of this class can be used to run the same (compiled) pipeline multiple times possibly with different port bindings and/or options.


Nested Class Summary
 class XProcPipeline.PipelineInfo
           
 
Method Summary
 XProcConfiguration getConfiguration()
           Return the XProcConfiguration used to run this XProcLibrary/XProcPipeline.
 XProcEngine getEngine()
           Returns the XProcEngine used to generate this XProcLibrary/XProcPipeline.
 XProcPipeline.PipelineInfo getInfo()
           
 java.net.URI getPipelineURI()
           
 XProcOutput run()
          Runs the pipeline without any input.
 XProcOutput run(XProcInput inputs)
          Runs the pipeline with the given input.
 void setConfiguration(XProcConfiguration config)
           Sets the XProcConfiguration to use when running this XProcLibrary/XProcPipeline.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getPipelineURI

public java.net.URI getPipelineURI()

getInfo

public XProcPipeline.PipelineInfo getInfo()

run

public XProcOutput run()

Runs the pipeline without any input. Produces an XProcOutput object anyway, even if an error occurs.

Returns:
an XProcOutput holding the result of the execution.

run

public XProcOutput run(XProcInput inputs)

Runs the pipeline with the given input. Produces an XProcOutput object anyway, even if an error occurs.

Parameters:
inputs - the inputs (port bindings and option settings) for the execution of the pipeline.
Returns:
an XProcOutput holding the result of the execution.

getEngine

public XProcEngine getEngine()

Returns the XProcEngine used to generate this XProcLibrary/XProcPipeline.

Please mind that the XProcConfiguration object hold by XProcEngine might have changed since generation of the pipeline/library.

Returns:
the XProcEngine used to generate this XProcPipeline.

getConfiguration

public XProcConfiguration getConfiguration()

Return the XProcConfiguration used to run this XProcLibrary/XProcPipeline.

Returns:
the configuration currently used.

setConfiguration

public void setConfiguration(XProcConfiguration config)
                      throws XProcInterfaceException

Sets the XProcConfiguration to use when running this XProcLibrary/XProcPipeline.

Parameters:
config - the configuration to use.
Throws:
XProcInterfaceException - if config is null.