koala.dynamicjava.tree
Class ConstructorDeclaration

java.lang.Object
  |
  +--koala.dynamicjava.tree.Node
        |
        +--koala.dynamicjava.tree.ConstructorDeclaration

public class ConstructorDeclaration
extends Node

This class represents constructor declarations in an AST


Field Summary
static java.lang.String ACCESS_FLAGS
          The accessFlags property name
static java.lang.String EXCEPTIONS
          The exceptions property name
static java.lang.String NAME
          The name property name
static java.lang.String PARAMETERS
          The parameters property name
static java.lang.String STATEMENTS
          The statements property name
 
Fields inherited from class koala.dynamicjava.tree.Node
BEGIN_COLUMN, BEGIN_LINE, END_COLUMN, END_LINE, FILENAME
 
Constructor Summary
ConstructorDeclaration(int flags, java.lang.String name, java.util.List params, java.util.List excepts, ConstructorInvocation eci, java.util.List stmts)
          Creates a new method declaration
ConstructorDeclaration(int flags, java.lang.String name, java.util.List params, java.util.List excepts, ConstructorInvocation eci, java.util.List stmts, java.lang.String fn, int bl, int bc, int el, int ec)
          Creates a new method declaration
 
Method Summary
 java.lang.Object acceptVisitor(Visitor visitor)
          Allows a visitor to traverse the tree
 int getAccessFlags()
          Returns the access flags for this constructor
 ConstructorInvocation getConstructorInvocation()
          The explicit constructor invocation if one or null
 java.util.List getExceptions()
          Returns the list of the exception thrown by this method
 java.lang.String getName()
          Returns the name of this constructor
 java.util.List getParameters()
          Returns the parameters list
 java.util.List getStatements()
          Returns the statements
 void setAccessFlags(int f)
          Sets the access flags for this constructor
 void setConstructorInvocation(ConstructorInvocation ci)
          Sets the constructor invocation
 void setExceptions(java.util.List l)
          Sets the exceptions thrown by this method
 void setName(java.lang.String s)
          Sets the constructor's name
 void setParameters(java.util.List l)
          Sets the parameters
 void setStatements(java.util.List l)
          Sets the statements
 
Methods inherited from class koala.dynamicjava.tree.Node
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getFilename, getProperties, getProperty, hasProperty, removePropertyChangeListener, removePropertyChangeListener, setBeginColumn, setBeginLine, setEndColumn, setEndLine, setFilename, setProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACCESS_FLAGS

public static final java.lang.String ACCESS_FLAGS
The accessFlags property name

NAME

public static final java.lang.String NAME
The name property name

PARAMETERS

public static final java.lang.String PARAMETERS
The parameters property name

EXCEPTIONS

public static final java.lang.String EXCEPTIONS
The exceptions property name

STATEMENTS

public static final java.lang.String STATEMENTS
The statements property name
Constructor Detail

ConstructorDeclaration

public ConstructorDeclaration(int flags,
                              java.lang.String name,
                              java.util.List params,
                              java.util.List excepts,
                              ConstructorInvocation eci,
                              java.util.List stmts)
Creates a new method declaration
Parameters:
flags - the access flags
name - the name of this constructor
params - the parameters list
excepts - the exception list (a list of list of token)
eci - the explicit constructor invocation
stmts - the statements
Throws:
java.lang.IllegalArgumentException - if name is null or params is null or excepts is null or stmts is null

ConstructorDeclaration

public ConstructorDeclaration(int flags,
                              java.lang.String name,
                              java.util.List params,
                              java.util.List excepts,
                              ConstructorInvocation eci,
                              java.util.List stmts,
                              java.lang.String fn,
                              int bl,
                              int bc,
                              int el,
                              int ec)
Creates a new method declaration
Parameters:
flags - the access flags
name - the name of this constructor
params - the parameters list
excepts - the exception list (a list of list of token)
eci - the explicit constructor invocation
stmts - the statements
fn - the filename
bl - the begin line
bc - the begin column
el - the end line
ec - the end column
Throws:
java.lang.IllegalArgumentException - if name is null or params is null or excepts is null or stmts is null
Method Detail

getAccessFlags

public int getAccessFlags()
Returns the access flags for this constructor

setAccessFlags

public void setAccessFlags(int f)
Sets the access flags for this constructor

getName

public java.lang.String getName()
Returns the name of this constructor

setName

public void setName(java.lang.String s)
Sets the constructor's name
Throws:
java.lang.IllegalArgumentException - if s is null

getParameters

public java.util.List getParameters()
Returns the parameters list

setParameters

public void setParameters(java.util.List l)
Sets the parameters

getExceptions

public java.util.List getExceptions()
Returns the list of the exception thrown by this method
Returns:
a list of string

setExceptions

public void setExceptions(java.util.List l)
Sets the exceptions thrown by this method
Parameters:
l - a list of string
Throws:
java.lang.IllegalArgumentException - if l is null

getConstructorInvocation

public ConstructorInvocation getConstructorInvocation()
The explicit constructor invocation if one or null

setConstructorInvocation

public void setConstructorInvocation(ConstructorInvocation ci)
Sets the constructor invocation

getStatements

public java.util.List getStatements()
Returns the statements

setStatements

public void setStatements(java.util.List l)
Sets the statements
Throws:
java.lang.IllegalArgumentException - if l is null

acceptVisitor

public java.lang.Object acceptVisitor(Visitor visitor)
Allows a visitor to traverse the tree
Overrides:
acceptVisitor in class Node
Parameters:
visitor - the visitor to accept


Copyright © 2001 Stephane Hillion. All Rights Reserved.