AppConfig

struct AppConfig : Decodable

App Config is to fetch the values from config files if there is no config files the values will be fetched from the default values

  • Undocumented

    Declaration

    Swift

    let API_SERVER_URL: String?
  • Undocumented

    Declaration

    Swift

    let AUTH_HEADER: String?
  • Undocumented

    Declaration

    Swift

    let DOWNLOAD_MODEL_URL: String?
  • Undocumented

    Declaration

    Swift

    let DEBUG_FOR_SAVING_IMAGES: Bool?
  • Shared instance to load and access values once

    Declaration

    Swift

    private static let shared: AppConfig
  • Static computed properties to access JSON values with default fallbacks

    Declaration

    Swift

    static var API_SERVER_URL: String { get }
  • Undocumented

    Declaration

    Swift

    static var AUTH_HEADER: String { get }
  • Undocumented

    Declaration

    Swift

    static var DOWNLOAD_MODEL_URL: String { get }
  • Undocumented

    Declaration

    Swift

    static var DEBUG_FOR_SAVING_IMAGES: Bool { get }
  • Private method to load and decode JSON file

    Declaration

    Swift

    private static func load() -> AppConfig