On this page
[Java] Class PreJava2GroovyConverter
- org.codehaus.groovy.antlr.java.PreJava2GroovyConverter
@Deprecated
public class PreJava2GroovyConverter
extends VisitorAdapter
This class mutates the Java AST, whilst it is still a Java AST, in readiness for conversion to Groovy, yippee-ky-a !
Constructor Summary
Constructor and description |
---|
PreJava2GroovyConverter (String[] tokenNames) |
Methods Summary
Type Params | Return Type | Name and description |
---|---|---|
public GroovySourceAST |
pop() |
|
public void |
push(GroovySourceAST t) |
|
public void |
swapTwoChildren(GroovySourceAST t) To swap two children of node t... |
|
public void |
visitDefault(GroovySourceAST t, int visit) |
Inherited Methods Summary
Constructor Detail
public PreJava2GroovyConverter(String[] tokenNames)
Method Detail
public GroovySourceAST pop()
public void push(GroovySourceAST t)
public void swapTwoChildren(GroovySourceAST t)
To swap two children of node t...
(t)
|
|
(a) -- (b)
t.down = firstNode
a.right = b
b.right = null
becomes
(t)
|
|
(b) -- (a)
t.down = b
a.right = null
b.right = a
todo - build API of basic tree mutations like this method.
public void visitDefault(GroovySourceAST t, int visit)
© 2003-2020 The Apache Software Foundation
Licensed under the Apache license.
https://docs.groovy-lang.org/3.0.9/html/gapi/org/codehaus/groovy/antlr/java/PreJava2GroovyConverter.html