ARoad0.AcsAddon.Accbee.Ubuntu.gWork
Class AcsFactoryUbuntu

java.lang.Object
  extended by ARoad0.AcsAddon.Accbee.Ubuntu.gWork.AcsFactoryUbuntu
All Implemented Interfaces:
AcsFactoryForAcsAddon, Singleton

public class AcsFactoryUbuntu
extends java.lang.Object
implements AcsFactoryForAcsAddon

This class is an utility class for the creation of the Linux Ubuntu ACS for simulating a Linux Ubuntu 8.04 Desktop. It uses the packages ARoad0.AcsAddon.Accbee.Ubuntu.xxx to create the ACS in the base. It appears the need to create 9 new gBase classes, and also NodeRightsUbuntuImpl and LinkRightsUbuntuImpl in gWork.

To be comply with the AcsAddon architectural pattern, this class offers the method create() called by ActionNewACSyst.createACS(), and the method configure() called by ActionNewACSyst.fillWithAcsObjects().


Field Summary
private static AcsFactoryUbuntu instance__
           
static java.lang.String PUBLIC_ACS_ADDON_NAME
          the descriptor of the AcsAddon to set in the menu for creating a new ACS.
 
Constructor Summary
AcsFactoryUbuntu()
          with this public constructor for the subclasses.
 
Method Summary
 ACSImpl configure(ACSImpl _result)
          Creates the components in a Linux Ubuntu ACS.
 ACSImpl create(ImmutableName _iSname, ImmutableName _name, java.lang.String _type, ImmutableName _parent)
          Creates a specific Linux Ubuntu ACS.
static AcsFactoryForAcsAddon getInstance()
          Only method to obtain the unique instance.
 java.lang.String getPublicAcsAddonName()
          Gets the descriptor of the AcsAddon, to set in the menu for creating a new ACS.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

instance__

private static AcsFactoryUbuntu instance__

PUBLIC_ACS_ADDON_NAME

public static final java.lang.String PUBLIC_ACS_ADDON_NAME
the descriptor of the AcsAddon to set in the menu for creating a new ACS. It has to contain a '(' character. ActionNewACSyst uses it to define the ACS type, as the beginning of the text up to the first '(' character.

See Also:
Constant Field Values
Constructor Detail

AcsFactoryUbuntu

public AcsFactoryUbuntu()
with this public constructor for the subclasses.

Method Detail

getInstance

public static AcsFactoryForAcsAddon getInstance()
Only method to obtain the unique instance. Called by reflection from ActionNewACSyst.createACS().

Returns:
an AcsFactoryUbuntu instance

getPublicAcsAddonName

public java.lang.String getPublicAcsAddonName()
Gets the descriptor of the AcsAddon, to set in the menu for creating a new ACS. This method has to return a static variable, because it is called after a call to the empty constructor. Called by ActionNewACSyst.actionPerformed().

Specified by:
getPublicAcsAddonName in interface AcsFactoryForAcsAddon

create

public ACSImpl create(ImmutableName _iSname,
                      ImmutableName _name,
                      java.lang.String _type,
                      ImmutableName _parent)
               throws BaseError
Creates a specific Linux Ubuntu ACS. configure() is called after this method by ActionNewACSyst.fillWithAcsObjects(). This method makes most of the work, but the ACS vocabulary is set by ACSFactoryUbuntuImpl directly. Called by ActionNewACSyst.createACS().

Specified by:
create in interface AcsFactoryForAcsAddon
Parameters:
_iSname - the IS of the new ACS. May be null.
_name - of the ACS to create or open. No test of null value nor empty.
_type - must be the beginning of PUBLIC_ACS_ADDON_NAME
_parent - is the parent node of the new ACS in the IS. Never null.
Returns:
the new ACS
Throws:
BaseError - if the ACS is known, the ACS is open, the core ACS is null when it is mandatory, or ClassNotFoundException, IOException with invalidClassException if ACSImplUbuntu HAS CHANGED, or if the type or the specified structure are not correct.

configure

public ACSImpl configure(ACSImpl _result)
Creates the components in a Linux Ubuntu ACS. Creates a resources tree with directories, leaves and executables. Called by ActionNewACSyst.fillWithAcsObjects().

Specified by:
configure in interface AcsFactoryForAcsAddon
Parameters:
_result - to construct
Returns:
ACS with the initial and standard trees of resources, eligible parties.