org.licas.parsers.types

## Class ObjectParser

- java.lang.Object
- - org.licas.parsers.types.ObjectParser

-     public class ObjectParser
      extends java.lang.Object

  This class serialises and parses an Object that extends `java.io.Serializable`. The serialization process involves converting the object into `Base64` format, using the `Base64` parser.
  Author:
    Kieran Greer

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static java.lang.String` | `SERIALIZED` Defines serialized object

  - ### Constructor Summary

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

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static java.lang.Object` | `parse(java.lang.String objStr)` Parse the String-based description back into the object.
    `static java.lang.String` | `serialize(java.lang.Object nextObj)` Convert the object into a serialized String-based description.

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

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

- - ### Field Detail

    - #### SERIALIZED

          public static final java.lang.String SERIALIZED

      Defines serialized object
      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### ObjectParser

          public ObjectParser()

      Creates a new instance of ObjectParser

  - ### Method Detail

    - #### parse

          public static java.lang.Object parse(java.lang.String objStr)
                                        throws java.lang.Exception

      Parse the String-based description back into the object.
      Parameters:
        `objStr` - a serialized description of the object.
      Returns:
        the original object, or the `objStr` parameter if this is not a recognised Base64 encoded object description.
      Throws:
        `java.lang.Exception` - any error.

    - #### serialize

          public static java.lang.String serialize(java.lang.Object nextObj)

      Convert the object into a serialized String-based description.
      Parameters:
        `nextObj` - the object to convert.
      Returns:
        the object converted into a Base64 encoded String.