SemVer class

Represents a parsed Semantic Versioning 2.0.0 compliance object.

Implemented types

Constructors

SemVer({required int major, required int minor, required int patch, List<String> prerelease = const [], List<String> build = const []})
const
SemVer.parse(String input)
Parses a string into a SemVer according to SemVer 2.0.0 rules.
factory

Properties

build → List<String>
final
hashCode → int
The hash code for this object.
no setteroverride
isPrerelease → bool
Returns true if this version is a prerelease (has prerelease identifiers).
no setter
major → int
final
minor → int
final
patch → int
final
prerelease → List<String>
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

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

Operators

operator ==(Object other) → bool
The equality operator.
override