APIdia Launch Partner
Top Fields Constructors Methods
com.sun.org.apache.xalan.internal.xsltc.compiler

public abstract Class Pattern

extends Expression
Class Inheritance
Known Direct Subclasses
com.sun.org.apache.xalan.internal.xsltc.compiler.AlternativePattern, com.sun.org.apache.xalan.internal.xsltc.compiler.LocationPathPattern
Imports
com.sun.org.apache.xalan.internal.xsltc.compiler.util.ClassGenerator, .MethodGenerator, .Type, .TypeCheckError

Authors
Jacek Ambroziak, Santiago Pericas-Geertsen

Field Summary

Inherited from com.sun.org.apache.xalan.internal.xsltc.compiler.Expression:
_falseList_trueList_type

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public abstract double
getPriority()

Returns the priority of this pattern (section 5.5 in the XSLT spec).

public abstract void
translate(ClassGenerator classGen, MethodGenerator methodGen)

Overrides com.sun.org.apache.xalan.internal.xsltc.compiler.Expression.translate.

Translate this node into JVM bytecodes.

public abstract Type
typeCheck(SymbolTable stable)

Overrides com.sun.org.apache.xalan.internal.xsltc.compiler.Expression.typeCheck.

Returns the type of a pattern, which is always a NodeType.

Inherited from com.sun.org.apache.xalan.internal.xsltc.compiler.Expression:
backPatchFalseListbackPatchTrueListcompiledesynthesizeevaluateAtCompileTimegetFalseListgetTrueListgetTypehasLastCallhasPositionCalllookupPrimopstartIteratorsynthesizetoStringtranslateDesynthesized

Constructor Detail

Patternback to summary
public Pattern()

Method Detail

getPriorityback to summary
public abstract double getPriority()

Returns the priority of this pattern (section 5.5 in the XSLT spec).

translateback to summary
public abstract void translate(ClassGenerator classGen, MethodGenerator methodGen)

Overrides com.sun.org.apache.xalan.internal.xsltc.compiler.Expression.translate.

Translate this node into JVM bytecodes. Patterns are translated as boolean expressions with true/false lists. Before calling translate on a pattern, make sure that the node being matched is on top of the stack. After calling translate, make sure to backpatch both true and false lists. True lists are the default, in the sense that they always "fall through". If this is not the intended semantics (e.g., see com.sun.org.apache.xalan.internal.xsltc.compiler.AlternativePattern#translate) then a GOTO must be appended to the instruction list after calling translate.

typeCheckback to summary
public abstract Type typeCheck(SymbolTable stable) throws TypeCheckError

Overrides com.sun.org.apache.xalan.internal.xsltc.compiler.Expression.typeCheck.

Returns the type of a pattern, which is always a NodeType. A NodeType has a number of subtypes defined by NodeType._type corresponding to each type of node.