org.codehaus.plexus.embed

Class Embedder

Implemented Interfaces:
PlexusEmbedder

public class Embedder
extends java.lang.Object
implements PlexusEmbedder

Field Summary

private Reader
configurationReader
private DefaultPlexusContainer
container
private boolean
embedderStarted
private boolean
embedderStopped
private Properties
properties
Context properties

Constructor Summary

Embedder()

Method Summary

void
addContextValue(Object key, Object value)
PlexusContainer
getContainer()
boolean
hasComponent(String role)
boolean
hasComponent(String role, String id)
protected void
initializeContext()
Object
lookup(String role)
Object
lookup(String role, String id)
void
release(Object service)
void
setClassWorld(ClassWorld classWorld)
void
setConfiguration(Reader configuration)
void
setConfiguration(URL configuration)
void
setLoggerManager(LoggerManager loggerManager)
void
setProperties(File file)
void
setProperties(Properties properties)
void
start()
void
start(ClassWorld classWorld)
void
stop()

Field Details

configurationReader

private Reader configurationReader

container

private final DefaultPlexusContainer container

embedderStarted

private boolean embedderStarted

embedderStopped

private boolean embedderStopped

properties

private Properties properties
Context properties

Constructor Details

Embedder

public Embedder()

Method Details

addContextValue

public void addContextValue(Object key,
                            Object value)
Specified by:
addContextValue in interface PlexusEmbedder

getContainer

public PlexusContainer getContainer()
Specified by:
getContainer in interface PlexusEmbedder

hasComponent

public boolean hasComponent(String role)
Specified by:
hasComponent in interface PlexusEmbedder

hasComponent

public boolean hasComponent(String role,
                            String id)
Specified by:
hasComponent in interface PlexusEmbedder

initializeContext

protected void initializeContext()

lookup

public Object lookup(String role)
            throws ComponentLookupException
Specified by:
lookup in interface PlexusEmbedder

lookup

public Object lookup(String role,
                     String id)
            throws ComponentLookupException
Specified by:
lookup in interface PlexusEmbedder

release

public void release(Object service)
            throws ComponentLifecycleException
Specified by:
release in interface PlexusEmbedder

setClassWorld

public void setClassWorld(ClassWorld classWorld)
Specified by:
setClassWorld in interface PlexusEmbedder

setConfiguration

public void setConfiguration(Reader configuration)
            throws IOException
Specified by:
setConfiguration in interface PlexusEmbedder

setConfiguration

public void setConfiguration(URL configuration)
            throws IOException
Specified by:
setConfiguration in interface PlexusEmbedder

setLoggerManager

public void setLoggerManager(LoggerManager loggerManager)
Specified by:
setLoggerManager in interface PlexusEmbedder

setProperties

public void setProperties(File file)
Specified by:
setProperties in interface PlexusEmbedder

setProperties

public void setProperties(Properties properties)
Specified by:
setProperties in interface PlexusEmbedder

start

public void start()
            throws PlexusContainerException
Specified by:
start in interface PlexusEmbedder

start

public void start(ClassWorld classWorld)
            throws PlexusContainerException
Specified by:
start in interface PlexusEmbedder

stop

public void stop()
Specified by:
stop in interface PlexusEmbedder