org.licas.parsers.types

## Class ArrayListParser

- java.lang.Object
- - org.licas.parsers.types.ListParser
  - - org.licas.parsers.types.ArrayListParser

- All Implemented Interfaces:
    org.ai_heuristic.def.ParserDef

      public class ArrayListParser
      extends ListParser

  This class parses standard `ArrayList` structures. This includes parsing nested lists and any objects that they might store.
  Author:
    Kieran Greer

- - ### Field Summary

    - ### Fields inherited from class org.licas.parsers.types.ListParser

      `ARRAYCLASS`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ArrayListParser()` Creates a new instance of ArrayListParser

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `arrayListToElement(java.util.ArrayList data, org.licas_xml.abs.Element rootElem)` Parse an ArrayList to generate an xml representation.
    `static void` | `elementToArrayList(java.util.ArrayList data, org.licas_xml.abs.Element paramXml)` Parse the information to return an ArrayList of the values.
    `java.lang.Object` | `parse(org.licas_xml.abs.Element toParse)` Parse the toParse information to return a list of the values.
    `org.licas_xml.abs.Element` | `serialize(java.lang.Object toSerialize)` Parse an ArryList to generate an xml representation.

    - ### Methods inherited from class org.licas.parsers.types.ListParser

      `createAddListObject, createAddMapObject, isList`

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

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

- - ### Constructor Detail

    - #### ArrayListParser

          public ArrayListParser()

      Creates a new instance of ArrayListParser

  - ### Method Detail

    - #### parse

          public java.lang.Object parse(org.licas_xml.abs.Element toParse)
                                 throws java.lang.Exception

      Parse the toParse information to return a list of the values.
      Parameters:
        `toParse` - a description of the data.
      Returns:
        a list with real values contained.
      Throws:
        `java.lang.Exception` - any error.

    - #### serialize

          public org.licas_xml.abs.Element serialize(java.lang.Object toSerialize)
                                              throws java.lang.Exception

      Parse an ArryList to generate an xml representation.
      Parameters:
        `toSerialize` - the data list.
      Returns:
        an element if a list or the original object if not a list.
      Throws:
        `java.lang.Exception` - any error.

    - #### elementToArrayList

          public static void elementToArrayList(java.util.ArrayList data,
                                                org.licas_xml.abs.Element paramXml)
                                         throws java.lang.Exception

      Parse the information to return an ArrayList of the values.
      Parameters:
        `data` - the list to store the data in.
        `paramXml` - a description of the `Const`.`PARAMETER` data.
      Throws:
        `java.lang.Exception` - any error.

    - #### arrayListToElement

          public static void arrayListToElement(java.util.ArrayList data,
                                                org.licas_xml.abs.Element rootElem)
                                         throws java.lang.Exception

      Parse an ArrayList to generate an xml representation.
      Parameters:
        `data` - the data list.
        `rootElem` - the root element.
      Throws:
        `java.lang.Exception` - any error.