-
-
Notifications
You must be signed in to change notification settings - Fork 31
/
Copy pathAPNSContainerID.swift
26 lines (23 loc) · 1.44 KB
/
APNSContainerID.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
extension APNSContainers.ID {
/// A default container ID available for use.
///
/// If you are configuring both a production and development container, ``production`` and ``development`` are also available.
///
/// - Note: You must configure this ID before using it by calling ``VaporAPNS/APNSContainers/use(_:eventLoopGroupProvider:responseDecoder:requestEncoder:byteBufferAllocator:as:isDefault:)``.
/// - Important: The actual default ID to use in ``Vapor/Application/APNS/client`` when none is provided is the first configuration that doesn't specify a value of `false` for `isDefault:`.
public static var `default`: APNSContainers.ID {
return .init(string: "default")
}
/// An ID that can be used for the production APNs environment.
///
/// - Note: You must configure this ID before using it by calling ``APNSContainers/use(_:eventLoopGroupProvider:responseDecoder:requestEncoder:byteBufferAllocator:as:isDefault:)``
public static var production: APNSContainers.ID {
return .init(string: "production")
}
/// An ID that can be used for the development (aka sandbox) APNs environment.
///
/// - Note: You must configure this ID before using it by calling ``APNSContainers/use(_:eventLoopGroupProvider:responseDecoder:requestEncoder:byteBufferAllocator:as:isDefault:)``
public static var development: APNSContainers.ID {
return .init(string: "development")
}
}