Trait

ml.combust.bundle.custom

CustomType

Related Doc: package custom

Permalink

trait CustomType[T] extends AnyRef

Type class for a custom object.

Custom objects can be serialized in an ml.combust.bundle.dsl.AttributeList as an ml.combust.bundle.dsl.Value. They must provide a JSON serialization as well as a compact byte representation.

T

Scala class of custom type

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CustomType
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def format: RootJsonFormat[T]

    Permalink

    Get the Spray JSON format for the custom type.

    Get the Spray JSON format for the custom type.

    This is the formatter used for serializing/deserializing the custom type with JSON.

    returns

    Spray JSON format

  2. abstract val klazz: Class[T]

    Permalink

    Class of the custom type.

  3. abstract def name: String

    Permalink

    Get name of the custom type.

    Get name of the custom type.

    This can be anything as long as it is unique among custom types

    returns

    name of the custom type

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  7. def equals(obj: Any): Boolean

    Permalink
    Definition Classes
    CustomType → AnyRef → Any
  8. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  9. def fromBytes(bytes: Array[Byte]): T

    Permalink

    Convert compact bytes to custom object.

    Convert compact bytes to custom object.

    bytes

    compact byte array

    returns

    deserialized custom object

  10. def fromJsonBytes(bytes: Array[Byte]): T

    Permalink

    Convert byte array of JSON to custom object.

    Convert byte array of JSON to custom object.

    bytes

    JSON byte array

    returns

    deserialized custom object

  11. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  12. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  13. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  14. def isLarge(obj: T): Boolean

    Permalink

    Whether or not this object is large when serialized.

    Whether or not this object is large when serialized.

    obj

    custom object

    returns

    true if large byte size when serialized, false otherwise

  15. def isSmall(obj: T): Boolean

    Permalink

    Whether or not this object is small when serialized.

    Whether or not this object is small when serialized.

    obj

    custom object

    returns

    true if small byte size when serialized, false otherwise

  16. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  18. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  19. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  20. def toBytes(obj: T): Array[Byte]

    Permalink

    Convert custom object to compact byte array.

    Convert custom object to compact byte array.

    obj

    custom object

    returns

    compact byte array serialization of obj

  21. def toJsonBytes(obj: T): Array[Byte]

    Permalink

    Convert object to byte array of JSON.

    Convert object to byte array of JSON.

    obj

    custom object

    returns

    byte array of JSON

  22. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  23. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped