at.dms.kjc
Class CTopLevel

java.lang.Object
  extended by at.dms.util.Utils
      extended by at.dms.kjc.CTopLevel
All Implemented Interfaces:
DeepCloneable, Serializable

public final class CTopLevel
extends Utils

This class implements the conceptual directory structure for .class files

See Also:
Serialized Form

Field Summary
 
Fields inherited from class at.dms.util.Utils
EMPTY_LIST, getForLoopCallers
 
Constructor Summary
CTopLevel()
           
 
Method Summary
static boolean addSourceClass(CClass cl)
           
 Object deepClone()
          Returns a deep clone of this object.
protected  void deepCloneInto(CTopLevel other)
          Clones all fields of this into
static void endSession(Compiler compiler)
           
static boolean hasClassFile(String name)
           
static void initSession(Compiler compiler)
          Removes all source classes
static CClass loadClass(String name)
          Loads class definition from .class file
 
Methods inherited from class at.dms.util.Utils
asPercent, cellMathEquivalent, cMathEquivalent, cppMathEquivalent, deepCloneInto, equalArrays, fail, getEnvironmentVariable, getExpression, hasPeeks, initArray, initArray, initLiteralArray, intArrayToList, isMathMethod, isUniform, kopi_assert, kopi_assert, makeCountdownForLoop, makeDotFileName, makeForLoop, makeForLoop, makeForLoop, makeForLoopFieldIndex, makeForLoopLocalIndex, nextPow2, passThruParens, peelMarkers, popBeforePeek, readFile, removeUnusedPops, replaceAll, setupDotFileName, simplifyMathMethod, splitQualifiedName, splitQualifiedName, toArray, toIntArray, toVector, voidToInt, writeFile
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CTopLevel

public CTopLevel()
Method Detail

loadClass

public static CClass loadClass(String name)
Loads class definition from .class file


addSourceClass

public static boolean addSourceClass(CClass cl)
Parameters:
cl - a class to add (must be a CSourceClass)
Returns:
false if name exists for source class as source class in an other file

hasClassFile

public static boolean hasClassFile(String name)
Parameters:
name - the name of the class file
Returns:
a class file that contain the class named name

initSession

public static void initSession(Compiler compiler)
Removes all source classes


endSession

public static void endSession(Compiler compiler)

deepClone

public Object deepClone()
Returns a deep clone of this object.

Specified by:
deepClone in interface DeepCloneable
Overrides:
deepClone in class Utils

deepCloneInto

protected void deepCloneInto(CTopLevel other)
Clones all fields of this into
other