PrereleaseIdentifier

public enum PrereleaseIdentifier : Comparable, Hashable, Sendable
extension PrereleaseIdentifier: LosslessStringConvertible
extension PrereleaseIdentifier: ExpressibleByStringLiteral
extension PrereleaseIdentifier: ExpressibleByIntegerLiteral

Enumerated pre-release identifier for SemVer.

Note

Identifier can be described using alphanumeric or numeric letters.

Attention

If an identifier does not show conformance for beeing numeric or alphanumeric it is initialized as nil.

  • Identifier displaying alpha.

    Declaration

    Swift

    case alpha
  • Identifier displaying beta.

    Declaration

    Swift

    case beta
  • Identifier displaying prerelease.

    Declaration

    Swift

    case prerelease
  • Identifier displaying rc.

    Declaration

    Swift

    case releaseCandidate
  • Alphanumeric identifier are lower- and uppercased letters and numbers from 0-9.

    Declaration

    Swift

    case alphaNumeric(_: String)
  • Numeric identifier are positive numbers and zeros, yet they do not allow for leading zeros.

    Declaration

    Swift

    case numeric(_: UInt)
  • Unknown identifier are used when string literals do not conform to SemVer and are removed.

    Declaration

    Swift

    case unknown
  • Compares pre-release identifiers for equality.

    Declaration

    Swift

    static func == (lhs: `Self`, rhs: `Self`) -> Bool

    Return Value

    true if pre-release identifiers are equal.

PrereleaseIdentifier + LosslessStringConvertible

  • Declaration

    Swift

    public var description: String { get }
  • Declaration

    Swift

    public init?(_ string: String)

PrereleaseIdentifier + ExpressibleByStringLiteral

PrereleaseIdentifier + ExpressibleByIntegerLiteral

  • Declaration

    Swift

    public init(integerLiteral value: IntegerLiteralType)
  • Raw string representation of a pre-release identifier.

    Declaration

    Swift

    var value: String { get }