com.microfocus.awm.core.internal

## Class TableStructure

- java.lang.Object
- - com.microfocus.awm.core.internal.TableStructure

- All Implemented Interfaces:
    IStructureType

      public class TableStructure
      extends java.lang.Object
      implements IStructureType

  `IStructureType` implementation for table structures. A table contains of rows of values separated by a delimiter.

  Tables rows can have different lengths, as long as all values have consistent indexes. This means that trailing values are optional (see `Ele2` in example below).

  Example:
  Assuming the following IStructure (delimiter=`","`)
  `PROP_ElementName
  PROP_Type
  PROP_Username`

  the following table:
  `Ele1,jpg,Stephen`
  `Ele2,txt`
  `Ele3,,John`

  would result in `IPropertyData` with the following `IPropertyElement`s:
  `PropertyElement [PROP_ElementName="Ele1", PROP_Type="jpg", PROP_Username="Stephen"]`
  `PropertyElement [PROP_ElementName="Ele2", PROP_Type="txt"]`
  `PropertyElement [PROP_ElementName="Ele3", PROP_Type="", PROP_Username="John"]`

  When calling `readStructure(FileDescriptor, String)` or vice versa when calling `createStructure(FileDescriptor, IPropertyData)`.
  On creation of the structure the third IPropertyElement would not even need a PROP_Type value at all, since the empty String would be created automatically.

  Author:
    RalfP

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TableStructure()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `createStructure(FileDescriptor pFileDescriptor, IPropertyData pPropertyData)`
    `java.lang.String` | `getID()`
    `java.lang.String` | `getName()`
    `IPropertyData` | `readStructure(FileDescriptor pDescription, java.lang.String pStructuredContents)` ...

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

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

- - ### Constructor Detail

    - #### TableStructure

          public TableStructure()

  - ### Method Detail

    - #### getName

          public java.lang.String getName()

      Specified by:
        `getName` in interface `IStructureType`

    - #### getID

          public java.lang.String getID()

      Specified by:
        `getID` in interface `IStructureType`

    - #### readStructure

          public IPropertyData readStructure(FileDescriptor pDescription,
                                             java.lang.String pStructuredContents)

      Description copied from interface: `IStructureType`
      ...

      If the given structure document can be considered empty (empty string or e.g. just a header), an `IPropertyData` instance with no `IPropertyElement`s must be returned.

      Specified by:
        `readStructure` in interface `IStructureType`
      Returns:
        created property data. Can contain an empty list of property elements but must not be `null`

    - #### createStructure

          public java.lang.String createStructure(FileDescriptor pFileDescriptor,
                                                  IPropertyData pPropertyData)
                                           throws TaurusCoreException

      Specified by:
        `createStructure` in interface `IStructureType`
      Returns:
      Throws:
        `TaurusCoreException`

Copyright © 2015 Micro Focus GmbH. All rights reserved.