com.saxonica.stream.feed
Class ComplexNodeEventFeed

java.lang.Object
  extended by com.saxonica.stream.feed.EventFeed
      extended by com.saxonica.stream.feed.ComplexNodeEventFeed
All Implemented Interfaces:
Feed

public class ComplexNodeEventFeed
extends EventFeed

This event feed supports instructions that create a document or element node. The events representing the start and end of the element or document are written to the destination receiver during the open() and close() calls. Between these two calls, the child instruction representing the content of the document or element pushes its output to the same destination receiver.

The instruction-dependent code is contained in the processLeft() and processRight() methods of the expression object, which must be a DivisibleInstruction


Constructor Summary
ComplexNodeEventFeed(Expression exp, Feed parentExpressionFeed, Stack<XPathContext> contextStack)
           
 
Method Summary
 void close()
          Finish evaluating the expression.
 void open()
          Start evaluating the expression.
 
Methods inherited from class com.saxonica.stream.feed.EventFeed
append, getContext, getContextStack, getExpression, getPipelineConfiguration, getResult, setPipelineConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ComplexNodeEventFeed

public ComplexNodeEventFeed(Expression exp,
                            Feed parentExpressionFeed,
                            Stack<XPathContext> contextStack)
Method Detail

open

public void open()
          throws XPathException
Description copied from class: EventFeed
Start evaluating the expression. This must call open() on the parent expression feed before it does anything else. For the default implementation, this is all that it does. Note that it does not open the destination receiver.

Specified by:
open in interface Feed
Overrides:
open in class EventFeed
Throws:
XPathException - to report any failure

close

public void close()
           throws XPathException
Description copied from class: EventFeed
Finish evaluating the expression. This must call close() on the parent expression feed as the last thing it does. For the default implementation, this is all that it does. Note that it does not close the destination receiver.

Specified by:
close in interface Feed
Overrides:
close in class EventFeed
Throws:
XPathException - to report any failure


Copyright (c) 2004-2011 Saxonica Limited. All rights reserved.