All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.jaw.impl.agent.services.mlet.LauncherSrv
java.lang.Object
|
+----com.sun.jaw.impl.agent.services.mlet.LauncherSrv
- public class LauncherSrv
- extends Object
- implements Serializable
This class will demand the MLet Service to load all the HTML files contained in a specific directory.
If the initCmf method of the object is called, the MLet Service used will be the one registered within the repository with the
following ObjectName:
defaultDomain:com.sun.jaw.impl.agent.services.mlet.MLetSrvMO
The directory used by the service to look for files defaults depending on the operating environment to:
- Solaris :
/etc/opt/SUNWconn/jaw/launch
- Windows NT :
<installDir>\SUNWconn\jaw\etc\launch
The service will load the files using alphanumeric ordering.
It is possible to specify a path containing several directories. To do so, use the
path separator specific to the platform on which you are running the agent (check
the "path.separator" property).
There are several ways for specifying a path:
- specify a path property in the object name you give to the service;
- directly invoke the setPath method.
-
LauncherSrv()
- Default constructor.
-
LauncherSrv(MLetSrv)
- Create a launching service.
-
LauncherSrv(MLetSrv, String)
- Create a launching service with a specific path.
-
getClassVersion()
- Returns the version of this class.
-
getMLetSrv()
- Returns a reference on the mlet service invoked for loading.
-
getMLetSrvObjectName()
- Returns a String representing the ObjectName
of the mlet service invoked for loading.
-
getPath()
- Returns the path used by the service.
-
getThreadGroup()
- Get the thread group used for creating the threads.
-
initCmf(Framework, ObjectName, boolean, ModificationList)
- Initialize the Launcher Service.
-
performLaunch()
- Load the content of the path.
-
setMLetSrv(MLetSrv)
- Sets direct reference to the mlet service to use.
-
setMLetSrvObjectName(String)
- Sets a String representing the ObjectName
of the mlet service to use.
-
setPath(String)
- Sets the path used for loading the HTML files.
-
setThreadGroup(ThreadGroup)
- Set the thread group to use when creating the threads for loading.
LauncherSrv
public LauncherSrv()
- Default constructor.
Default path will be used.
LauncherSrv
public LauncherSrv(MLetSrv mletSrv)
- Create a launching service.
- Parameters:
- mletSrv - reference to the mlet service to invoke
LauncherSrv
public LauncherSrv(MLetSrv mletSrv,
String path)
- Create a launching service with a specific path.
- Parameters:
- mletSrv - reference to the mlet service to invoke
- path - path to look for the HTML files
initCmf
public void initCmf(Framework cmf,
ObjectName name,
boolean db,
ModificationList list) throws InstanceAlreadyExistException
- Initialize the Launcher Service.
The method will declare the object to the Core Management Framework.
For internal use only.
- Parameters:
- agent - The core management framework to register the service with.
- name - Object name containing configuration information.
- db - Indicates if persistent storage is required.
- list - The modification list to use for setting up parameters.
- Throws: InstanceAlreadyExistException
- The m-bean is already registered in the repository.
performLaunch
public void performLaunch() throws ServiceNotFoundException
- Load the content of the path.
The method will ask the mlet service associated to the launcher to load all the
files contained in a given path.
If there is no mlet service associated, a ServiceNotFoundException is thrown.
If an objet name for the mlet is given, it has precedence over a direct reference to a
mlet object.
Every single loading is invoked in a separate thread.
All the created threads are created in the same ThreadGroup.
They are named using the directory name currently loaded.
- Throws: ServiceNotFoundException
- The MLet Service couldn't be found.
- See Also:
- getThreadGroup, setThreadGroup
getPath
public String getPath()
- Returns the path used by the service.
setPath
public void setPath(String path)
- Sets the path used for loading the HTML files.
getMLetSrvObjectName
public String getMLetSrvObjectName()
- Returns a String representing the ObjectName
of the mlet service invoked for loading.
If the mlet to use was specified using a direct reference to the service
through the
setMLetSrv method , this method will return null.
getMLetSrv
public MLetSrv getMLetSrv()
- Returns a reference on the mlet service invoked for loading.
setMLetSrv
public void setMLetSrv(MLetSrv mlet)
- Sets direct reference to the mlet service to use.
- See Also:
- setMLetSrvObjectName
setMLetSrvObjectName
public void setMLetSrvObjectName(String mlet)
- Sets a String representing the ObjectName
of the mlet service to use.
Such a mlet has precedence over an mlet service reigstered using the
setMLetSrv method.
- See Also:
- setMLetSrvObjectName
getClassVersion
public static String getClassVersion()
- Returns the version of this class.
getThreadGroup
public ThreadGroup getThreadGroup()
- Get the thread group used for creating the threads.
setThreadGroup
public void setThreadGroup(ThreadGroup threadGroup)
- Set the thread group to use when creating the threads for loading.
- Parameters:
- threadGroup - the thread group to use.
All Packages Class Hierarchy This Package Previous Next Index