DynamicJava Javadoc: Class BufferedImportationManager

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## koala.dynamicjava.util
Class BufferedImportationManager

    java.lang.Object
      |
      +--koala.dynamicjava.util.ImportationManager
            |
            +--koala.dynamicjava.util.BufferedImportationManager

All Implemented Interfaces:
  java.lang.Cloneable

public class BufferedImportationManager
extends ImportationManager

A buffered version of the importation manager

Field Summary
`protected java.util.Map` | `buffer` The class buffer

Fields inherited from class koala.dynamicjava.util.ImportationManager
`classLoader, currentPackage, importOnDemandClauses, singleTypeImportClauses`

Constructor Summary
`` | `BufferedImportationManager(java.lang.ClassLoader cl)` Creates a new importation manager.
`protected` | `BufferedImportationManager(ImportationManager im)` Copy constructor

Method Summary
`java.lang.Object` | `clone()` Returns a copy of this object
`void` | `declareClassImport(java.lang.String cname)` Declares a new single-type-import clause
`void` | `declarePackageImport(java.lang.String pkg)` Declares a new import-on-demand clause
`java.lang.Class` | `lookupClass(java.lang.String cname, java.lang.String ccname)` Loads the class that match to the given name in the source file
`void` | `setCurrentPackage(java.lang.String pkg)` Sets the current package.

Methods inherited from class koala.dynamicjava.util.ImportationManager
`findInnerClass, getCurrentPackage, getImportOnDemandClauses, getOuterNames, getSingleTypeImportClauses, hasSuffix, setClassLoader`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### buffer

    protected java.util.Map buffer

  The class buffer

Constructor Detail

### BufferedImportationManager

    public BufferedImportationManager(java.lang.ClassLoader cl)

  Creates a new importation manager.
  Parameters:
    `cl` - the class loader to use

### BufferedImportationManager

    protected BufferedImportationManager(ImportationManager im)

  Copy constructor

Method Detail

### clone

    public java.lang.Object clone()

  Returns a copy of this object
  Overrides:
    `clone` in class `ImportationManager`

### setCurrentPackage

    public void setCurrentPackage(java.lang.String pkg)

  Sets the current package. This has no influence on the behaviour of the `lookupClass` method.
  Overrides:
    `setCurrentPackage` in class `ImportationManager`
  Parameters:
    `pkg` - the package name

### declarePackageImport

    public void declarePackageImport(java.lang.String pkg)

  Declares a new import-on-demand clause
  Overrides:
    `declarePackageImport` in class `ImportationManager`
  Parameters:
    `pkg` - the package name

### declareClassImport

    public void declareClassImport(java.lang.String cname)
                            throws java.lang.ClassNotFoundException

  Declares a new single-type-import clause
  Overrides:
    `declareClassImport` in class `ImportationManager`
  Parameters:
    `cname` - the fully qualified class name
  Throws:
    `java.lang.ClassNotFoundException` - if the class cannot be found

### lookupClass

    public java.lang.Class lookupClass(java.lang.String cname,
                                       java.lang.String ccname)
                                throws java.lang.ClassNotFoundException

  Loads the class that match to the given name in the source file
  Overrides:
    `lookupClass` in class `ImportationManager`
  Parameters:
    `cname` - the name of the class to find
    `ccname` - the name of the current class or null
  Returns:
    the class found
  Throws:
    `java.lang.ClassNotFoundException` - if the class cannot be loaded

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001 Stephane Hillion. All Rights Reserved.