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

## net.sf.saxon.event
Class TransformerReceiver

    java.lang.Object
      net.sf.saxon.event.ProxyReceiver
          net.sf.saxon.event.TransformerReceiver

All Implemented Interfaces:
  Receiver, javax.xml.transform.Result

public class TransformerReceiver
extends ProxyReceiver

TransformerReceiver is similar in concept to the JAXP TransformerHandler, except that it implements Saxon's Receiver interface rather than the standard SAX2 interface. This means that it allows nodes with type annotations to be passed down a pipeline from one transformation to another.

Field Summary

Fields inherited from class net.sf.saxon.event.ProxyReceiver
`baseReceiver, pipelineConfig`

Fields inherited from interface javax.xml.transform.Result
`PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING`

Constructor Summary
`TransformerReceiver(Controller controller)` Create a TransformerHandlerImpl and initialise variables.

Method Summary
`void` | `close()` Override the behaviour of endDocument() in ReceivingContentHandler, so that it fires off the transformation of the constructed document
`javax.xml.transform.Result` | `getResult()` Get the output destination of the transformation
`java.lang.String` | `getSystemId()` Get the systemId of the document
`javax.xml.transform.Transformer` | `getTransformer()` Get the Transformer used for this transformation
`void` | `open()` Start of event stream
`void` | `setResult(javax.xml.transform.Result result)` Set the output destination of the transformation
`void` | `setSystemId(java.lang.String url)` Set the SystemId of the document
`void` | `startElement(int nameCode, int typeCode, int locationId, int properties)` Notify the start of an element

Methods inherited from class net.sf.saxon.event.ProxyReceiver
`attribute, characters, comment, endDocument, endElement, getConfiguration, getDocumentLocator, getNamePool, getPipelineConfiguration, getUnderlyingReceiver, namespace, processingInstruction, setPipelineConfiguration, setUnderlyingReceiver, setUnparsedEntity, startContent, startDocument`

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

Constructor Detail

### TransformerReceiver

    public TransformerReceiver(Controller controller)

  Create a TransformerHandlerImpl and initialise variables.

Method Detail

### open

    public void open()
              throws XPathException

  Start of event stream

  Specified by:
    `open` in interface `Receiver`
  Overrides:
    `open` in class `ProxyReceiver`
  Throws:
    `XPathException`

### getTransformer

    public javax.xml.transform.Transformer getTransformer()

  Get the Transformer used for this transformation

### setSystemId

    public void setSystemId(java.lang.String url)

  Set the SystemId of the document

  Specified by:
    `setSystemId` in interface `Receiver`
  Overrides:
    `setSystemId` in class `ProxyReceiver`

### getSystemId

    public java.lang.String getSystemId()

  Get the systemId of the document

  Specified by:
    `getSystemId` in interface `javax.xml.transform.Result`
  Overrides:
    `getSystemId` in class `ProxyReceiver`

### startElement

    public void startElement(int nameCode,
                             int typeCode,
                             int locationId,
                             int properties)
                      throws XPathException

  Notify the start of an element

  Specified by:
    `startElement` in interface `Receiver`
  Overrides:
    `startElement` in class `ProxyReceiver`
  Parameters:
    `nameCode` - integer code identifying the name of the element within the name pool.
    `typeCode` - integer code identifying the element's type within the name pool.
    `properties` - bit-significant properties of the element node.
  Throws:
    `XPathException`

### setResult

    public void setResult(javax.xml.transform.Result result)

  Set the output destination of the transformation

### getResult

    public javax.xml.transform.Result getResult()

  Get the output destination of the transformation

### close

    public void close()
               throws XPathException

  Override the behaviour of endDocument() in ReceivingContentHandler, so that it fires off the transformation of the constructed document

  Specified by:
    `close` in interface `Receiver`
  Overrides:
    `close` in class `ProxyReceiver`
  Throws:
    `XPathException`

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