public interface ISafeguardConnection
| Modifier and Type | Method and Description |
|---|---|
void |
dispose()
Disposes of the connection.
|
int |
getAccessTokenLifetimeRemaining()
Number of minutes remaining in the lifetime of the Safeguard API access token.
|
SafeguardEventListener |
getEventListener()
Gets a Safeguard event listener.
|
ISafeguardEventListener |
getPersistentEventListener()
Gets a persistent Safeguard event listener.
|
String |
invokeMethod(Service service,
Method method,
String relativeUrl,
String body,
Map<String,String> parameters,
Map<String,String> additionalHeaders)
Call a Safeguard API method and get any response as a string.
|
String |
invokeMethodCsv(Service service,
Method method,
String relativeUrl,
String body,
Map<String,String> parameters,
Map<String,String> additionalHeaders) |
FullResponse |
invokeMethodFull(Service service,
Method method,
String relativeUrl,
String body,
Map<String,String> parameters,
Map<String,String> additionalHeaders)
Call a Safeguard API method and get a detailed response with status code, headers,
and body.
|
void |
logOut()
Call Safeguard API to invalidate current access token and clear its value from
the connection.
|
void |
refreshAccessToken()
Request a new Safeguard API access token with the underlying credentials used to
initial create the connection.
|
int getAccessTokenLifetimeRemaining()
throws ObjectDisposedException,
SafeguardForJavaException
ObjectDisposedException - Object has already been disposed.SafeguardForJavaException - General Safeguard for Java exception.void refreshAccessToken()
throws ObjectDisposedException,
SafeguardForJavaException
ObjectDisposedException - Object has already been disposed.SafeguardForJavaException - General Safeguard for Java exception.String invokeMethod(Service service, Method method, String relativeUrl, String body, Map<String,String> parameters, Map<String,String> additionalHeaders) throws ObjectDisposedException, SafeguardForJavaException, ArgumentException
service - Safeguard service to call.method - Safeguard method type to use.relativeUrl - Relative URL of the service to use.body - Request body to pass to the method.parameters - Additional parameters to add to the URL.additionalHeaders - Additional headers to add to the request.ObjectDisposedException - Object has already been disposed.SafeguardForJavaException - General Safeguard for Java exception.ArgumentException - Invalid argument.FullResponse invokeMethodFull(Service service, Method method, String relativeUrl, String body, Map<String,String> parameters, Map<String,String> additionalHeaders) throws ObjectDisposedException, SafeguardForJavaException, ArgumentException
service - Safeguard service to call.method - Safeguard method type to use.relativeUrl - Relative URL of the service to use.body - Request body to pass to the method.parameters - Additional parameters to add to the URL.additionalHeaders - Additional headers to add to the request.ObjectDisposedException - Object has already been disposed.SafeguardForJavaException - General Safeguard for Java exception.ArgumentException - Invalid argument.String invokeMethodCsv(Service service, Method method, String relativeUrl, String body, Map<String,String> parameters, Map<String,String> additionalHeaders) throws ObjectDisposedException, SafeguardForJavaException, ArgumentException
SafeguardEventListener getEventListener() throws ObjectDisposedException, ArgumentException
ObjectDisposedException - Object has already been disposed.ArgumentException - Invalid argument.ISafeguardEventListener getPersistentEventListener() throws ObjectDisposedException, SafeguardForJavaException
ObjectDisposedException - Object has already been disposed.SafeguardForJavaException - General Safeguard for Java exception.void logOut()
throws ObjectDisposedException
ObjectDisposedException - Object has already been disposed.void dispose()
Copyright © 2019. All rights reserved.