Nuxeo Enterprise Platform 5.3

org.nuxeo.osgi.application
Class StandaloneApplication

java.lang.Object
  extended by org.nuxeo.osgi.OSGiAdapter
      extended by org.nuxeo.osgi.application.StandaloneApplication

public class StandaloneApplication
extends OSGiAdapter

Author:
Bogdan Stefanescu

Field Summary
protected  SharedClassLoader classLoader
           
protected  List<File> classPath
           
protected  Environment env
           
protected  File home
           
protected  boolean isStarted
           
protected  String[] libdirs
           
static String MAIN_TASK
           
protected  boolean scanForNestedJARs
           
 
Fields inherited from class org.nuxeo.osgi.OSGiAdapter
bundleIds, bundleListeners, bundles, dataDir, frameworkListeners, idTableFile, properties, registry, serviceListeners, services, systemBundle, workingDir
 
Method Summary
protected  void autoInstallBundles()
           
static Environment createEnvironment()
           
static StandaloneApplication createInstance(SharedClassLoader cl)
           
static BundleFile createSystemBundle(URL systemBundle)
          Creates the system bundle from the jar specified by the nuxeo.osgi.system.bundle property.
 List<File> getClassPath()
           
static CommandLineOptions getComandLineOptions()
           
 Environment getEnvironment()
           
static StandaloneApplication getInstance()
           
static Runnable getMainTask()
           
 SharedClassLoader getSharedClassLoader()
           
static boolean hasCommandLineOption(String option)
           
 void install(BundleFile bf)
           
 void installAll(List<BundleFile> bundles)
           
 boolean isStarted()
           
protected  List<BundleFile> loadUserBundles(String key)
           
static void main(URL systemBundle, List<File> classPath, String[] args)
           
 void setClassPath(List<File> classPath)
           
static void setMainTask(Runnable mainTask)
           
 void shutdown()
           
 void start()
           
protected  void startBundles(List<BundleFile> bundles)
           
 
Methods inherited from class org.nuxeo.osgi.OSGiAdapter
addBundleListener, addFrameworkListener, addServiceListener, addServiceListener, fireBundleEvent, fireFrameworkEvent, fireServiceEvent, getBundleId, getDataDir, getInstalledBundles, getProperty, getProperty, getRegistry, getSystemBundle, getWorkingDir, initialize, install, removeBundleListener, removeFrameworkListener, removeServiceListener, setProperty, setSystemBundle, uninstall
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAIN_TASK

public static final String MAIN_TASK
See Also:
Constant Field Values

classLoader

protected final SharedClassLoader classLoader

env

protected final Environment env

isStarted

protected boolean isStarted

home

protected File home

classPath

protected List<File> classPath

scanForNestedJARs

protected boolean scanForNestedJARs

libdirs

protected String[] libdirs
Method Detail

getInstance

public static StandaloneApplication getInstance()

createInstance

public static StandaloneApplication createInstance(SharedClassLoader cl)
                                            throws IOException
Throws:
IOException

getSharedClassLoader

public SharedClassLoader getSharedClassLoader()

getEnvironment

public Environment getEnvironment()

start

public void start()
           throws Exception
Throws:
Exception

isStarted

public boolean isStarted()

shutdown

public void shutdown()
              throws IOException
Overrides:
shutdown in class OSGiAdapter
Throws:
IOException

startBundles

protected void startBundles(List<BundleFile> bundles)
                     throws Exception
Throws:
Exception

loadUserBundles

protected List<BundleFile> loadUserBundles(String key)
                                    throws Exception
Throws:
Exception

getClassPath

public List<File> getClassPath()

setClassPath

public void setClassPath(List<File> classPath)

autoInstallBundles

protected void autoInstallBundles()
                           throws Exception
Throws:
Exception

install

public void install(BundleFile bf)
             throws org.osgi.framework.BundleException
Throws:
org.osgi.framework.BundleException

installAll

public void installAll(List<BundleFile> bundles)
                throws org.osgi.framework.BundleException
Throws:
org.osgi.framework.BundleException

createSystemBundle

public static BundleFile createSystemBundle(URL systemBundle)
                                     throws URISyntaxException,
                                            IOException
Creates the system bundle from the jar specified by the nuxeo.osgi.system.bundle property.

Throws:
URISyntaxException
IOException

getComandLineOptions

public static CommandLineOptions getComandLineOptions()

hasCommandLineOption

public static boolean hasCommandLineOption(String option)

createEnvironment

public static Environment createEnvironment()
                                     throws IOException
Throws:
IOException

setMainTask

public static void setMainTask(Runnable mainTask)

getMainTask

public static Runnable getMainTask()

main

public static void main(URL systemBundle,
                        List<File> classPath,
                        String[] args)

Nuxeo Enterprise Platform 5.3

Copyright © 2010 Nuxeo SAS. All Rights Reserved.