/* Options:
Date: 2025-04-04 05:58:30
SwiftVersion: 6.0
Version: 8.52
Tip: To override a DTO option, remove "//" prefix before updating
BaseUrl: https://taxfiling.pwc.de

//BaseClass: 
//AddModelExtensions: True
//AddServiceStackTypes: True
//MakePropertiesOptional: True
IncludeTypes: VersionCheckAsync.*
//ExcludeTypes: 
//ExcludeGenericBaseTypes: False
//AddResponseStatus: False
//AddImplicitVersion: 
//AddDescriptionAsComments: True
//InitializeCollections: False
//TreatTypesAsStrings: 
//DefaultImports: Foundation,ServiceStack
*/

import Foundation
import ServiceStack

/**
* An asynchronous service to retrieve the list of all product and file versions of used ERiC-libraries.
*/
// @Route("/VersionCheckAsync", "GET")
// @Api(Description="An asynchronous service to retrieve the list of all product and file versions of used ERiC-libraries.")
public class VersionCheckAsync : VersionCheckBase, IReturn
{
    public typealias Return = EricVersionResponse

    required public init(){ super.init() }

    required public init(from decoder: Decoder) throws {
        try super.init(from: decoder)
    }

    public override func encode(to encoder: Encoder) throws {
        try super.encode(to: encoder)
    }
}

/**
* Represents a type that encapsulates the versions of ERiC library components.
*/
// @Api(Description="Represents a type that encapsulates the versions of ERiC library components.")
public class EricVersionResponse : EricFehlerCodeResponse
{
    /**
    * The version of an ERiC library component.
    */
    // @ApiMember(Description="The version of an ERiC library component.")
    public var rueckgabe:EricVersion?

    required public init(){ super.init() }

    private enum CodingKeys : String, CodingKey {
        case rueckgabe
    }

    required public init(from decoder: Decoder) throws {
        try super.init(from: decoder)
        let container = try decoder.container(keyedBy: CodingKeys.self)
        rueckgabe = try container.decodeIfPresent(EricVersion.self, forKey: .rueckgabe)
    }

    public override func encode(to encoder: Encoder) throws {
        try super.encode(to: encoder)
        var container = encoder.container(keyedBy: CodingKeys.self)
        if rueckgabe != nil { try container.encode(rueckgabe, forKey: .rueckgabe) }
    }
}

/**
* A base service to retrieve the list of all product and file versions of used ERiC-libraries.
*/
// @Api(Description="A base service to retrieve the list of all product and file versions of used ERiC-libraries.")
public class VersionCheckBase : IGet, Codable
{
    required public init(){}
}

/**
* Represents a structure that encapsulates a list of ERiC dynamic libraries.
*/
// @Api(Description="Represents a structure that encapsulates a list of ERiC dynamic libraries.")
public class EricVersion : Codable
{
    /**
    * The list of available ERiC dynamic libraries.
    */
    // @ApiMember(Description="The list of available ERiC dynamic libraries.")
    public var bibliotheken:[Bibliothek] = []

    required public init(){}
}

/**
* Represents Represents an ERiC dynamic library.
*/
// @Api(Description="Represents Represents an ERiC dynamic library.")
public class Bibliothek : Codable
{
    /**
    * The name of the library.
    */
    // @ApiMember(Description="The name of the library.")
    public var name:String?

    /**
    * The product version of the library.
    */
    // @ApiMember(Description="The product version of the library.")
    public var produktversion:String?

    /**
    * The file version of the library.
    */
    // @ApiMember(Description="The file version of the library.")
    public var dateiversion:String?

    /**
    * The list of test modules of the library.
    */
    // @ApiMember(Description="The list of test modules of the library.")
    public var pruefModulen:[PruefModul] = []

    required public init(){}
}

/**
* Represent a version of the internally used test module.
*/
// @Api(Description="Represent a version of the internally used test module.")
public class PruefModul : Codable
{
    /**
    * The tax data type version of the test module.
    */
    // @ApiMember(Description="The tax data type version of the test module.")
    public var datenartVersion:String?

    /**
    * The label of the test module.
    */
    // @ApiMember(Description="The label of the test module.")
    public var label:String?

    /**
    * The runtime of the test module.
    */
    // @ApiMember(Description="The runtime of the test module.")
    public var runtime:String?

    required public init(){}
}

/**
* Represent a base response that encapsulate any ERiC API function return value.
*/
// @Api(Description="Represent a base response that encapsulate any ERiC API function return value.")
public class EricFehlerCodeResponse : ServiceReponseBase
{
    /**
    * The status code that the ERiC API function returns.
    */
    // @ApiMember(Description="The status code that the ERiC API function returns.")
    public var statusCode:EricFehlerCode?

    /**
    * The status message that the ERiC API function returns.
    */
    // @ApiMember(Description="The status message that the ERiC API function returns.")
    public var statusText:String?

    required public init(){ super.init() }

    private enum CodingKeys : String, CodingKey {
        case statusCode
        case statusText
    }

    required public init(from decoder: Decoder) throws {
        try super.init(from: decoder)
        let container = try decoder.container(keyedBy: CodingKeys.self)
        statusCode = try container.decodeIfPresent(EricFehlerCode.self, forKey: .statusCode)
        statusText = try container.decodeIfPresent(String.self, forKey: .statusText)
    }

    public override func encode(to encoder: Encoder) throws {
        try super.encode(to: encoder)
        var container = encoder.container(keyedBy: CodingKeys.self)
        if statusCode != nil { try container.encode(statusCode, forKey: .statusCode) }
        if statusText != nil { try container.encode(statusText, forKey: .statusText) }
    }
}