DefaultKitCreationEnvironmentConfigService

struct DefaultKitCreationEnvironmentConfigService

The DefaultKitCreationEnvironmentConfigService

  • The home directory path

    Declaration

    Swift

    let homeDirectoryPath: String?
  • The environment config file name

    Declaration

    Swift

    let environmentConfigFileName: String
  • The URL type

    Declaration

    Swift

    let urlType: URL.Type
  • The Data type

    Declaration

    Swift

    let dataType: Data.Type
  • The JSONDecoder

    Declaration

    Swift

    let jsonDecoder: JSONDecoder
  • Designated Initializer

    Declaration

    Swift

    init(homeDirectoryPath: String? = ProcessInfo.processInfo.environment["HOME"],
         environmentConfigFileName: String = ".swiftkit-env.json",
         urlType: URL.Type = URL.self,
         dataType: Data.Type = Data.self,
         jsonDecoder: JSONDecoder = .init())

    Parameters

    homeDirectoryPath

    The home directory path. Default value processInfo.environment["HOME"]

    environmentConfigFileName

    The environment config file name. Default value .swiftkit-env.json

    dataTyurlTypepe

    The URL type. Default value URL.self

    dataType

    The Data type. Default value Data.self

    jsonDecoder

    The JSONDecoder. Default value .init

  • Get KitCreationEnvironmentConfig

    Throws

    If retrieving fails

    Declaration

    Swift

    func get() throws -> KitCreationEnvironmentConfig

    Return Value

    The KitCreationEnvironmentConfig