org.licas.parsers.admin

## Class ServiceMetaParser

- java.lang.Object
- - org.licas.parsers.admin.ServiceMetaParser

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

      public class ServiceMetaParser
      extends java.lang.Object
      implements org.ai_heuristic.def.ParserDef

  This provides methods to parse a service and return only its `ServiceMeta` description.
  Author:
    Kieran Greer

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ServiceMetaParser()` Create a new instance of ServiceMetaParser.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.Object` | `parse(org.licas_xml.abs.Element toParse)` Parse the XML description back into the ServiceMeta object.
    `org.licas_xml.abs.Element` | `serialize(java.lang.Object toSerialize)` Serialise the object of type ServiceMeta into XML.
    `org.licas_xml.abs.Element` | `serialize(java.lang.Object toSerialize, boolean permLinks)` Serialise the object of type ServiceMeta into XML.

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

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

- - ### Constructor Detail

    - #### ServiceMetaParser

          public ServiceMetaParser()

      Create a new instance of ServiceMetaParser.

  - ### Method Detail

    - #### serialize

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

      Serialise the object of type ServiceMeta into XML. Automatically serializes the permanent links.
      Specified by:
        `serialize` in interface `org.ai_heuristic.def.ParserDef`
      Parameters:
        `toSerialize` - the service meta object of type ServiceMeta.
      Returns:
        an XML description of the object.
      Throws:
        `java.lang.Exception` - any error.

    - #### serialize

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

      Serialise the object of type ServiceMeta into XML.
      Parameters:
        `toSerialize` - the service meta object of type ServiceMeta.
        `permLinks` - if true serialize the permanent inks as well (link/association). The dynamic links need to be serialized separately.
      Returns:
        an XML description of the object.
      Throws:
        `java.lang.Exception` - any error.

    - #### parse

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

      Parse the XML description back into the ServiceMeta object.
      Specified by:
        `parse` in interface `org.ai_heuristic.def.ParserDef`
      Parameters:
        `toParse` - the XML description to parse.
      Returns:
        the ServiceMeta object with nested meta descriptions.
      Throws:
        `java.lang.Exception` - any error.