extension
NewiOS
CTTelephonyNetworkInfo
NewiOSextension CTTelephonyNetworkInfoDeclaration
extension CTTelephonyNetworkInfo {
/// A message that posts when the radio access technology changes for one of the services.
///
/// Use the ``serviceIdentifier`` property as the key in ``CTTelephonyNetworkInfo/serviceCurrentRadioAccessTechnology`` to get the value of the new radio access technology for the service.
public struct RadioAccessTechnologyDidChangeMessage : NotificationCenter.AsyncMessage {
/// A type which you can optionally post and observe along with this `AsyncMessage`.
public typealias Subject = String
/// A optional name corresponding to this type, used to interoperate with notification posters and observers.
public static var name: Notification.Name { get }
/// The service identifier for which the radio access technology changed.
public var serviceIdentifier: String
/// Converts a posted notification into this asynchronous message type for any observers.
///
/// To implement this method in your own `AsyncMessage` conformance, retrieve values from the ``Notification``'s ``Notification/userInfo`` and set them as properties on the message.
/// - Parameter notification: The posted ``Notification``.
/// - Returns: The converted `AsyncMessage`, or `nil` if conversion is not possible.
public static func makeMessage(_ notification: Notification) -> CTTelephonyNetworkInfo.RadioAccessTechnologyDidChangeMessage?
/// Converts a posted asynchronous message into a notification for any observers.
///
/// To implement this method in your own `AsyncMessage` conformance, use the properties defined by the message to populate the ``Notification``'s ``Notification/userInfo``.
/// - Parameters:
/// - message: The posted `AsyncMessage`.
/// - Returns: The converted ``Notification``.
public static func makeNotification(_ message: CTTelephonyNetworkInfo.RadioAccessTechnologyDidChangeMessage) -> Notification
}
}