alt.jiapi.util
Class Bootstrapper

java.lang.Object
  extended by alt.jiapi.util.Bootstrapper

public class Bootstrapper
extends java.lang.Object

Bootstrapper which can be used to launch applications based on Jiapi. Bootstrapper is needed so that the classes are loaded to same name space. There's two phases during the bootstrap process:

Version:
$Revision: 1.5 $ $Date: 2006/01/31 12:53:04 $
Author:
Mika Riekkinen, Joni Suominen

Constructor Summary
Bootstrapper(java.lang.String className, java.lang.String methodName, java.lang.Class[] parameterTypes, java.lang.Object[] args, java.lang.ClassLoader classLoader)
           
 
Method Summary
 void bootstrap(java.lang.String className, java.lang.String methodName, java.lang.Class[] parameterTypes, java.lang.Object[] args, java.lang.ClassLoader classLoader)
          This method is used to bootstrap an application.
static void launch(java.lang.String className, java.lang.Object[] args, InstrumentationContext ctx, java.lang.ClassLoader classLoader)
          A utility method which is usually used from Jiapi applications to launch a target application for instrumentation.
static void launch(java.lang.String className, java.lang.String methodName, java.lang.Class[] parameterTypes, java.lang.Object[] args, InstrumentationContext ctx, java.lang.ClassLoader classLoader)
          A utility method which is usually used from Jiapi applications to launch a target application for instrumentation.
static void main(java.lang.String[] args)
          A command-line entry point.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Bootstrapper

public Bootstrapper(java.lang.String className,
                    java.lang.String methodName,
                    java.lang.Class[] parameterTypes,
                    java.lang.Object[] args,
                    java.lang.ClassLoader classLoader)
Method Detail

bootstrap

public void bootstrap(java.lang.String className,
                      java.lang.String methodName,
                      java.lang.Class[] parameterTypes,
                      java.lang.Object[] args,
                      java.lang.ClassLoader classLoader)
This method is used to bootstrap an application. The command-line entry point uses this method to start a Jiapi application.

Parameters:
className - a fully qualified name of a class to bootstrap
methodName - name of a method to call (e.g. "main")
parameterTypes - parameter types of a method
args - arguments for a method
classLoader - to be used, the given classloader should implement setContext method

launch

public static void launch(java.lang.String className,
                          java.lang.Object[] args,
                          InstrumentationContext ctx,
                          java.lang.ClassLoader classLoader)
A utility method which is usually used from Jiapi applications to launch a target application for instrumentation. It ensures that the classes are properly loaded to a same name space. The target classe's main(String args[]) method is called.

Parameters:
className - a fully qualified name of a class to bootstrap
args - arguments for a method
classLoader - which loaded the calling application

launch

public static void launch(java.lang.String className,
                          java.lang.String methodName,
                          java.lang.Class[] parameterTypes,
                          java.lang.Object[] args,
                          InstrumentationContext ctx,
                          java.lang.ClassLoader classLoader)
A utility method which is usually used from Jiapi applications to launch a target application for instrumentation. It ensures that the classes are properly loaded to a same name space.

Parameters:
className - a fully qualified name of a class to bootstrap
methodName - name of a method to call (e.g. "main")
parameterTypes - parameter types of a method
args - arguments for a method
classLoader - which loaded the calling application

main

public static void main(java.lang.String[] args)
A command-line entry point.



Copyright © 2001. Documenation generated August 26 2011.