zeab / aenea   2.1.0

Apache License 2.0 GitHub

Automatic case class xml serilization and deseriliztation

Scala versions: 2.12

Aenea

An automatic xml case class serializer and deserializer using reflection which so far has not failed me running this multithreaded with Akka.

Maven Central Build Status Codacy Badge

Xml Serialize:

import zeab.aenea.XmlSerializer._
case class MyDoubleClass(myDouble:Double)
val obj: MyDoubleClass = MyDoubleClass(1.1)
val serializedXml: Either[Throwable, String] = obj.asXml

Xml Deserialize:

case class MyBooleanClass(myBoolean:Boolean)
val expectedType: String = "MyBooleanClass"
val xml: String = "<myBooleanClass><myBoolean>false</myBoolean></myBooleanClass>"
val obj = xml.fromXml[MyBooleanClass]