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.
89 lines
3.3 KiB
Swift
89 lines
3.3 KiB
Swift
//
|
|
// CaptableSafe.swift
|
|
//
|
|
// Generated by openapi-generator
|
|
// https://openapi-generator.tech
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public struct CaptableSafe: Sendable, Codable, ParameterConvertible, Hashable {
|
|
|
|
/** Capital is the cash the investor put in. */
|
|
public var capital: Double?
|
|
/** DiscountRate is the discount to the next round's price, if any. */
|
|
public var discountRate: Double?
|
|
/** ID is the SAFE id. */
|
|
public var id: String?
|
|
/** IssueDate is the ISO date the SAFE was signed. */
|
|
public var issueDate: String?
|
|
/** MFN is true when the SAFE carries a most-favoured-nation clause. */
|
|
public var mfn: Bool?
|
|
/** ProRata is true when the SAFE carries pro-rata rights. */
|
|
public var proRata: Bool?
|
|
/** PublicID is the SAFE's shareable identifier, unique within the company. */
|
|
public var publicId: String?
|
|
/** StakeholderID is the investor. */
|
|
public var stakeholderId: String?
|
|
/** StakeholderName is that investor's name. */
|
|
public var stakeholderName: String?
|
|
/** Status is the SAFE's state, e.g. DRAFT or ACTIVE. */
|
|
public var status: String?
|
|
/** Type is POST_MONEY or PRE_MONEY. */
|
|
public var type: String?
|
|
/** ValuationCap is the valuation cap, if any. */
|
|
public var valuationCap: Double?
|
|
|
|
public init(capital: Double? = nil, discountRate: Double? = nil, id: String? = nil, issueDate: String? = nil, mfn: Bool? = nil, proRata: Bool? = nil, publicId: String? = nil, stakeholderId: String? = nil, stakeholderName: String? = nil, status: String? = nil, type: String? = nil, valuationCap: Double? = nil) {
|
|
self.capital = capital
|
|
self.discountRate = discountRate
|
|
self.id = id
|
|
self.issueDate = issueDate
|
|
self.mfn = mfn
|
|
self.proRata = proRata
|
|
self.publicId = publicId
|
|
self.stakeholderId = stakeholderId
|
|
self.stakeholderName = stakeholderName
|
|
self.status = status
|
|
self.type = type
|
|
self.valuationCap = valuationCap
|
|
}
|
|
|
|
public enum CodingKeys: String, CodingKey, CaseIterable {
|
|
case capital
|
|
case discountRate
|
|
case id
|
|
case issueDate
|
|
case mfn
|
|
case proRata
|
|
case publicId
|
|
case stakeholderId
|
|
case stakeholderName
|
|
case status
|
|
case type
|
|
case valuationCap
|
|
}
|
|
|
|
// Encodable protocol methods
|
|
|
|
public func encode(to encoder: Encoder) throws {
|
|
var container = encoder.container(keyedBy: CodingKeys.self)
|
|
try container.encodeIfPresent(capital, forKey: .capital)
|
|
try container.encodeIfPresent(discountRate, forKey: .discountRate)
|
|
try container.encodeIfPresent(id, forKey: .id)
|
|
try container.encodeIfPresent(issueDate, forKey: .issueDate)
|
|
try container.encodeIfPresent(mfn, forKey: .mfn)
|
|
try container.encodeIfPresent(proRata, forKey: .proRata)
|
|
try container.encodeIfPresent(publicId, forKey: .publicId)
|
|
try container.encodeIfPresent(stakeholderId, forKey: .stakeholderId)
|
|
try container.encodeIfPresent(stakeholderName, forKey: .stakeholderName)
|
|
try container.encodeIfPresent(status, forKey: .status)
|
|
try container.encodeIfPresent(type, forKey: .type)
|
|
try container.encodeIfPresent(valuationCap, forKey: .valuationCap)
|
|
}
|
|
}
|
|
|
|
|
|
@available(iOS 13, tvOS 13, watchOS 6, macOS 10.15, *)
|
|
extension CaptableSafe: Identifiable {}
|