jif.ast
Class Jif_c

java.lang.Object
  extended by polyglot.ast.Ext_c
      extended by jif.ast.Jif_c
All Implemented Interfaces:
java.lang.Cloneable, Jif, polyglot.ast.Ext, polyglot.util.Copy
Direct Known Subclasses:
JifClassBodyExt, JifClassDeclExt, JifExprExt, JifFieldDeclExt_c, JifFormalExt, JifInitializerExt, JifProcedureDeclExt_c, JifSourceFileExt, JifStmtExt_c

public class Jif_c
extends polyglot.ast.Ext_c
implements Jif

An implementation of the Jif interface.


Field Summary
protected  ToJavaExt toJava
           
protected  PathMap X
           
 
Fields inherited from class polyglot.ast.Ext_c
ext, node
 
Constructor Summary
Jif_c(ToJavaExt toJava)
           
 
Method Summary
static void checkAndRemoveThrowType(java.util.List throwTypes, polyglot.types.Type excType)
          Check that the type excType is indeed in the list of types thrown, throwTypes, and remove excType from that list.
static void checkThrowTypes(java.util.List throwTypes)
          Check that the list of types thrown, throwTypes, does not contain any checked exceptions, i.e., all throw types have been correctly label checked.
 java.lang.Object copy()
           
static PathMap getPathMap(polyglot.ast.Node n)
           
 void init(polyglot.ast.Node node)
           
 void integerBoundsCalculated()
          A method that is called to notify the extension that the numeric bounds have been calculated.
 polyglot.ast.Node labelCheck(LabelChecker lc)
          Label check the node to which this extension is attached.
 ToJavaExt toJava()
           
 Jif toJava(ToJavaExt toJava)
           
static polyglot.ast.Node updatePathMap(polyglot.ast.Node n, PathMap X)
           
 PathMap X()
          Gets the path map of this extension.
 Jif X(PathMap X)
          Returns a copy of this object with the path map updated.
 
Methods inherited from class polyglot.ast.Ext_c
dump, ext, ext, node, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface polyglot.ast.Ext
dump, ext, ext, node
 

Field Detail

X

protected PathMap X

toJava

protected ToJavaExt toJava
Constructor Detail

Jif_c

public Jif_c(ToJavaExt toJava)
Method Detail

toJava

public ToJavaExt toJava()
Specified by:
toJava in interface Jif

init

public void init(polyglot.ast.Node node)
Specified by:
init in interface polyglot.ast.Ext
Overrides:
init in class polyglot.ast.Ext_c

toJava

public Jif toJava(ToJavaExt toJava)
Specified by:
toJava in interface Jif

copy

public java.lang.Object copy()
Specified by:
copy in interface polyglot.util.Copy
Overrides:
copy in class polyglot.ast.Ext_c

X

public PathMap X()
Description copied from interface: Jif
Gets the path map of this extension.

Specified by:
X in interface Jif

X

public Jif X(PathMap X)
Description copied from interface: Jif
Returns a copy of this object with the path map updated.

Specified by:
X in interface Jif

labelCheck

public polyglot.ast.Node labelCheck(LabelChecker lc)
                             throws polyglot.types.SemanticException
Description copied from interface: Jif
Label check the node to which this extension is attached.

Specified by:
labelCheck in interface Jif
Throws:
polyglot.types.SemanticException

getPathMap

public static PathMap getPathMap(polyglot.ast.Node n)

updatePathMap

public static polyglot.ast.Node updatePathMap(polyglot.ast.Node n,
                                              PathMap X)

checkAndRemoveThrowType

public static void checkAndRemoveThrowType(java.util.List throwTypes,
                                           polyglot.types.Type excType)
Check that the type excType is indeed in the list of types thrown, throwTypes, and remove excType from that list.

Parameters:
throwTypes -
excType -

checkThrowTypes

public static void checkThrowTypes(java.util.List throwTypes)
Check that the list of types thrown, throwTypes, does not contain any checked exceptions, i.e., all throw types have been correctly label checked.

Parameters:
throwTypes -

integerBoundsCalculated

public void integerBoundsCalculated()
Description copied from interface: Jif
A method that is called to notify the extension that the numeric bounds have been calculated.

Specified by:
integerBoundsCalculated in interface Jif