576 */
577 public ValueHandler createValueHandler()
578 {
579 return valueHandlerSingleton;
580 }
581
582 /**
583 * Returns the codebase, if any, for the given class.
584 * @param clz the class to get a codebase for.
585 * @return a space-separated list of URLs, or null.
586 */
587 public String getCodebase(java.lang.Class clz) {
588 return RMIClassLoader.getClassAnnotation(clz);
589 }
590
591 /**
592 * Returns a class instance for the specified class.
593 * @param className the name of the class.
594 * @param remoteCodebase a space-separated list of URLs at which
595 * the class might be found. May be null.
596 * @param loadingContext a class whose ClassLoader may be used to
597 * load the class if all other methods fail.
598 * @return the <code>Class</code> object representing the loaded class.
599 * @exception ClassNotFoundException if class cannot be loaded.
600 */
601 public Class loadClass( String className, String remoteCodebase,
602 ClassLoader loader) throws ClassNotFoundException
603 {
604 return JDKBridge.loadClass(className,remoteCodebase,loader);
605 }
606
607 /**
608 * The <tt>isLocal</tt> method has the same semantics as the
609 * ObjectImpl._is_local method, except that it can throw a RemoteException.
610 * (no it doesn't but the spec says it should.)
611 *
612 * The <tt>_is_local()</tt> method is provided so that stubs may determine
613 * if a particular object is implemented by a local servant and hence local
614 * invocation APIs may be used.
615 *
616 * @param stub the stub to test.
|
576 */
577 public ValueHandler createValueHandler()
578 {
579 return valueHandlerSingleton;
580 }
581
582 /**
583 * Returns the codebase, if any, for the given class.
584 * @param clz the class to get a codebase for.
585 * @return a space-separated list of URLs, or null.
586 */
587 public String getCodebase(java.lang.Class clz) {
588 return RMIClassLoader.getClassAnnotation(clz);
589 }
590
591 /**
592 * Returns a class instance for the specified class.
593 * @param className the name of the class.
594 * @param remoteCodebase a space-separated list of URLs at which
595 * the class might be found. May be null.
596 * @param loader a class whose ClassLoader may be used to
597 * load the class if all other methods fail.
598 * @return the <code>Class</code> object representing the loaded class.
599 * @exception ClassNotFoundException if class cannot be loaded.
600 */
601 public Class loadClass( String className, String remoteCodebase,
602 ClassLoader loader) throws ClassNotFoundException
603 {
604 return JDKBridge.loadClass(className,remoteCodebase,loader);
605 }
606
607 /**
608 * The <tt>isLocal</tt> method has the same semantics as the
609 * ObjectImpl._is_local method, except that it can throw a RemoteException.
610 * (no it doesn't but the spec says it should.)
611 *
612 * The <tt>_is_local()</tt> method is provided so that stubs may determine
613 * if a particular object is implemented by a local servant and hence local
614 * invocation APIs may be used.
615 *
616 * @param stub the stub to test.
|