OrdereableModel mixin
A GenericModel that has an ordinal parameter. When used with a ReorderableMap, by default greater ordinal values should be shown first.
This is to make it convenient to add a custom sort feature.
- Superclass Constraints
Properties
-
fieldKeys
→ Iterable<
String> -
Returns all the available field keys in this object.
no setterinherited
- getterSetterMap → MappableFields
-
Used by toMap to generate the map
latefinalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id ↔ String?
-
Unique identifier for this model
getter/setter pairinherited
- idKey → String
-
Represents the field key used for the id
no setterinherited
- ordinal ↔ int
-
Compared with other instances of OrdereableModel to set the custom sort.
getter/setter pair
-
ordinalGetterSetter
→ Tuple2<
Getter, Setter> -
Add this to your implementation of the
getGetterSetterMap function of GenericModel
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- type → String
-
Unique type to give to the model. Whether or not collision is expected is
dependent on the parameters of your system.
no setterinherited
- typeKey → String
-
Represents the field key used for the type
no setterinherited
Methods
-
getField(
String key) → dynamic -
Returns the value of the field with name
key
or null ifkey
is not a field in this model.inherited -
getGetterSetterMap(
) → MappableFields -
Implemented by subclasses to map the getters and setters of the object.
inherited
-
loadFromMap(
Map< String, dynamic> map, {bool respectType = true}) → void -
Loads a Serializable map into the values of this BaseModel
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setField(
String key, dynamic value) → bool -
Sets the field with name
key
to the givenvalue
inherited -
toMap(
) → Map< String, dynamic> -
Converts this BaseModel into a Serializable Map.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited