com.microfocus.awm.control

## Class ElementlistManager

- java.lang.Object
- - com.microfocus.awm.control.ElementlistManager

-     public class ElementlistManager
      extends java.lang.Object

  Parses physical element lists (files with separated values in each line) into element list entries.
  Author:
    Micro Focus

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ElementlistManager()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `fillElementList(IGetDataResponse pResp, FileDescriptor pFD, IElementList pElementList, IExecutionContext pContext)` Finds the file output parameter from the given tool descriptor and converts the physical element list into element list entries.
    `static void` | `fillElementList(ISystemImage pImg, java.io.InputStream pIS, FileDescriptor pFD, IElementList pElementList, IExecutionContext pContext)` Deprecated. used `fillElementList(IGetDataResponse, FileDescriptor, IElementList, IExecutionContext)` instead because the local code page `IGetDataResponse.getLocalCodePage()` used to create the input stream is needed to read it.)
    `static void` | `fillElementList(ToolDescriptor pTd, IElementList pElementList, ActionDescriptor filActDescr, IExecutionContext pContext)` Finds the file output parameter from the given tool descriptor and converts the physical element list into element list entries.
    `static ElementType` | `getElementTypeFromProperties(java.util.Collection<IPropertyValue> pPropertyValues)` Gets the element type from a collection of property values by searching the match name.
    `static IElement` | `getLastInsertedElement()` Deprecated. does not work anymore. Use logical resource operation names ( `RActionTool.getAffectedResourceName()`).
    `static void` | `notifyRefresh()` Deprecated. does not refresh the tree view.
    `static void` | `refreshElementList(IElementList pEleList, boolean pPhysicalRefresh, IExecutionContext pContext, org.eclipse.core.runtime.IProgressMonitor pMon)` Refreshes an `IElementList`.
    `static void` | `refreshElementList(IElementList pEleList, boolean pPhysicalRefresh, org.eclipse.core.runtime.IProgressMonitor pMon)` Refreshes an `IElementList`.

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

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

- - ### Constructor Detail

    - #### ElementlistManager

          public ElementlistManager()

  - ### Method Detail

    - #### fillElementList

          public static void fillElementList(ToolDescriptor pTd,
                                             IElementList pElementList,
                                             ActionDescriptor filActDescr,
                                             IExecutionContext pContext)
                                      throws TaurusCoreException,
                                             TaurusToolException

      Finds the file output parameter from the given tool descriptor and converts the physical element list into element list entries. The converted entries will be added to the given element list.
      Parameters:
        `pTd` - the tool descriptor containing the file output parameter
        `pElementList` - the element list to fill
        `filActDescr` - the action descriptor
        `pContext` - the execution context
      Throws:
        `TaurusToolException` - see TaurusCoreException
        `TaurusCoreException` - if filling the element list fails for various reasons, including:
    - Reading the physical element list fails.
    - The modelled separator (file descriptor) does not match the actual separator (physical file).
    - At least one line in the physical file does not contain a proper ID definition.
    - At least one line in the physical file does not contain a match name.
    - At least one line contains an invalid match name.
    - The separator occurred within an actual value.
    - Adding additional properties to the element list fails.

  - #### fillElementList

        @Deprecated
        public static void fillElementList(ISystemImage pImg,
                                                        java.io.InputStream pIS,
                                                        FileDescriptor pFD,
                                                        IElementList pElementList,
                                                        IExecutionContext pContext)
                                                 throws TaurusCoreException,
                                                        TaurusToolException

    Deprecated. used `fillElementList(IGetDataResponse, FileDescriptor, IElementList, IExecutionContext)` instead because the local code page `IGetDataResponse.getLocalCodePage()` used to create the input stream is needed to read it.)
    Finds the file output parameter from the given tool descriptor and converts the physical element list into element list entries. The converted entries will be added to the given element list.
    Parameters:
      `pImg` - the system image
      `pIS` - contents of the physical element list
      `pFD` - the file descriptor of the physical element list
      `pElementList` - the element list to fill
      `pContext` - the execution context
    Throws:
      `TaurusToolException` - see TaurusCoreException
      `TaurusCoreException` - if filling the element list fails for various reasons, including:
  - Reading the physical element list fails.
  - The modelled separator (file descriptor) does not match the actual separator (physical file).
  - At least one line in the physical file does not contain a proper ID definition.
  - At least one line in the physical file does not contain a match name.
  - At least one line contains an invalid match name.
  - The separator occurred within an actual value.
  - Adding additional properties to the element list fails.

- #### fillElementList

      public static void fillElementList(IGetDataResponse pResp,
                                         FileDescriptor pFD,
                                         IElementList pElementList,
                                         IExecutionContext pContext)
                                  throws TaurusCoreException,
                                         TaurusToolException

  Finds the file output parameter from the given tool descriptor and converts the physical element list into element list entries. The converted entries will be added to the given element list.
  Parameters:
    `pResp` - the data response (contents of the physical element list and the local code page used to create it)
    `pFD` - the file descriptor of the physical element list
    `pElementList` - the element list to fill
    `pContext` - the execution context
  Throws:
    `TaurusToolException` - see TaurusCoreException
    `TaurusCoreException` - if filling the element list fails for various reasons, including:
- Reading the physical element list fails.
- The modelled separator (file descriptor) does not match the actual separator (physical file).
- At least one line in the physical file does not contain a proper ID definition.
- At least one line in the physical file does not contain a match name.
- At least one line contains an invalid match name.
- The separator occurred within an actual value.
- Adding additional properties to the element list fails.

- #### notifyRefresh

      @Deprecated
      public static void notifyRefresh()

  Deprecated. does not refresh the tree view.
  Notifies that an element list has changed.

- #### getElementTypeFromProperties

      public static ElementType getElementTypeFromProperties(java.util.Collection<IPropertyValue> pPropertyValues)

  Gets the element type from a collection of property values by searching the match name.
  Parameters:
    `pPropertyValues` - a collection of property values (usually the contents of a physical element list line)
  Returns:
    the element type or `null` if no element type could be found
  See Also:
    `Property.getSpecialProperty()`, `ESpecialProperties.ELEMENT_TYPE`

- #### getLastInsertedElement

      @Deprecated
      public static IElement getLastInsertedElement()

  Deprecated. does not work anymore. Use logical resource operation names ( `RActionTool.getAffectedResourceName()`).
  Gets the last element which was added to an element list.
  Returns:
    the last element which was added to an element list.

- #### refreshElementList

      public static void refreshElementList(IElementList pEleList,
                                            boolean pPhysicalRefresh,
                                            org.eclipse.core.runtime.IProgressMonitor pMon)

  Refreshes an `IElementList`. Depending on the physical refresh parameter, the list will be re-created or just updated.
  Parameters:
    `pEleList` - the element list to be refreshed
    `pPhysicalRefresh` - if `true` the element list will be recreated by calling its refresh-action. If `false` the list will only be re-ordered.
    `pMon` - a progress monitor

- #### refreshElementList

      public static void refreshElementList(IElementList pEleList,
                                            boolean pPhysicalRefresh,
                                            IExecutionContext pContext,
                                            org.eclipse.core.runtime.IProgressMonitor pMon)

  Refreshes an `IElementList`. Depending on the physical refresh parameter, the list will be re-created or just updated.
  Parameters:
    `pEleList` - the element list to be refreshed
    `pPhysicalRefresh` - if `true` the element list will be recreated by calling its refresh-action. If `false` the list will only be re-ordered.
    `pContext` - the execution context
    `pMon` - progress monitor

Copyright © 2015 Micro Focus GmbH. All rights reserved.