mirror of
https://github.com/hanzoai/swift-sdk.git
synced 2026-10-30 18:20:19 +00:00
The forge tree held the package scaffolding and none of the generated sources — 2,435 files of APIs, Models and Infrastructure, including BaseAPI, were simply absent, so anything depending on this copy had a package that compiled to nothing usable. Generated from the current API document rather than reconciled with the other copy: a client is a function of the spec, so regenerating answers "which history wins" without anyone having to choose. .spec-lock records which document, so the next reader can tell.
46 lines
1.7 KiB
Swift
46 lines
1.7 KiB
Swift
//
|
|
// ArgoCluster.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct ArgoCluster: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** ConnectionState is whether the destination is reachable. */
|
|
public var connectionState: ArgoConnectionState?
|
|
/** Info is the connection state again plus the count of applications targeting this destination. */
|
|
public var info: ArgoClusterInfo?
|
|
/** Name is what the Destination column shows: \"in-cluster\" for this cluster, otherwise whatever spec.destination.name declares, falling back to the server URL when it declares none. */
|
|
public var name: String?
|
|
/** Server is the destination's API URL, and the key the list is deduplicated by. https://kubernetes.default.svc is this cluster. */
|
|
public var server: String?
|
|
|
|
public init(connectionState: ArgoConnectionState? = nil, info: ArgoClusterInfo? = nil, name: String? = nil, server: String? = nil) {
|
|
self.connectionState = connectionState
|
|
self.info = info
|
|
self.name = name
|
|
self.server = server
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case connectionState
|
|
case info
|
|
case name
|
|
case server
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(connectionState, forKey: .connectionState)
|
|
try container.encodeIfPresent(info, forKey: .info)
|
|
try container.encodeIfPresent(name, forKey: .name)
|
|
try container.encodeIfPresent(server, forKey: .server)
|
|
}
|
|
}
|
|
|