We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 617d875 commit ddc544bCopy full SHA for ddc544b
Sources/Shouter/Shouter.swift
@@ -14,7 +14,11 @@ public class Shouter {
14
15
fileprivate typealias Key = String
16
fileprivate var observers: [Key: NSHashTable<AnyObject>] = [:]
17
- fileprivate let notificationQueue = DispatchQueue(label: "com.swift.notification.center.dispatch.queue", attributes: .concurrent)
+ fileprivate let notificationQueue: DispatchQueue
18
+
19
+ public init(notificationQueue: DispatchQueue = DispatchQueue(label: "de.chaosspace.Shouter.dispatch.queue", attributes: .concurrent)) {
20
+ self.notificationQueue = notificationQueue
21
+ }
22
23
public func register<T>(_ type: T.Type, observer: T) {
24
notificationQueue.sync(flags: .barrier) {
0 commit comments