|
Uranium
Application Framework
|
Public Member Functions | |
| None | __init__ (self, Union[str, bytes, int, "Version", List[Union[int, str, bytes]]] version) |
| int | getMajor (self) |
| int | getMinor (self) |
| int | getRevision (self) |
| str | getPostfixType (self) |
| int | getPostfixVersion (self) |
| "Version" | getWithoutPostfix (self) |
| bool | hasPostFix (self) |
| bool | __gt__ (self, Union["Version", str] other) |
| bool | __lt__ (self, Union["Version", str] other) |
| bool | __eq__ (self, object other) |
| bool | __ge__ (self, Union["Version", str] other) |
| bool | __le__ (self, Union["Version", str] other) |
| str | __str__ (self) |
| int | __hash__ (self) |
Protected Attributes | |
| _major | |
| _minor | |
| _revision | |
| _postfix_type | |
| _postfix_version | |
Represents a version number, like "3.2.8" and allows comparison of those numbers.
| None UM.Version.Version.__init__ | ( | self, | |
| Union[str, bytes, int, "Version", List[Union[int, str, bytes]]] | version | ||
| ) |
Constructs the version instance from a string representing the version. The string representation may have dashes or underscores that separate the major, minor and revision version numbers. All text is ignored. :param version: A string or bytes representing a version number.
| bool UM.Version.Version.__eq__ | ( | self, | |
| object | other | ||
| ) |
Indicates whether this version is equal to the specified version. Implements the == operator. :param other: Either another version object or a string representing one.
| bool UM.Version.Version.__ge__ | ( | self, | |
| Union["Version", str] | other | ||
| ) |
Indicates whether this version is later or equal to the specified version. Implements the >= operator. :param other: Either another version object or a string representing one.
| bool UM.Version.Version.__gt__ | ( | self, | |
| Union["Version", str] | other | ||
| ) |
Indicates whether this version is later than the specified version. Implements the > operator. :param other: Either another version object or a string representing one.
| int UM.Version.Version.__hash__ | ( | self | ) |
Returns a number reasonably representing the identity of the version.
| bool UM.Version.Version.__le__ | ( | self, | |
| Union["Version", str] | other | ||
| ) |
Indicates whether this version is earlier or equal to the specified version. Implements the <= operator. :param other: Either another version object or a string representing one.
| bool UM.Version.Version.__lt__ | ( | self, | |
| Union["Version", str] | other | ||
| ) |
Indicates whether this version is earlier than the specified version. Implements the < operator. :param other: Either another version object or a string representing one.
| str UM.Version.Version.__str__ | ( | self | ) |
Returns a string representation containing the major, minor and revision number. Such as "3.2.8".
| int UM.Version.Version.getMajor | ( | self | ) |
Gets the major version number. The major version number is the first number of the version: "3" in the version "3.2.8".
| int UM.Version.Version.getMinor | ( | self | ) |
Gets the minor version number. The minor version number is the second number of the version: "2" in the version "3.2.8".
| str UM.Version.Version.getPostfixType | ( | self | ) |
Gets the postfix type. The postfix type is the name of the postfix, e.g. "alpha" in the version "1.2.3-alpha.4"
| int UM.Version.Version.getPostfixVersion | ( | self | ) |
Gets the postfix version number. The postfix version is the last number, e.g. "4" in the version "1.2.3-alpha.4"
| int UM.Version.Version.getRevision | ( | self | ) |
Gets the revision or patch version number. The revision version number is the third number of the version: "8" in the version "3.2.8".
| "Version" UM.Version.Version.getWithoutPostfix | ( | self | ) |
Returns this as _only_ a major.minor.revision, without the postfix type/version. The postfix is everything beyond the patch, like '-beta+1' in 5.0.0-beta+1 -- in this example 5.0.0 is returned.
| bool UM.Version.Version.hasPostFix | ( | self | ) |
Check if a version has a postfix.