This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Alamofire | |
import Combine | |
final class NetworkReachabilityHelper { | |
static let shared = NetworkReachabilityHelper() | |
private enum Constants { | |
static let host = "api1.\(Environment.domain)" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
import SystemConfiguration | |
class Reachability | |
{ | |
var hostname: String? | |
var isRunning = false | |
var isReachableOnWWAN: Bool | |
var reachability: SCNetworkReachability? | |
var reachabilityFlags = SCNetworkReachabilityFlags() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Created by Saeed Rezaei. | |
// | |
import Foundation | |
public enum DeviceTypes : String { | |
case simulator = "Simulator", | |
iPad2 = "iPad 2", | |
iPad3 = "iPad 3", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// An Int representing a Jalaali year. | |
public typealias JalaaliYear = Int | |
/// An Int representing a Jalaali month (1-based). | |
public typealias JalaaliMonth = Int | |
/// An Int representing a Jalaali day. | |
public typealias JalaaliDay = Int | |
/// An Int representing a Gregorian year. |