@@ -25,19 +25,24 @@ public enum Schedulers {
2525 public static var asyncMain : DispatchQueue . Scheduler { . asyncMain }
2626
2727 /// In case `schedule` methods are called from `DispatchQueue.userInteractive`, it will perform action immediately without scheduling.
28- public static var userInteractive : DispatchQueue . Scheduler { . userInteractive }
28+ public static func userInteractive( file: StaticString = #fileID, line: UInt = #line) -> DispatchQueue . Scheduler { DispatchQueue . Scheduler. userInteractive ( file: file, line: line)
29+ }
2930
3031 /// In case `schedule` methods are called from `DispatchQueue.userInitiated`, it will perform action immediately without scheduling.
31- public static var userInitiated : DispatchQueue . Scheduler { . userInitiated }
32+ public static func userInitiated( file: StaticString = #fileID, line: UInt = #line) -> DispatchQueue . Scheduler { DispatchQueue . Scheduler. userInitiated ( file: file, line: line)
33+ }
3234
3335 /// In case `schedule` methods are called from `DispatchQueue.default`, it will perform action immediately without scheduling.
34- public static var `default` : DispatchQueue . Scheduler { . default }
36+ public static func `default`( file: StaticString = #fileID, line: UInt = #line) -> DispatchQueue . Scheduler { DispatchQueue . Scheduler. default ( file: file, line: line)
37+ }
3538
3639 /// In case `schedule` methods are called from `DispatchQueue.utility`, it will perform action immediately without scheduling.
37- public static var utility : DispatchQueue . Scheduler { . utility }
40+ public static func utility( file: StaticString = #fileID, line: UInt = #line) -> DispatchQueue . Scheduler { DispatchQueue . Scheduler. utility ( file: file, line: line)
41+ }
3842
3943 /// In case `schedule` methods are called from `DispatchQueue.background`, it will perform action immediately without scheduling.
40- public static var background : DispatchQueue . Scheduler { . background }
44+ public static func background( file: StaticString = #fileID, line: UInt = #line) -> DispatchQueue . Scheduler { DispatchQueue . Scheduler. background ( file: file, line: line)
45+ }
4146}
4247
4348public extension DispatchQueue {
@@ -51,19 +56,29 @@ public extension DispatchQueue {
5156 public static let asyncMain : Scheduler = . init( . main, alwaysAsync: true )
5257
5358 /// In case `schedule` methods are called from `DispatchQueue.userInteractive`, it will perform action immediately without scheduling.
54- public static let userInteractive : Scheduler = . init( . userInteractive)
59+ public static func userInteractive( file: StaticString = #fileID, line: UInt = #line) -> Scheduler {
60+ Scheduler ( DispatchQueue . userInteractive ( file: file, line: line) )
61+ }
5562
5663 /// In case `schedule` methods are called from `DispatchQueue.userInitiated`, it will perform action immediately without scheduling.
57- public static let userInitiated : Scheduler = . init( . userInitiated)
64+ public static func userInitiated( file: StaticString = #fileID, line: UInt = #line) -> Scheduler {
65+ Scheduler ( DispatchQueue . userInitiated ( file: file, line: line) )
66+ }
5867
5968 /// In case `schedule` methods are called from `DispatchQueue.default`, it will perform action immediately without scheduling.
60- public static let `default` : Scheduler = . init( . default)
69+ public static func `default`( file: StaticString = #fileID, line: UInt = #line) -> Scheduler {
70+ Scheduler ( DispatchQueue . default ( file: file, line: line) )
71+ }
6172
6273 /// In case `schedule` methods are called from `DispatchQueue.utility`, it will perform action immediately without scheduling.
63- public static let utility : Scheduler = . init( . utility)
74+ public static func utility( file: StaticString = #fileID, line: UInt = #line) -> Scheduler {
75+ Scheduler ( DispatchQueue . utility ( file: file, line: line) )
76+ }
6477
6578 /// In case `schedule` methods are called from `DispatchQueue.background`, it will perform action immediately without scheduling.
66- public static let background : Scheduler = . init( . background)
79+ public static func background( file: StaticString = #fileID, line: UInt = #line) -> Scheduler {
80+ Scheduler ( DispatchQueue . background ( file: file, line: line) )
81+ }
6782
6883 public typealias SchedulerOptions = Never
6984 public typealias SchedulerTimeType = Foundation . DispatchQueue . SchedulerTimeType
0 commit comments