Class OSGIListener.ClassCodeBaseHandlerImpl

java.lang.Object
com.sun.corba.ee.impl.osgi.loader.OSGIListener.ClassCodeBaseHandlerImpl
All Implemented Interfaces:
ClassCodeBaseHandler
Enclosing class:
OSGIListener

private static class OSGIListener.ClassCodeBaseHandlerImpl extends Object implements ClassCodeBaseHandler
  • Field Details

  • Constructor Details

    • ClassCodeBaseHandlerImpl

      private ClassCodeBaseHandlerImpl()
  • Method Details

    • classNotFoundInBundle

      @InfoMethod private void classNotFoundInBundle(String name)
    • foundClassInBundleVersion

      @InfoMethod private void foundClassInBundleVersion(Class<?> cls, String name, String version)
    • getCodeBase

      public String getCodeBase(Class<?> cls)
      Description copied from interface: ClassCodeBaseHandler
      Returns some sort of codebase for the given class, or null. It is expected that, if str is the result of getCodeBase( cls ), then loadClass( str, cls.getClassName() ) will return cls.
      Specified by:
      getCodeBase in interface ClassCodeBaseHandler
      Parameters:
      cls - Class for which we need a codebase
      Returns:
      A codebase to use with this handler, or null if this handler does not apply to this class.
    • couldNotLoadClassInBundle

      @InfoMethod private void couldNotLoadClassInBundle(ClassNotFoundException exc, String className, String bname)
    • foundClassInBundleVersion

      @InfoMethod private void foundClassInBundleVersion(String cname, String bname, String version)
    • classNotFoundInBundleVersion

      @InfoMethod private void classNotFoundInBundleVersion(String cname, String bname, String version)
    • loadClass

      public Class<?> loadClass(String codebase, String className)
      Description copied from interface: ClassCodeBaseHandler
      load a class given the classname and a codebase. The className will always satisfy cls.getClassName().equals( className ) if the call succeeds and returns a Class.
      Specified by:
      loadClass in interface ClassCodeBaseHandler
      Parameters:
      codebase - A string that somehow describes which ClassLoader to use. For example, the string could be an ordinary URL that a URL ClassLoader can use, or something more specialized, such as a description of an OSGi bundles and version.
      className - The name of the class to load
      Returns:
      The loaded class, or null if the class could not be loaded.