public interface IRestfulClient
| Modifier and Type | Method and Description |
|---|---|
<T extends IBaseResource> |
fetchResourceFromUrl(Class<T> theResourceType,
String theUrl)
Retrieve the contents at the given URL and parse them as a resource.
|
EncodingEnum |
getEncoding()
Returns the encoding that will be used on requests.
|
FhirContext |
getFhirContext()
Returns the FHIR context associated with this client
|
IHttpClient |
getHttpClient()
Do not call this method in client code.
|
List<IClientInterceptor> |
getInterceptors()
Returns the client interceptors that have been registered with this client
|
String |
getServerBase()
Base URL for the server, with no trailing "/"
|
void |
registerInterceptor(IClientInterceptor theInterceptor)
Register a new interceptor for this client.
|
void |
setEncoding(EncodingEnum theEncoding)
Specifies that the client should use the given encoding to do its
queries.
|
void |
setPrettyPrint(Boolean thePrettyPrint)
Specifies that the client should request that the server respond with "pretty printing"
enabled.
|
void |
setSummary(SummaryEnum theSummary)
If not set to
null, specifies a value for the _summary parameter
to be applied globally on this client. |
void |
unregisterInterceptor(IClientInterceptor theInterceptor)
Remove an intercaptor that was previously registered using
registerInterceptor(IClientInterceptor) |
<T extends IBaseResource> T fetchResourceFromUrl(Class<T> theResourceType, String theUrl)
theResourceType - The resource type to parsetheUrl - The URL to loadEncodingEnum getEncoding()
null, which means the client will not
explicitly request an encoding. (This is standard behaviour according to the FHIR specification)FhirContext getFhirContext()
IHttpClient getHttpClient()
List<IClientInterceptor> getInterceptors()
String getServerBase()
void registerInterceptor(IClientInterceptor theInterceptor)
void setEncoding(EncodingEnum theEncoding)
theEncoding - The encoding to use in the request, or null not specify
an encoding (which generally implies the use of XML). The default is null.void setPrettyPrint(Boolean thePrettyPrint)
thePrettyPrint - The pretty print flag to use in the request (default is false)void setSummary(SummaryEnum theSummary)
null, specifies a value for the _summary parameter
to be applied globally on this client.void unregisterInterceptor(IClientInterceptor theInterceptor)
registerInterceptor(IClientInterceptor)Copyright © 2014–2017 University Health Network. All rights reserved.