Documentation ¶
Index ¶
- Constants
- type Version
- func (v1 Version) Compare(v2 Version) int
- func (v *Version) Epoch() int
- func (v1 *Version) Equal(v2 Version) bool
- func (v1 *Version) GreaterThan(v2 Version) bool
- func (v1 Version) LessThan(v2 Version) bool
- func (v *Version) Release() string
- func (v1 Version) String() string
- func (v *Version) Version() string
Constants ¶
View Source
const ( LESS = -1 EQUAL = 0 GREATER = 1 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Version ¶
type Version struct {
// contains filtered or unexported fields
}
Version represents a package version.
func (Version) Compare ¶
Compare returns an integer comparing two version. The result will be 0 if v1==v2, -1 if v1 < v2, and +1 if v1 > v2.
func (*Version) GreaterThan ¶
GreaterThan returns whether this version is greater than another version.
Click to show internal directories.
Click to hide internal directories.