Version class Core

Compact major/minor version for content (usually roadmaps).

Encodes a major/minor pair. It can be compared to other Version.

Usually provided by classes such as ContentStoreItem, OffBoardListener and MapDetails.

See also:

Implemented types

Constructors

Version({int encodedVersion = 0})
Constructor for the Version class.
Version.fromJson(Map<String, dynamic> json)
Deserializes a JSON-compatible map to create an instance.
factory
Version.fromMajorAndMinor({required int major, required int minor})
Serializes this instance to a JSON-compatible map.
factory

Properties

hashCode int
The hash code for this object.
no setteroverride
isValid bool
Check if the version is valid
no setter
major int
Major version number
no setter
minor int
Minor version number
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

compareTo(Version other) int
Compares this object to another object.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(covariant Version other) bool
The equality operator.
override