SwiftBlade enums

In this case, HederaNetwork has two possible values: TESTNET and MAINNET. These values are of type String and are represented as cases of the enumeration using the case keyword.

The public keyword indicates that this enumeration can be accessed from outside the module where it is defined.

Overall, this code defines a way to represent the two different network options available for interacting with the Hedera Hashgraph platform: TESTNET for testing and development purposes, and MAINNET for production use.

public enum HederaNetwork: String {
    case TESTNET
    case MAINNET
}

BladeEnv has two possible values: Prod and CI. Indicating BladeApi environment. Prod for production use and CI for testing and development purposes.

public enum BladeEnv: String {
    case Prod = "Prod"
    case CI = "CI"
}
public enum SwiftBladeError: Error {
    case unknownJsError(String)
    case apiError(String)
    case initError(String)
}
public enum CryptoFlowServiceStrategy: String {
    case BUY = "Buy"
    case SELL = "Sell"
    case SWAP = "Swap"
}
public enum CryptoKeyType: String, Codable {
    case ECDSA_SECP256K1 = "ECDSA_SECP256K1"
    case ED25519 = "ED25519"
}
public enum KeyType: String, Codable {
    case admin = "admin"
    case kyc = "kyc"
    case freeze = "freeze"
    case wipe = "wipe"
    case pause = "pause"
    case feeSchedule = "feeSchedule"
}
public enum IPFSProvider: String, Encodable {
    case pinata = "pinata"
}
public enum ScheduleTransactionType: String, Codable {
    case TRANSFER = "TRANSFER"
    // case SUBMIT_MESSAGE = "SUBMIT_MESSAGE"
    // case APPROVE_ALLOWANCE = "APPROVE_ALLOWANCE"
    // case TOKEN_MINT = "TOKEN_MINT"
    // case TOKEN_BURN = "TOKEN_BURN"
}
public enum ScheduleTransferType: String, Codable {
    case HBAR = "HBAR"
    case FT = "FT"
    case NFT = "NFT"
}

Last updated