Helper library use to compare or validate the semantic versions (VersionUtils.sol)

View Source: contracts/libraries/VersionUtils.sol

VersionUtils

Functions

lessThanOrEqual

function lessThanOrEqual(uint8[] _current, uint8[] _new) internal pure
returns(bool)

Arguments

Name

Type

Description

_current

uint8[]

_new

uint8[]

greaterThanOrEqual

Arguments

Name

Type

Description

_current

uint8[]

_new

uint8[]

pack

Used to pack the uint8[] array data into uint24 value

Arguments

Name

Type

Description

_major

uint8

Major version

_minor

uint8

Minor version

_patch

uint8

Patch version

unpack

Used to convert packed data into uint8 array

Arguments

Name

Type

Description

_packedVersion

uint24

Packed data

packKYC

Used to packed the KYC data

Arguments

Name

Type

Description

_a

uint64

_b

uint64

_c

uint64

_d

uint8

unpackKYC

Used to convert packed data into KYC data

Arguments

Name

Type

Description

_packedVersion

uint256

Packed data

Last updated

Was this helpful?