|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.sf.saxon.instruct.Instruction
Abstract superclass for all instructions in the compiled stylesheet.
This represents a compiled instruction, and as such, the minimum information is
retained from the original stylesheet.
Note: this class implements SourceLocator.
Field Summary | |
protected Instr[] |
children
|
Constructor Summary | |
Instruction()
Constructor |
Method Summary | |
protected static ParameterSet |
assembleParams(XPathContext context,
WithParam[] actualParams)
Assemble a ParameterSet. |
protected static ParameterSet |
assembleTunnelParams(XPathContext context,
WithParam[] actualParams)
Assemble a ParameterSet. |
static void |
displayChildren(Instr[] children,
int level,
NamePool pool)
Display the children of an intstruction for diagostics |
protected static javax.xml.transform.TransformerException |
dynamicError(Instr instr,
javax.xml.transform.TransformerException error,
Controller controller)
Construct an exception with diagnostic information. |
protected javax.xml.transform.TransformerException |
dynamicError(java.lang.String message,
Controller controller)
Raise a dynamic error |
int |
getCardinality()
Get the cardinality of the sequence returned by evaluating this instruction |
Instr[] |
getChildren()
Get the children of this instruction |
int |
getColumnNumber()
|
Executable |
getExecutable()
|
abstract java.lang.String |
getInstructionName()
Get the name of the instruction for use in diagnostics |
java.lang.String |
getInstructionNamespace()
Get the namespace of the instruction name. |
ItemType |
getItemType()
Get the item type of the items returned by evaluating this instruction |
int |
getLineNumber()
Get the line number of the source stylesheet instruction within its module. |
java.lang.String |
getPublicId()
|
javax.xml.transform.SourceLocator |
getSourceLocator()
Get a SourceLocator identifying the location of this instruction |
java.lang.String |
getSystemId()
|
void |
process(XPathContext context)
Process the instruction, without returning any tail calls |
protected void |
processChildren(XPathContext context)
Process the children of this instruction, including any tail calls |
protected TailCall |
processChildrenLeavingTail(XPathContext context)
Process the children of this instruction, returning any tail call made by the last child instruction |
abstract TailCall |
processLeavingTail(XPathContext context)
ProcessLeavingTail: called to do the real work of this instruction. |
protected static void |
recoverableError(Instr instr,
java.lang.String message,
Controller controller)
Signal a recoverable error. |
void |
setChildren(Instr[] children)
Set the children of this instruction |
void |
setExecutable(Executable exec)
Set the containing executable |
void |
setSourceLocation(int module,
int lineNumber)
Set the system ID and the line number of this instruction. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected Instr[] children
Constructor Detail |
public Instruction()
Method Detail |
public void setExecutable(Executable exec)
public Executable getExecutable()
public void setChildren(Instr[] children)
children
- The instructions that are children of this instructionpublic Instr[] getChildren()
public void setSourceLocation(int module, int lineNumber)
module
- integer identifying the module in which this instruction occurs,
This is an index into the module array owned by the Executable objectlineNumber
- the line number of this instruction within its modulepublic java.lang.String getSystemId()
getSystemId
in interface javax.xml.transform.SourceLocator
public java.lang.String getPublicId()
getPublicId
in interface javax.xml.transform.SourceLocator
public int getColumnNumber()
getColumnNumber
in interface javax.xml.transform.SourceLocator
public int getLineNumber()
getLineNumber
in interface javax.xml.transform.SourceLocator
public abstract java.lang.String getInstructionName()
public java.lang.String getInstructionNamespace()
public ItemType getItemType()
public int getCardinality()
public abstract TailCall processLeavingTail(XPathContext context) throws javax.xml.transform.TransformerException
processLeavingTail
in interface Instr
context
- The dynamic context of the transformation, giving access to the current node,
the current variables, etc.
javax.xml.transform.TransformerException
public void process(XPathContext context) throws javax.xml.transform.TransformerException
process
in interface Instr
context
- The dynamic context, giving access to the current node,
the current variables, etc.
javax.xml.transform.TransformerException
protected void processChildren(XPathContext context) throws javax.xml.transform.TransformerException
context
- The dynamic context for the transformation
javax.xml.transform.TransformerException
- if a dynamic error occursprotected TailCall processChildrenLeavingTail(XPathContext context) throws javax.xml.transform.TransformerException
context
- The dynamic context of the transformation, giving access to the current node,
the current variables, etc.
javax.xml.transform.TransformerException
public javax.xml.transform.SourceLocator getSourceLocator()
getSourceLocator
in interface Locatable
protected static javax.xml.transform.TransformerException dynamicError(Instr instr, javax.xml.transform.TransformerException error, Controller controller)
error
- The exception containing information about the errorcontroller
- The controller of the transformation
protected javax.xml.transform.TransformerException dynamicError(java.lang.String message, Controller controller)
message
- An English text error messagecontroller
- The controller of the transformation
protected static void recoverableError(Instr instr, java.lang.String message, Controller controller) throws javax.xml.transform.TransformerException
message
- an English-language error messagecontroller
- the controller for the transformation
javax.xml.transform.TransformerException
- - the method throws an exception if the selected
policy is not to recover from recoverable errorspublic static void displayChildren(Instr[] children, int level, NamePool pool)
protected static ParameterSet assembleParams(XPathContext context, WithParam[] actualParams) throws javax.xml.transform.TransformerException
javax.xml.transform.TransformerException
protected static ParameterSet assembleTunnelParams(XPathContext context, WithParam[] actualParams) throws javax.xml.transform.TransformerException
javax.xml.transform.TransformerException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |