ALMA Computing Group

alma::demo::dyncomp::Client Class Reference

Client demostrates how to activate and release dynamic components. More...

List of all members.

Public Member Functions

 Client (Logger logger, String managerLoc, String clientName) throws Exception
 The constructor.
boolean hasFreeSlot ()
 Check if a free slot exists into the array A free slot has a null value and, as the array is not ordered, may be in every position of the array.
String getDynamicComponent (ComponentSpec cs, boolean markAsDefault) throws AcsJContainerServicesEx
 Start a dynamic component.
boolean releaseComponent (String url)
 Release a component The component is specified with its cURL.
void cleanExit ()
 Release all the components before exiting.

Package Attributes

ACSComponent m_components []
String m_cURLs []

Private Attributes

final int MAXCOMPONENTS = 32


Detailed Description

Client demostrates how to activate and release dynamic components.

Author:
Alessandro Caproni, 2003, Nov 7

Definition at line 17 of file Client.java.


Constructor & Destructor Documentation

alma::demo::dyncomp::Client::Client Logger  logger,
String  managerLoc,
String  clientName
throws Exception [inline]
 

The constructor.

Definition at line 29 of file Client.java.

References m_components, m_cURLs, and MAXCOMPONENTS.


Member Function Documentation

void alma::demo::dyncomp::Client::cleanExit  )  [inline]
 

Release all the components before exiting.

Definition at line 98 of file Client.java.

References m_components, m_cURLs, and MAXCOMPONENTS.

Referenced by alma::demo::dyncomp::JDynAct::cleanExit().

String alma::demo::dyncomp::Client::getDynamicComponent ComponentSpec  cs,
boolean  markAsDefault
throws AcsJContainerServicesEx [inline]
 

Start a dynamic component.

Parameters:
cs The component specification record
markAsDefault marck the specified dynamic component ad default
Returns:
The cUrl of the activated component (nul if the component is not activated)
Definition at line 57 of file Client.java.

References m_components, m_cURLs, and MAXCOMPONENTS.

Referenced by alma::demo::dyncomp::JDynAct::startDynamicComponent().

boolean alma::demo::dyncomp::Client::hasFreeSlot  )  [inline]
 

Check if a free slot exists into the array A free slot has a null value and, as the array is not ordered, may be in every position of the array.

Definition at line 45 of file Client.java.

References m_components, and MAXCOMPONENTS.

Referenced by alma::demo::dyncomp::JDynAct::startDynamicComponent().

boolean alma::demo::dyncomp::Client::releaseComponent String  url  )  [inline]
 

Release a component The component is specified with its cURL.

Parameters:
url The name of the component
Returns:
false in case of error releasing the component or if the component with the specified url is not found
Definition at line 81 of file Client.java.

References m_components, m_cURLs, and MAXCOMPONENTS.

Referenced by alma::demo::dyncomp::JDynAct::releaseComponent().


Member Data Documentation

ACSComponent alma::demo::dyncomp::Client::m_components[] [package]
 

Definition at line 24 of file Client.java.

Referenced by cleanExit(), Client(), getDynamicComponent(), hasFreeSlot(), and releaseComponent().

String alma::demo::dyncomp::Client::m_cURLs[] [package]
 

Definition at line 25 of file Client.java.

Referenced by cleanExit(), Client(), getDynamicComponent(), and releaseComponent().

final int alma::demo::dyncomp::Client::MAXCOMPONENTS = 32 [private]
 

Definition at line 19 of file Client.java.

Referenced by cleanExit(), Client(), getDynamicComponent(), hasFreeSlot(), and releaseComponent().


The documentation for this class was generated from the following file: