com.microfocus.awm.model.internal

## Class TaurusSystemDirectory

- java.lang.Object
- - java.util.Observable
  - - com.microfocus.awm.model.internal.TaurusSystemDirectory

- All Implemented Interfaces:
    ITaurusSystemDirectory

      public class TaurusSystemDirectory
      extends java.util.Observable
      implements ITaurusSystemDirectory

  Main implementation of `ITaurusSystemDirectory`.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static java.lang.String` | `XML_ATTRIBUTE_APPLICATION_PROPERTY_LABEL` XML attribute: Application property label.
    `static java.lang.String` | `XML_ATTRIBUTE_APPLICATION_PROPERTY_TYPE` XML attribute: Application property type.
    `static java.lang.String` | `XML_ATTRIBUTE_APPLICATION_PROPERTY_UPDATEDVALUE` XML attribute: Application property updated value.
    `static java.lang.String` | `XML_ATTRIBUTE_CUSTOMATTRIBUTE_VALUE` XML attribute: Custom attribute value.
    `static java.lang.String` | `XML_ATTRIBUTE_GENERAL_ID` XML attribute: ID.
    `static java.lang.String` | `XML_ATTRIBUTE_GENERAL_NAME` XML attribute: Name.
    `static java.lang.String` | `XML_ATTRIBUTE_SYSTEM_PROVIDERID` XML attribute: AWM system provider ID.
    `static java.lang.String` | `XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMHOSTNAME` XML attribute: AWM System remote system host name.
    `static java.lang.String` | `XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMNAME` XML attribute: AWM system remote system name.
    `static java.lang.String` | `XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMUSERID` XML attribute: AWM System remote system user ID.
    `static java.lang.String` | `XML_ELEMENT_APPLICATION` XML element name: AWM application.
    `static java.lang.String` | `XML_ELEMENT_CUSTOMATTRIBUTE` XML element name: Custom attribute.
    `static java.lang.String` | `XML_ELEMENT_SYSTEM` XML element name: AWM system.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addSystem(ITaurusSystem pSystem, boolean pNotify)` Add the given TAURUS system to the TAURUS system directory.
    `java.util.Map<java.lang.String,java.lang.Boolean>` | `getExpandMap()` Gets the map with all resources of this system which are expanded in the tree view.
    `static TaurusSystemDirectory` | `getInstance()` Gets the singleton instance.
    `ITaurusSystem` | `getSelectedSystem()` Gets the system of the application which is currently loaded.
    `ITaurusSystem` | `getTaurusSystem(java.lang.String pResourceID)` Returns the TAURUS system with the given ID.
    `ITaurusSystem` | `getTaurusSystem(java.lang.String pSystemName, java.lang.String pUniqueSystemName)` Returns an `ITaurusSystem` for the given parameters or `null` if that system does not exist.
    `java.util.List<ITaurusSystem>` | `getTaurusSystemList()` Gets a list of all available AWM systems.
    `void` | `loadSystems()` Load the system directory from the st_systems.xml-file in the workspace.
    `void` | `loadSystems(boolean pSynchronous)` Same as `loadSystems()` but with the option to wait for the systems being loaded.
    `void` | `notifyChanged(TaurusNotification pTn)` Sets the changed flag of the system directory (Observerable) and notifies observers about the change.
    `void` | `removeSystem(ITaurusSystem pSystem)` Remove the given TAURUS system from the system directory.
    `void` | `saveSystems()` Save the system directory to the st_systems.xml-file in the workspace.
    `void` | `setExpandMap(java.util.Map<java.lang.String,java.lang.Boolean> pExpandMap)` Sets the map of all resources of this system which are expanded in the tree view.
    `void` | `setSelectedSystem(ITaurusSystem pSelectedSystem)` Sets the currently active system.
    `boolean` | `systemsLoaded()` Gets whether loading cached systems was completed.

    - ### Methods inherited from class java.util.Observable

      `addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface com.microfocus.awm.model.ITaurusSystemDirectory

      `addObserver`

- - ### Field Detail

    - #### XML_ATTRIBUTE_CUSTOMATTRIBUTE_VALUE

          public static final java.lang.String XML_ATTRIBUTE_CUSTOMATTRIBUTE_VALUE

      XML attribute: Custom attribute value.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_APPLICATION_PROPERTY_TYPE

          public static final java.lang.String XML_ATTRIBUTE_APPLICATION_PROPERTY_TYPE

      XML attribute: Application property type.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_APPLICATION_PROPERTY_UPDATEDVALUE

          public static final java.lang.String XML_ATTRIBUTE_APPLICATION_PROPERTY_UPDATEDVALUE

      XML attribute: Application property updated value.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_APPLICATION_PROPERTY_LABEL

          public static final java.lang.String XML_ATTRIBUTE_APPLICATION_PROPERTY_LABEL

      XML attribute: Application property label.
      See Also:
        Constant Field Values

    - #### XML_ELEMENT_CUSTOMATTRIBUTE

          public static final java.lang.String XML_ELEMENT_CUSTOMATTRIBUTE

      XML element name: Custom attribute.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMUSERID

          public static final java.lang.String XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMUSERID

      XML attribute: AWM System remote system user ID.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMHOSTNAME

          public static final java.lang.String XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMHOSTNAME

      XML attribute: AWM System remote system host name.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMNAME

          public static final java.lang.String XML_ATTRIBUTE_SYSTEM_REMOTESYSTEMNAME

      XML attribute: AWM system remote system name.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_GENERAL_NAME

          public static final java.lang.String XML_ATTRIBUTE_GENERAL_NAME

      XML attribute: Name.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_GENERAL_ID

          public static final java.lang.String XML_ATTRIBUTE_GENERAL_ID

      XML attribute: ID.
      See Also:
        Constant Field Values

    - #### XML_ELEMENT_APPLICATION

          public static final java.lang.String XML_ELEMENT_APPLICATION

      XML element name: AWM application.
      See Also:
        Constant Field Values

    - #### XML_ELEMENT_SYSTEM

          public static final java.lang.String XML_ELEMENT_SYSTEM

      XML element name: AWM system.
      See Also:
        Constant Field Values

    - #### XML_ATTRIBUTE_SYSTEM_PROVIDERID

          public static final java.lang.String XML_ATTRIBUTE_SYSTEM_PROVIDERID

      XML attribute: AWM system provider ID.
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### getInstance

          public static TaurusSystemDirectory getInstance()

      Gets the singleton instance.
      Returns:
        the instance

    - #### addSystem

          public void addSystem(ITaurusSystem pSystem,
                                boolean pNotify)
                         throws TaurusCoreException

      Description copied from interface: `ITaurusSystemDirectory`
      Add the given TAURUS system to the TAURUS system directory.
      Specified by:
        `addSystem` in interface `ITaurusSystemDirectory`
      Parameters:
        `pSystem` - TAURUS system to be added
        `pNotify` - if `true`, notify the system directory's observers
      Throws:
        `TaurusCoreException` - if a TAURUS System with the same name already exists.

    - #### removeSystem

          public void removeSystem(ITaurusSystem pSystem)

      Description copied from interface: `ITaurusSystemDirectory`
      Remove the given TAURUS system from the system directory.
      Specified by:
        `removeSystem` in interface `ITaurusSystemDirectory`
      Parameters:
        `pSystem` - TAURUS system to be removed

    - #### loadSystems

          public void loadSystems()
                           throws TaurusCoreException

      Description copied from interface: `ITaurusSystemDirectory`
      Load the system directory from the st_systems.xml-file in the workspace.
      Specified by:
        `loadSystems` in interface `ITaurusSystemDirectory`
      Throws:
        `TaurusCoreException` - if loading the system cache fails

    - #### loadSystems

          public void loadSystems(boolean pSynchronous)
                           throws TaurusCoreException

      Same as `loadSystems()` but with the option to wait for the systems being loaded.
      Parameters:
        `pSynchronous` - if set to `true` the method will wait until the systems are loaded. If set to `false` it behaves exactly like `loadSystems()`
      Throws:
        `TaurusCoreException` - if loading the system cache gets interrupted

    - #### saveSystems

          public void saveSystems()
                           throws TaurusCoreException

      Description copied from interface: `ITaurusSystemDirectory`
      Save the system directory to the st_systems.xml-file in the workspace.
      Specified by:
        `saveSystems` in interface `ITaurusSystemDirectory`
      Throws:
        `TaurusCoreException` - if saving the system cache fails

    - #### getSelectedSystem

          public ITaurusSystem getSelectedSystem()

      Description copied from interface: `ITaurusSystemDirectory`
      Gets the system of the application which is currently loaded.
      Specified by:
        `getSelectedSystem` in interface `ITaurusSystemDirectory`
      Returns:
        the currently active system

    - #### setSelectedSystem

          public void setSelectedSystem(ITaurusSystem pSelectedSystem)

      Description copied from interface: `ITaurusSystemDirectory`
      Sets the currently active system.
      Specified by:
        `setSelectedSystem` in interface `ITaurusSystemDirectory`
      Parameters:
        `pSelectedSystem` - the new active system

    - #### getTaurusSystemList

          public java.util.List<ITaurusSystem> getTaurusSystemList()

      Description copied from interface: `ITaurusSystemDirectory`
      Gets a list of all available AWM systems.
      Specified by:
        `getTaurusSystemList` in interface `ITaurusSystemDirectory`
      Returns:
        a list of all systems

    - #### setExpandMap

          public void setExpandMap(java.util.Map<java.lang.String,java.lang.Boolean> pExpandMap)

      Description copied from interface: `ITaurusSystemDirectory`
      Sets the map of all resources of this system which are expanded in the tree view.
      Specified by:
        `setExpandMap` in interface `ITaurusSystemDirectory`
      Parameters:
        `pExpandMap` - the map containing all expanded resources

    - #### getExpandMap

          public java.util.Map<java.lang.String,java.lang.Boolean> getExpandMap()

      Description copied from interface: `ITaurusSystemDirectory`
      Gets the map with all resources of this system which are expanded in the tree view.
      Specified by:
        `getExpandMap` in interface `ITaurusSystemDirectory`
      Returns:
        a map with all expanded resources

    - #### getTaurusSystem

          public ITaurusSystem getTaurusSystem(java.lang.String pSystemName,
                                               java.lang.String pUniqueSystemName)

      Description copied from interface: `ITaurusSystemDirectory`
      Returns an `ITaurusSystem` for the given parameters or `null` if that system does not exist.
      Specified by:
        `getTaurusSystem` in interface `ITaurusSystemDirectory`
      Parameters:
        `pSystemName` - the name of a TAURUS System
        `pUniqueSystemName` - the unique name of the remote system
      Returns:
        the TAURUS System or `null`

    - #### notifyChanged

          public void notifyChanged(TaurusNotification pTn)

      Sets the changed flag of the system directory (Observerable) and notifies observers about the change.
      Specified by:
        `notifyChanged` in interface `ITaurusSystemDirectory`
      Parameters:
        `pTn` - the notification for the observers

    - #### getTaurusSystem

          public ITaurusSystem getTaurusSystem(java.lang.String pResourceID)

      Description copied from interface: `ITaurusSystemDirectory`
      Returns the TAURUS system with the given ID.
      Specified by:
        `getTaurusSystem` in interface `ITaurusSystemDirectory`
      Parameters:
        `pResourceID` - the ID of the TAURUS system (case sensitive)
      Returns:
        an `ITaurusSystem` or `null` if the system was not found or loaded from cache.
      See Also:
        `ITaurusSystemDirectory.loadSystems()`

    - #### systemsLoaded

          public boolean systemsLoaded()

      Description copied from interface: `ITaurusSystemDirectory`
      Gets whether loading cached systems was completed. This can be useful at startup, since loading cached systems runs in a job which waits for initializations of depending frameworks.
      Specified by:
        `systemsLoaded` in interface `ITaurusSystemDirectory`
      Returns:
        `true` if cached AWM systems have already been loaded

Copyright © 2015 Micro Focus GmbH. All rights reserved.