Package

com.alpine.common.serialization

json

Permalink

package json

Visibility
  1. Public
  2. All

Type Members

  1. trait ClassLoaderUtil extends AnyRef

    Permalink
  2. class ColumnDefTypeAdapter extends JsonSerializer[ColumnDef] with JsonDeserializer[ColumnDef]

    Permalink
  3. class GsonMapAdapter extends JsonSerializer[Map[_, _]] with JsonDeserializer[Map[_, _]]

    Permalink

    Gson adapter used to serialize and serialize scala.collection.Map to and from JSON.

  4. case class GsonOptionAdapter() extends JsonSerializer[Option[_]] with JsonDeserializer[Option[_]] with Product with Serializable

    Permalink

    Gson adapter to be used to serialize and serialize scala.Option to and from JSON with Gson.

  5. case class GsonSeqAdapter() extends JsonSerializer[Seq[_]] with JsonDeserializer[Seq[_]] with Product with Serializable

    Permalink

    Gson adapter to be used to serialize and serialize scala.collection.Seq to and from JSON with Gson.

  6. case class GsonSetAdapter() extends JsonSerializer[Set[_]] with JsonDeserializer[Set[_]] with Product with Serializable

    Permalink
  7. class GsonTypeAdapter extends JsonSerializer[TypeWrapper[_]] with JsonDeserializer[TypeWrapper[_]]

    Permalink

    Gson adapter to be used to serialize and serialize TypeWrapper to and from JSON with Gson.

    Gson adapter to be used to serialize and serialize TypeWrapper to and from JSON with Gson.

    To be used when the developer wishes to to include a interface type in the model object, or one of its fields.

    e.g. to store a List[Bird], or just val b: Bird, where trait Bird class Robin() extends Bird class Eagle() extends Bird the Bird type should be wrapped in TypeWrapper: case class Aviary(specialBird: TypeWrapper[Bird], commonBirds: List[TypeWrapper[Bird]])

  8. class InterfaceAdapter[T] extends JsonSerializer[T] with JsonDeserializer[T]

    Permalink

    For serializing/deserializing arbitrary interface types.

    For serializing/deserializing arbitrary interface types. From stackoverflow with some modifications to handle generic interfaces.

  9. class SuperClassExclusionStrategy extends ExclusionStrategy

    Permalink

    Taken from Stackoverflow (and translated to scala).

    Taken from Stackoverflow (and translated to scala). http://stackoverflow.com/questions/16476513/class-a-declares-multiple-json-fields

  10. case class TypeWrapper[T](value: T) extends Product with Serializable

    Permalink

    To be used as a wrapper for interfaces.

    To be used as a wrapper for interfaces. It includes the actual class name in the serialization in order to instantiate the new object on deserialization.

    T

    Type of value.

    value

    Actual value to serialize.

Value Members

  1. object InterfaceAdapter

    Permalink
  2. object JsonUtil

    Permalink

    Utility for Json used to serialize / deserialize IOBase and MLModel types.

Ungrouped