Class Util
- java.lang.Object
-
- org.glassfish.pfl.dynamic.codegen.impl.Util
-
public final class Util extends java.lang.Object
-
-
Constructor Summary
Constructors Modifier Constructor Description private
Util()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
checkScope(ExpressionInternal expr)
Throw an exception if any ExpressionInternal reachable from expr contains a Variable that is out of scope.static void
checkTree(Node node, java.io.PrintStream pw)
Check that node is really a tree, that is, when we traverse it with the visitor, we never encounter the same node twice.static void
close(Node node)
Make sure that all variables reachable from node are marked not available, indicating that they are no longer in scope.static void
display(Node node, java.io.PrintStream pw)
Display a tree for the node.private static void
displayAttributes(Node node, CodegenPrinter pr)
static java.lang.String
getNodeIdString(Node obj)
-
-
-
Method Detail
-
close
public static void close(Node node)
Make sure that all variables reachable from node are marked not available, indicating that they are no longer in scope. Note that only defining occurrences of variables are to be considered here, as a scope that merely references a variable may be closed while the containing defining scope is still open.
-
checkScope
public static void checkScope(ExpressionInternal expr)
Throw an exception if any ExpressionInternal reachable from expr contains a Variable that is out of scope. Note that this is only useful for Expressions.
-
checkTree
public static void checkTree(Node node, java.io.PrintStream pw)
Check that node is really a tree, that is, when we traverse it with the visitor, we never encounter the same node twice.
-
displayAttributes
private static void displayAttributes(Node node, CodegenPrinter pr)
-
getNodeIdString
public static java.lang.String getNodeIdString(Node obj)
-
display
public static void display(Node node, java.io.PrintStream pw)
Display a tree for the node.
-
-