net.sf.saxon.instruct
Class Block

java.lang.Object
  extended bynet.sf.saxon.instruct.Instruction
      extended bynet.sf.saxon.instruct.Block
All Implemented Interfaces:
Serializable, SourceLocator

public class Block
extends Instruction

Implements an imaginary xsl:block instruction which simply evaluates its contents. Used for top-level templates, xsl:otherwise, etc.

See Also:
Serialized Form

Field Summary
static byte BLOCK
          General-purpose block
static byte FALLBACK
          Block representing an xsl:fallback instruction
static byte IF
          Block representing the body of an xsl:if
static byte MATCHING_SUBSTRING
          Block representing an xsl:matching-substring instruction
static byte NON_MATCHING_SUBSTRING
          Block representing an xsl:non-matching-substring instruction
static byte OTHERWISE
          Block representing an xsl:otherwise instruction
static byte WHEN
          Block representing the body of an xsl:when
 
Fields inherited from class net.sf.saxon.instruct.Instruction
children
 
Constructor Summary
Block()
           
 
Method Summary
 TailCall processLeavingTail(XPathContext context)
          ProcessLeavingTail: called to do the real work of this instruction.
 void setInstructionDetails(Controller controller, NamePool namePool, InstructionDetails details)
          Get the name of the instruction for use in diagnostics
 void setInstructionName(byte instructionNameCode)
           
 
Methods inherited from class net.sf.saxon.instruct.Instruction
assembleParams, assembleTunnelParams, getChildren, getColumnNumber, getInstructionDetails, getInstructionName, getLineNumber, getPublicId, getResultType, getSystemId, getSystemId, process, processChildren, processChildrenLeavingTail, recoverableError, setChildren, setSourceLocation, styleError, styleError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BLOCK

public static final byte BLOCK
General-purpose block

See Also:
Constant Field Values

OTHERWISE

public static final byte OTHERWISE
Block representing an xsl:otherwise instruction

See Also:
Constant Field Values

FALLBACK

public static final byte FALLBACK
Block representing an xsl:fallback instruction

See Also:
Constant Field Values

MATCHING_SUBSTRING

public static final byte MATCHING_SUBSTRING
Block representing an xsl:matching-substring instruction

See Also:
Constant Field Values

NON_MATCHING_SUBSTRING

public static final byte NON_MATCHING_SUBSTRING
Block representing an xsl:non-matching-substring instruction

See Also:
Constant Field Values

IF

public static final byte IF
Block representing the body of an xsl:if

See Also:
Constant Field Values

WHEN

public static final byte WHEN
Block representing the body of an xsl:when

See Also:
Constant Field Values
Constructor Detail

Block

public Block()
Method Detail

setInstructionName

public void setInstructionName(byte instructionNameCode)

setInstructionDetails

public void setInstructionDetails(Controller controller,
                                  NamePool namePool,
                                  InstructionDetails details)
Description copied from class: Instruction
Get the name of the instruction for use in diagnostics

Specified by:
setInstructionDetails in class Instruction

processLeavingTail

public TailCall processLeavingTail(XPathContext context)
                            throws TransformerException
Description copied from class: Instruction
ProcessLeavingTail: called to do the real work of this instruction. This method must be implemented in each subclass. The results of the instruction are written to the current Receiver, which can be obtained via the Controller.

Specified by:
processLeavingTail in class Instruction
Parameters:
context - The dynamic context of the transformation, giving access to the current node, the current variables, etc.
Returns:
null if the instruction has completed execution; or a TailCall indicating a function call or template call that is delegated to the caller, to be made after the stack has been unwound so as to save stack space.
Throws:
TransformerException