Eyerise
public struct Eyerise
Undocumented
-
Returns app’s name
Declaration
Swift
public static var appDisplayName: String?
-
Returns app’s version number
Declaration
Swift
public static var appVersion: String?
-
Return app’s build number
Declaration
Swift
public static var appBuild: String?
-
Return app’s bundle ID
Declaration
Swift
public static var appBundleID: String?
-
Returns both app’s version and build numbers
v0.3(7)
Declaration
Swift
public static var appVersionAndBuild: String?
-
Return device version “”
Declaration
Swift
public static var deviceVersion: String
-
Returns true if DEBUG mode is active //TODO: Add to readme
Declaration
Swift
public static var isDebug: Bool
-
Returns true if RELEASE mode is active //TODO: Add to readme
Declaration
Swift
public static var isRelease: Bool
-
Returns true if its simulator and not a device //TODO: Add to readme
Declaration
Swift
public static var isSimulator: Bool
-
Returns true if its on a device and not a simulator //TODO: Add to readme
Declaration
Swift
public static var isDevice: Bool
-
Returns true if app is running in test flight mode
Declaration
Swift
public static var isInTestFlight: Bool
-
Returns the top ViewController
Declaration
Swift
public static var topMostVC: UIViewController?
-
Returns current screen orientation
Declaration
Swift
public static var screenOrientation: UIInterfaceOrientation
-
Undocumented
Declaration
Swift
public static var horizontalSizeClass: UIUserInterfaceSizeClass
-
Undocumented
Declaration
Swift
public static var verticalSizeClass: UIUserInterfaceSizeClass
-
Returns screen width
Declaration
Swift
public static var screenWidth: CGFloat
-
Returns screen height
Declaration
Swift
public static var screenHeight: CGFloat
-
Returns StatusBar height
Declaration
Swift
public static var screenStatusBarHeight: CGFloat
-
Return screen’s height without StatusBar
Declaration
Swift
public static var screenHeightWithoutStatusBar: CGFloat
-
Returns the locale country code. An example value might be
ES
. //TODO: Add to readmeDeclaration
Swift
public static var currentRegion: String?
-
Calls action when a screen shot is taken
Declaration
Swift
public static func detectScreenShot(_ action: @escaping () -> Void)
-
Iterates through enum elements, use with (for element in ez.iterateEnum(myEnum))
Declaration
Swift
public static func iterateEnum<T: Hashable>(_: T.Type) -> AnyIterator<T>
-
Runs the function after x seconds
Declaration
Swift
public static func dispatchDelay(_ second: Double, closure:@escaping () -> Void)
-
Runs function after x seconds
Declaration
Swift
public static func runThisAfterDelay(seconds: Double, after: @escaping () -> Void)
-
Runs function after x seconds with dispatch_queue, use this syntax: dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_LOW, 0)
Declaration
Swift
public static func runThisAfterDelay(seconds: Double, queue: DispatchQueue, after: @escaping () -> Void)
-
Submits a block for asynchronous execution on the main queue
Declaration
Swift
public static func runThisInMainThread(_ block: @escaping () -> Void)
-
Runs in Default priority queue
Declaration
Swift
public static func runThisInBackground(_ block: @escaping () -> Void)
-
Runs every second, to cancel use: timer.invalidate()
Declaration
Swift
@discardableResult public static func runThisEvery( seconds: TimeInterval, startAfterSeconds: TimeInterval, handler: @escaping (CFRunLoopTimer?) -> Void) -> Timer
-
Gobal main queue
Declaration
Swift
public var globalMainQueue: DispatchQueue
-
Gobal queue with user interactive priority
Declaration
Swift
public var globalUserInteractiveQueue: DispatchQueue
-
Gobal queue with user initiated priority
Declaration
Swift
public var globalUserInitiatedQueue: DispatchQueue
-
Gobal queue with utility priority
Declaration
Swift
public var globalUtilityQueue: DispatchQueue
-
Gobal queue with background priority
Declaration
Swift
public var globalBackgroundQueue: DispatchQueue
-
Gobal queue with default priority
Declaration
Swift
public var globalQueue: DispatchQueue
-
Downloads image from url string
Declaration
Swift
public static func requestImage(_ url: String, success: @escaping (UIImage?) -> Void)
-
Downloads JSON from url string
Declaration
Swift
public static func requestJSON(_ url: String, success: @escaping ((Any?) -> Void), error: ((NSError) -> Void)?)