FHIRClient
public class FHIRClient
Lightweight client for FHIR communication. Can perform FHIROperation
s.
-
Initialize with the service URL and an
HTTPClient
Declaration
Swift
public init(server: URL, httpClient: HTTPClient, receiveQueue: AnySchedulerOf<DispatchQueue> = .main)
Parameters
server
URL
where the request will be sent tohttpClient
HTTPClient
that will (alter and) perform the request resulting from aFHIRClientOperation
-
Perform a request derived from a
FHIRClientOperation
.Declaration
Swift
public func execute<F>(operation: F) -> AnyPublisher<F.Value, FHIRClient.Error> where F : FHIRClientOperation
Parameters
operation
The request to be performed will be derived from this
FHIRClientOperation
.Return Value
AnyPublisher
that emits aFHIRClient.Response
-
Wrapper for the URLResponse receiver from the FHIR service
See moreDeclaration
Swift
public struct Response
-
Error cases when using the
See moreFHIRClient
Declaration
Swift
public enum Error : Swift.Error, Equatable, CustomStringConvertible, LocalizedError
-
‘Anonymous-inner-class’ for FHIRResponseHandler
See moreDeclaration
Swift
public class DefaultFHIRResponseHandler<Value> : FHIRResponseHandler