EUDCC

public struct EUDCC : Hashable
extension EUDCC: Decodable
extension EUDCC: Encodable

The European Digital COVID Certificate (EUCC)

Properties

  • The issuer

    Declaration

    Swift

    public let issuer: String
  • The issued at Date

    Declaration

    Swift

    public let issuedAt: Date
  • The expiry Date

    Declaration

    Swift

    public let expiresAt: Date
  • The Schema version

    Declaration

    Swift

    public let schmemaVersion: String
  • The date of birth

    Declaration

    Swift

    public let dateOfBirth: Date
  • The Name

    Declaration

    Swift

    public let name: Name
  • The Content

    Declaration

    Swift

    public let content: Content
  • The CryptographicSignature

    Declaration

    Swift

    public let cryptographicSignature: CryptographicSignature
  • The Base-45 representation

    Declaration

    Swift

    public let base45Representation: String

Initializer

Decodable

  • Creates a new instance by decoding from the given decoder.

    Declaration

    Swift

    public init(from decoder: Decoder) throws

    Parameters

    decoder

    The decoder to read data from.

EncoderUserInfoKeys

  • The EUDCC Encoder UserInfo Keys

    Declaration

    Swift

    enum EncoderUserInfoKeys

Encodable

  • Encodes this value into the given encoder.

    Declaration

    Swift

    public func encode(to encoder: Encoder) throws

    Parameters

    encoder

    The encoder to write data to.

Content

  • The EUDCC Content

    See more

    Declaration

    Swift

    enum Content : Hashable

Country

  • The EUDCC Country

    See more

    Declaration

    Swift

    struct Country : Hashable
    extension EUDCC.Country: Codable

CryptographicSignature

DiseaseAgentTargeted

  • The EUDCC disease or agent targeted

    See more

    Declaration

    Swift

    struct DiseaseAgentTargeted : Hashable
    extension EUDCC.DiseaseAgentTargeted: Codable

Name

  • The EUDCC Person Name

    See more

    Declaration

    Swift

    struct Name : Hashable
    extension EUDCC.Name: Codable

Convenience Content Accessor

Recovery

  • The EUDCC Recovery Entry

    See more

    Declaration

    Swift

    struct Recovery : Hashable
    extension EUDCC.Recovery: Codable

Test

  • The EUDCC Test Entry

    See more

    Declaration

    Swift

    struct Test : Hashable
    extension EUDCC.Test: Codable

Vaccination

  • The EUDCC Vaccination Entry

    See more

    Declaration

    Swift

    struct Vaccination : Hashable
    extension EUDCC.Vaccination: Codable

Convenience Decode

  • Decode EUDCC from EUDCC String representation

    Declaration

    Swift

    static func decode(
        from eudccStringRepresentation: String,
        using decoder: EUDCCDecoder = .init()
    ) -> Result<Self, EUDCCDecoder.DecodingError>

    Parameters

    eudccStringRepresentation

    The EUDCC String representation

    decoder

    The EUDCCDecoder. Default value .init()

    Return Value

    A Result contains either the successfully decoded EUDCC or an DecodingError

EUDCC+verify

SignedPayload

  • The EUDCC SignedPayload

    See more

    Declaration

    Swift

    struct SignedPayload : Codable, Hashable

EUDCC+TrustCertificate

EUDCC+VerificationCandidate

EUDCC+validate

  • Valide EUDCC using a ValidationRule

    Declaration

    Swift

    func validate(
        rule: EUDCC.ValidationRule = .default,
        using validator: EUDCCValidator = .init()
    ) -> EUDCCValidator.ValidationResult

    Parameters

    rule

    The ValidationRule that hsould be used to value the EUDCC. Default value .default

    validator

    The EUDCCValidator. Default value .init()

    Return Value

    The ValidationResult

ValidationRule