public class SandboxedModuleManager extends Object implements SandboxedModuleHelper, FeatureStateListener
Constructor and Description |
---|
SandboxedModuleManager() |
Modifier and Type | Method and Description |
---|---|
SandboxedModule |
getCurrentModule()
Returns the
SandboxedModule associated with the current thread context. |
SandboxedModule |
getModule(String moduleName)
Returns the
SandboxedModule that owns the given module name. |
void |
stateChanged(Feature app,
Feature.State previousState)
Called when the state of a Feature has changed.
|
public SandboxedModule getCurrentModule()
SandboxedModuleHelper
SandboxedModule
associated with the current thread context.getCurrentModule
in interface SandboxedModuleHelper
SandboxedModule
owning the current execution context.@Nullable public SandboxedModule getModule(String moduleName)
SandboxedModuleHelper
SandboxedModule
that owns the given module name.getModule
in interface SandboxedModuleHelper
moduleName
- the name of the module to look up.SandboxedModule
, or null
if none found.public void stateChanged(Feature app, @Nullable Feature.State previousState)
FeatureStateListener
stateChanged
in interface FeatureStateListener
app
- the Feature which state has changedpreviousState
- the previous state, null
if Feature state is Feature.State.INSTALLED