ESC/Java2
© 2003,2004,2005 David Cok and Joseph Kiniry
© 2005 UCD Dublin
© 2003,2004 Radboud University Nijmegen
© 1999,2000 Compaq Computer Corporation
© 1997,1998,1999 Digital Equipment Corporation
All Rights Reserved

javafe.ast
Class RoutineDecl

java.lang.Object
  extended byjavafe.ast.ASTNode
      extended byjavafe.ast.RoutineDecl
All Implemented Interfaces:
java.lang.Cloneable, TypeDeclElem
Direct Known Subclasses:
ConstructorDecl, MethodDecl

public abstract class RoutineDecl
extends ASTNode
implements TypeDeclElem

Represents both MethodDeclarations and ConstructorDeclarations.


Field Summary
 FormalParaDeclVec args
           
private  Type[] argtypes
           
 boolean binaryArgNames
           
 BlockStmt body
           
 boolean implicit
           
 int loc
           
 int locId
           
 int locOpenBrace
           
 int locThrowsKeyword
           
 int modifiers
           
 TypeNameVec originalRaises
           
 TypeDecl parent
           
 ModifierPragmaVec pmodifiers
           
 TypeNameVec raises
           
 TypeModifierPragmaVec tmodifiers
           
 
Fields inherited from class javafe.ast.ASTNode
decorations
 
Constructor Summary
protected RoutineDecl()
          Construct a raw RoutineDecl whose class invariant(s) have not yet been established.
 
Method Summary
 Type[] argTypes()
           
 void check()
           
 int getEndLoc()
           
 int getModifiers()
           
 TypeDecl getParent()
          The TypeDecl we are an element of, or null if we do not have a parent (cf. hasParent).
 ModifierPragmaVec getPModifiers()
           
 int getStartLoc()
           
abstract  Identifier id()
           
private  void postCheck()
           
 void setModifiers(int m)
           
 void setParent(TypeDecl p)
           
 
Methods inherited from class javafe.ast.ASTNode
accept, accept, childAt, childCount, clone, clone, getDecorations, getTag, setDecorations, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javafe.ast.TypeDeclElem
accept, accept, getTag
 

Field Detail

parent

public TypeDecl parent

binaryArgNames

public boolean binaryArgNames

implicit

public boolean implicit

originalRaises

public TypeNameVec originalRaises

modifiers

public int modifiers

pmodifiers

public ModifierPragmaVec pmodifiers

tmodifiers

public TypeModifierPragmaVec tmodifiers

args

public FormalParaDeclVec args

raises

public TypeNameVec raises

body

public BlockStmt body

locOpenBrace

public int locOpenBrace

loc

public int loc

locId

public int locId

locThrowsKeyword

public int locThrowsKeyword

argtypes

private Type[] argtypes
Constructor Detail

RoutineDecl

protected RoutineDecl()
Construct a raw RoutineDecl whose class invariant(s) have not yet been established. It is the caller's job to initialize the returned node's fields so that any class invariants hold.

Method Detail

postCheck

private void postCheck()

getParent

public TypeDecl getParent()
Description copied from interface: TypeDeclElem
The TypeDecl we are an element of, or null if we do not have a parent (cf. hasParent).

Specified by:
getParent in interface TypeDeclElem

setParent

public void setParent(TypeDecl p)
Specified by:
setParent in interface TypeDeclElem

getModifiers

public int getModifiers()
Specified by:
getModifiers in interface TypeDeclElem

setModifiers

public void setModifiers(int m)
Specified by:
setModifiers in interface TypeDeclElem

getPModifiers

public ModifierPragmaVec getPModifiers()
Specified by:
getPModifiers in interface TypeDeclElem

getStartLoc

public int getStartLoc()
Specified by:
getStartLoc in interface TypeDeclElem
Specified by:
getStartLoc in class ASTNode

id

public abstract Identifier id()

getEndLoc

public int getEndLoc()
Overrides:
getEndLoc in class ASTNode

argTypes

public Type[] argTypes()

check

public void check()
Overrides:
check in class ASTNode

ESC/Java2
© 2003,2004,2005 David Cok and Joseph Kiniry
© 2005 UCD Dublin
© 2003,2004 Radboud University Nijmegen
© 1999,2000 Compaq Computer Corporation
© 1997,1998,1999 Digital Equipment Corporation
All Rights Reserved

The ESC/Java2 Project Homepage