Serializer class
Serializes to and deserializes from JSON.
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
deserialize(
String jsonText, Serializable target) → void -
Deserializes the given
jsonText
into the specified serializabletarget
. -
deserializeList(
String jsonText, List< Serializable> targetList, Serializable creator(Map<String, dynamic> )) → void -
Deserializes the given
jsonText
into the specified list of serializablestarget
. -
deserializeOnDemand(
String jsonText, OnDemandSerializable target, {Map< String, dynamic Function(dynamic)> ? transformers, Map<String, dynamic Function(Map< ? objectCreators}) → voidString, dynamic> ?)> -
Deserializes the specied
jsonText
into the OnDemandSerializabletarget
. Specifytransformers
to transform values such as enums or non-String Map keys. SpecifyobjectCreators
when you have Lists, Map or nested objects. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
serialize(
Serializable serializable) → String -
Serializes the specified
serializable
instance. Generates the JSON text representation. -
serializeList(
List< Serializable> serializables) → String -
Serializes the given list of
serializables
. Generates the JSON text representation. -
serializeOnDemand(
OnDemandSerializable onDemandSerializable, {Map< String, dynamic Function(dynamic)> ? transformers}) → String - Serializes an OnDemandSerializable object.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited