com.microfocus.awm.model.internal

## Class TaurusDirectory

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

- Direct Known Subclasses:
    ElementDirectory, ElementListDirectory, FilterList

      public abstract class TaurusDirectory
      extends java.util.Observable

  General super class for "Taurus...Directory" classes that are able to save and load cache components.

  Copyright (C) Micro Focus

  Author:
    Ralf Pakosch

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static java.lang.String` | `ATTRIBUTE_CHILD_RESOURCE_ID` XML attribute name for an ID
    `static java.lang.String` | `ELEMENT_CHILD_RESOURCE` XML element name for a child resource

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TaurusDirectory()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `addChild(IResource pResource, org.xml.sax.Attributes pAttr)` Adds a child resource to the given `IResource`.
    `static java.lang.String` | `getResourceID(org.xml.sax.Attributes pAttr)` Gets the resource ID out of the given XML attributes.
    `void` | `notifyObservers(TaurusNotification pNotification)` Sets the changed flag of this observable and notifies observers.
    `void` | `saveChildren(org.w3c.dom.Document pDoc, org.w3c.dom.Element pXMLElement, IResource pResource)` Creates an XML child element for every child resource of the given resource.

    - ### 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`

- - ### Field Detail

    - #### ELEMENT_CHILD_RESOURCE

          public static final java.lang.String ELEMENT_CHILD_RESOURCE

      XML element name for a child resource
      See Also:
        Constant Field Values

    - #### ATTRIBUTE_CHILD_RESOURCE_ID

          public static final java.lang.String ATTRIBUTE_CHILD_RESOURCE_ID

      XML attribute name for an ID
      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### TaurusDirectory

          public TaurusDirectory()

  - ### Method Detail

    - #### saveChildren

          public void saveChildren(org.w3c.dom.Document pDoc,
                                   org.w3c.dom.Element pXMLElement,
                                   IResource pResource)

      Creates an XML child element for every child resource of the given resource.
      Parameters:
        `pDoc` - the XML document
        `pXMLElement` - the XML element
        `pResource` - the AWM resource
      See Also:
        `IResource.getChildrenResources()`

    - #### getResourceID

          public static java.lang.String getResourceID(org.xml.sax.Attributes pAttr)

      Gets the resource ID out of the given XML attributes.
      Parameters:
        `pAttr` - XML attributes
      Returns:
        a resource ID or `null` if the attributes do not contain a resource ID

    - #### addChild

          public static void addChild(IResource pResource,
                                      org.xml.sax.Attributes pAttr)

      Adds a child resource to the given `IResource`.
      Parameters:
        `pResource` - the resource
        `pAttr` - must contain an "ID" XML attribute from a "childResource" element.

    - #### notifyObservers

          public void notifyObservers(TaurusNotification pNotification)

      Sets the changed flag of this observable and notifies observers.
      Parameters:
        `pNotification` - the notification. Can be `null` (not recommended).
      See Also:
        `Observable.notifyObservers(Object)`

Copyright © 2015 Micro Focus GmbH. All rights reserved.