Top Description Fields Constructors Methods
org.codehaus.groovy.ast

public Class ASTNode

extends Object
implements NodeMetaDataHandler
Class Inheritance
All Implemented Interfaces
org.codehaus.groovy.ast.NodeMetaDataHandler
Known Direct Subclasses
org.codehaus.groovy.ast.GenericsType, org.codehaus.groovy.ast.ModifierNode, org.codehaus.groovy.ast.ModuleNode, org.codehaus.groovy.ast.stmt.Statement, org.codehaus.groovy.ast.AnnotatedNode, org.codehaus.groovy.ast.AnnotationNode
Imports
java.util.Map

Base class for any AST node. This class supports basic information used in all nodes of the AST:

Field Summary

Modifier and TypeField and Description
private int
private int
private int
private int
private Map<?, ?>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
copyNodeMetaData(final ASTNode
- the other node
other
)

Copies all node meta data from the other node to this one

public int
public int
public int
public int
public Map<?, ?>
public String
public void
setColumnNumber(final int columnNumber)

public void
setLastColumnNumber(final int lastColumnNumber)

public void
setLastLineNumber(final int lastLineNumber)

public void
setLineNumber(final int lineNumber)

public void
public void
setSourcePosition(final ASTNode
- the node used to configure the position information
node
)

Sets the source position using another ASTNode.

public void
visit(final GroovyCodeVisitor visitor)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

columnNumberback to summary
private int columnNumber
lastColumnNumberback to summary
private int lastColumnNumber
lastLineNumberback to summary
private int lastLineNumber
lineNumberback to summary
private int lineNumber
metaDataMapback to summary
private Map<?, ?> metaDataMap

Constructor Detail

ASTNodeback to summary
public ASTNode()

Method Detail

copyNodeMetaDataback to summary
public void copyNodeMetaData(final ASTNode other)

Copies all node meta data from the other node to this one

Parameters
other:ASTNode

- the other node

getColumnNumberback to summary
public int getColumnNumber()
getLastColumnNumberback to summary
public int getLastColumnNumber()
getLastLineNumberback to summary
public int getLastLineNumber()
getLineNumberback to summary
public int getLineNumber()
getMetaDataMapback to summary
public Map<?, ?> getMetaDataMap()

Implements org.codehaus.groovy.ast.NodeMetaDataHandler.getMetaDataMap.

Annotations
@Override
getTextback to summary
public String getText()
setColumnNumberback to summary
public void setColumnNumber(final int columnNumber)
setLastColumnNumberback to summary
public void setLastColumnNumber(final int lastColumnNumber)
setLastLineNumberback to summary
public void setLastLineNumber(final int lastLineNumber)
setLineNumberback to summary
public void setLineNumber(final int lineNumber)
setMetaDataMapback to summary
public void setMetaDataMap(final Map<?, ?> metaDataMap)

Implements org.codehaus.groovy.ast.NodeMetaDataHandler.setMetaDataMap.

Annotations
@Override
setSourcePositionback to summary
public void setSourcePosition(final ASTNode node)

Sets the source position using another ASTNode. The sourcePosition consists of a line/column pair for the start and a line/column pair for the end of the expression or statement

Parameters
node:ASTNode

- the node used to configure the position information

visitback to summary
public void visit(final GroovyCodeVisitor visitor)