|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
org.apache.sling.installer.core.impl.OsgiInstallerImpl
public class OsgiInstallerImpl
Worker thread where all OSGi tasks are executed. Runs cycles where the list of RegisteredResources is examined, OsgiTasks are created accordingly and executed. A separate list of RegisteredResources is kept for resources that are updated or removed during a cycle, and merged with the main list at the end of the cycle.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
Thread.State, Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
OsgiInstallerImpl(org.osgi.framework.BundleContext ctx)
Constructor |
Method Summary | |
---|---|
void |
bundleChanged(org.osgi.framework.BundleEvent e)
|
void |
deactivate()
Deactivate |
void |
frameworkEvent(org.osgi.framework.FrameworkEvent event)
|
PersistentResourceList |
getPersistentResourceList()
|
Object |
getResourcesLock()
|
static long |
getTotalEventsCount()
Used for tasks that wait for a framework or bundle event before retrying their operations |
void |
registerResources(String scheme,
InstallableResource[] resources)
Provide the installer with the complete list of installable resources for a given client. |
void |
run()
|
void |
updateResources(String scheme,
InstallableResource[] resources,
String[] ids)
Inform the installer that resources are available for installation and/or other resources are no longer available. |
void |
wakeUp()
Wake up the run cycle. |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public OsgiInstallerImpl(org.osgi.framework.BundleContext ctx)
Method Detail |
---|
public void deactivate()
public void run()
run
in interface Runnable
run
in class Thread
public Object getResourcesLock()
public PersistentResourceList getPersistentResourceList()
public void updateResources(String scheme, InstallableResource[] resources, String[] ids)
OsgiInstaller
updateResources
in interface OsgiInstaller
scheme
- identifies the client.ids
- An array of identifiers for removed resources - might be nullOsgiInstaller.updateResources(java.lang.String, org.apache.sling.installer.api.InstallableResource[], java.lang.String[])
public void registerResources(String scheme, InstallableResource[] resources)
OsgiInstaller
registerResources
in interface OsgiInstaller
scheme
- identifies the client.resources
- the list of available resourcesOsgiInstaller.registerResources(java.lang.String, org.apache.sling.installer.api.InstallableResource[])
public void bundleChanged(org.osgi.framework.BundleEvent e)
bundleChanged
in interface org.osgi.framework.BundleListener
BundleListener.bundleChanged(org.osgi.framework.BundleEvent)
public static long getTotalEventsCount()
public void frameworkEvent(org.osgi.framework.FrameworkEvent event)
frameworkEvent
in interface org.osgi.framework.FrameworkListener
FrameworkListener.frameworkEvent(org.osgi.framework.FrameworkEvent)
public void wakeUp()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |