|
Object-oriented Parser System v3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectGl.Tree
Tree
public class Tree
tree factory to evaluate a Guarded Language program. Each factory method is overridden to substitute the interpreter class. Each branch node class is extended for interpretation.
| Nested Class Summary | |
|---|---|
static class |
Tree.Add
tree node class. |
static class |
Tree.AndIf
tree node class. |
static class |
Tree.Assign
tree node class. |
static class |
Tree.Deref
tree node class. |
static class |
Tree.Div
tree node class. |
static class |
Tree.Eq
tree node class. |
static class |
Tree.Ge
tree node class. |
static class |
Tree.Gt
tree node class. |
static interface |
Tree.Interpreter
what an interpreter branch node can do. |
static class |
Tree.Le
tree node class. |
static class |
Tree.Lit
tree node class. |
static class |
Tree.Loop
tree node class. |
static class |
Tree.Lt
tree node class. |
static class |
Tree.Mul
tree node class. |
static class |
Tree.Ne
tree node class. |
static class |
Tree.OrIf
tree node class. |
static class |
Tree.Print
tree node class. |
static class |
Tree.Rem
tree node class. |
static class |
Tree.Select
tree node class. |
static class |
Tree.Sub
tree node class. |
static class |
Tree.With
tree node class. |
| Nested classes/interfaces inherited from class Gl.Tree |
|---|
Gl.Tree.Guard, Gl.Tree.Stmt, Gl.Tree.Var, Gl.Tree.Visit, Gl.Tree.Visitor |
| Constructor Summary | |
|---|---|
Tree()
|
|
| Method Summary | |
|---|---|
Tree.Add |
add(int position,
List args)
factory method. |
Tree.AndIf |
andif(int position,
List args)
factory method. |
Tree.Assign |
assign(int position,
List args)
factory method. |
Tree.Deref |
deref(int position,
List args)
factory method. |
Tree.Div |
div(int position,
List args)
factory method. |
Tree.Eq |
eq(int position,
List args)
factory method. |
protected static List<Gl.Tree.Guard> |
evalGuards(List guards,
Env env)
return true guards. |
protected static void |
evalRandomStmts(List<Gl.Tree.Guard> guards,
Env env)
evaluate tail of randomly selected guard. |
protected static void |
evalStmts(List stmts,
int offset,
Env env)
evaluate tail of list. |
Tree.Ge |
ge(int position,
List args)
factory method. |
Tree.Gt |
gt(int position,
List args)
factory method. |
Tree.Le |
le(int position,
List args)
factory method. |
Tree.Loop |
loop(int position,
List args)
factory method. |
Tree.Lt |
lt(int position,
List args)
factory method. |
static void |
main(String[] args)
main program to compile and interpret a Guarded Language program. |
Tree.Mul |
mul(int position,
List args)
factory method. |
Tree.Ne |
ne(int position,
List args)
factory method. |
Tree.Lit |
number(int position,
List args)
factory method. |
Tree.OrIf |
orif(int position,
List args)
factory method. |
Tree.Print |
print(int position,
List args)
factory method. |
Tree.Rem |
rem(int position,
List args)
factory method. |
Tree.Select |
select(int position,
List args)
factory method. |
Tree.Sub |
sub(int position,
List args)
factory method. |
Tree.With |
with(int position,
List args)
factory method. |
| Methods inherited from class Gl.Tree |
|---|
add, guard, remove, stmt, var |
| Methods inherited from class Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Tree()
| Method Detail |
|---|
protected static List<Gl.Tree.Guard> evalGuards(List guards,
Env env)
protected static void evalRandomStmts(List<Gl.Tree.Guard> guards,
Env env)
protected static void evalStmts(List stmts,
int offset,
Env env)
public static void main(String[] args)
throws Exception
Exception
public Tree.Select select(int position,
List args)
select in class Gl.Tree
public Tree.Loop loop(int position,
List args)
loop in class Gl.Tree
public Tree.Print print(int position,
List args)
print in class Gl.Tree
public Tree.With with(int position,
List args)
with in class Gl.Tree
public Tree.OrIf orif(int position,
List args)
orif in class Gl.Tree
public Tree.AndIf andif(int position,
List args)
andif in class Gl.Tree
public Tree.Eq eq(int position,
List args)
eq in class Gl.Tree
public Tree.Ne ne(int position,
List args)
ne in class Gl.Tree
public Tree.Lt lt(int position,
List args)
lt in class Gl.Tree
public Tree.Le le(int position,
List args)
le in class Gl.Tree
public Tree.Gt gt(int position,
List args)
gt in class Gl.Tree
public Tree.Ge ge(int position,
List args)
ge in class Gl.Tree
public Tree.Add add(int position,
List args)
add in class Gl.Tree
public Tree.Sub sub(int position,
List args)
sub in class Gl.Tree
public Tree.Mul mul(int position,
List args)
mul in class Gl.Tree
public Tree.Div div(int position,
List args)
div in class Gl.Tree
public Tree.Rem rem(int position,
List args)
rem in class Gl.Tree
public Tree.Lit number(int position,
List args)
number in class Gl.Tree
public Tree.Deref deref(int position,
List args)
deref in class Gl.Tree
public Tree.Assign assign(int position,
List args)
assign in class Gl.Tree
|
(c) 2008 Axel T. Schreiner |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||