com.funambol.syncclient.spap.launcher
Class JavaLauncher

java.lang.Object
  extended by com.funambol.syncclient.spap.launcher.JavaLauncher
All Implemented Interfaces:
Launcher

public class JavaLauncher
extends java.lang.Object
implements Launcher

This class represents a Laucher for the execution of java class. It uses the SimpleClassLoader in order to load the class and executes the method main(String[] args)

Version:
$Id: JavaLauncher.java,v 1.3 2007-12-22 18:09:18 nichele Exp $
See Also:
SimpleClassLoader

Constructor Summary
JavaLauncher()
           
 
Method Summary
 int execute(java.lang.String programName, boolean install, InstallationContext ctx)
          Executes the class with given name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaLauncher

public JavaLauncher()
Method Detail

execute

public int execute(java.lang.String programName,
                   boolean install,
                   InstallationContext ctx)
            throws AssetInstallationException
Executes the class with given name.

Specified by:
execute in interface Launcher
Parameters:
programName - the program to execute.
install - true if the program is the installation program, false if the program is the uninstallation program
ctx - installation context information
Returns:
Returns the exit code of the program. Exit code is the value returned of the method called or, if the method calls System.exit(code), is the code used in the exit method.
Throws:
AssetInstallationException - if the java class is not found or an error occurs during execution.


Copyright © 2010 Funambol. All Rights Reserved.