Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Gimp/libgimp/test/   (Gimp Bildeditor Version 3.2.0©)  Datei vom 14.2.2026 mit Größe 9 kB image not shown  

SSL ServerAPIRequestAdapter.swift   Interaktion und
PortierbarkeitJAVA

 

import CocoaLumberjackSwift
import Foundation

/// Default implementation that wraps the Objective-C `ServerAPIRequest` class.
///
/// This adapter bridges the callback-based `ServerAPIRequest` API to Swift's
/// async/await concurrency model.
public final class ServerAPIRequestAdapter: ServerAPIRequestProtocol {
    
    public init() { }
    
    public func postJSONToWorkAPI(path: String, data: [String: Any]) async throws -> Any? {
        try await withCheckedThrowingContinuation { continuation in
            ServerAPIRequest.postJSON(toWorkAPIPath: path, data: data) { json in
                continuation.resume(returning: json)
            } onError: { error in
                if let error {
                    DDLogError("[ServerAPIRequestAdapter] Error: \(error)")
                    continuation.resume(throwing: error)
                }
                else {
                    continuation.resume(returning: nil)
                }
            }
        }
    }
}

Messung
CHZG
91919391

¤ Diese beiden folgenden Angebotsgruppen bietet das Unternehmen0.6Angebot  (Wie Sie bei der Firma Beratungs- und Dienstleistungen beauftragen können 2026-11-24) ¤

*Eine klare Vorstellung vom Zielzustand