toString

open override fun toString(): String


fun toString(separator: String = ".", omitZeros: Boolean = false, omitIdx: Int = -1, omitMetadata: Boolean = false): String

Converts this version to a string, using the given separator

Parameters

separator

The separator to use between the version parts. Defaults to ..

omitZeros

Whether to omit trailing zeros in the version number (i.e. 1.0.0 ->1). Defaults to false.

omitIdx

The first index of the main version number that should not be included in the string, or -1 to include everything. Defaults to -1.

omitMetadata

Whether to omit the metadata. Defaults to false.