Class BatchRequest
- java.lang.Object
-
- org.apache.syncope.client.lib.batch.BatchRequest
-
public class BatchRequest extends Object
Encapsulates the Batch request management via CXF Proxy Client.
-
-
Constructor Summary
Constructors Constructor Description BatchRequest(javax.ws.rs.core.MediaType mediaType, String address, List<?> providers, String jwt, TLSClientParameters tlsClientParameters)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BatchResponse
commit()
Sends the current request, with items accumulated by invoking methods on proxies obtained viagetService(java.lang.Class)
, to the Batch service, and awaits for synchronous response.BatchResponse
commit(boolean async)
Sends the current request, with items accumulated by invoking methods on proxies obtained viagetService(java.lang.Class)
, to the Batch service, and awaits for a synchronous or asynchronous response, depending on theasync
parameter.List<BatchRequestItem>
getItems()
<T> T
getService(Class<T> serviceClass)
-
-
-
Constructor Detail
-
BatchRequest
public BatchRequest(javax.ws.rs.core.MediaType mediaType, String address, List<?> providers, String jwt, TLSClientParameters tlsClientParameters)
-
-
Method Detail
-
getService
public <T> T getService(Class<T> serviceClass)
-
getItems
public List<BatchRequestItem> getItems()
-
commit
public BatchResponse commit()
Sends the current request, with items accumulated by invoking methods on proxies obtained viagetService(java.lang.Class)
, to the Batch service, and awaits for synchronous response. It also clears out the accumulated items, in case of reuse of this instance for subsequent requests.- Returns:
- batch response
-
commit
public BatchResponse commit(boolean async)
Sends the current request, with items accumulated by invoking methods on proxies obtained viagetService(java.lang.Class)
, to the Batch service, and awaits for a synchronous or asynchronous response, depending on theasync
parameter. It also clears out the accumulated items, in case of reuse of this instance for subsequent requests.- Parameters:
async
- whether asynchronous Batch process is requested, or not- Returns:
- batch response
-
-