- Index
- »
- sys
- »
- Serializable
type
Serializable
src
@FacetMeta { inherited=true }
@Serializable
facet class Serializable : Obj, Facet
Serializable is a facet used to annotate types which can be serialized. Objects are serialized via OutStream.writeObj
and deserialized via InStream.readObj
.
See the Serialization Doc for details.
fields
collection |
Collections are serialized with a collection of child objects using the following rules where |
---|---|
simple |
Simples are serialized atomically via a customized string representation using the following rules |
Slot Details
collection
simple
src
const Bool simple := false
Simples are serialized atomically via a customized string representation using the following rules:
- Override
Obj.toStr
to return a suitable string representation of the object. - Must declare a static method called
fromStr
which takes oneStr
parameter and returns an instance of the declaring type. ThefromStr
method may contain additional parameters if they declare defaults.