Interface Client
- All Superinterfaces:
AutoCloseable,Closeable
- All Known Implementing Classes:
HttpComponentsClient
Abstraction around underlying Http Client library. Allows for replacing the
underlying library in the future if needed.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Close the Client implementation and release any resources it may have open.executeRequest(Request<?> request) Execute the supplied request and return the server's response.
-
Method Details
-
executeRequest
Execute the supplied request and return the server's response.- Parameters:
request- The request to execute.- Returns:
- The API response.
-
close
void close()Close the Client implementation and release any resources it may have open.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-