Package com.labs64.netlicensing.service
Class NetLicensingService
- java.lang.Object
-
- com.labs64.netlicensing.service.NetLicensingService
-
public class NetLicensingService extends Object
Provides generic requests to NetLicensing services. This class is supposed to be used by other **Service classes.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected <RES> RES
processResponse(MetaInfo[] meta, Netlicensing netlicensing, Class<RES> resultType)
Netlicensing
request(Context context, String method, String urlTemplate, javax.ws.rs.core.Form request, Map<String,Object> queryParams)
Helper method for performing request to NetLicensing API services.
-
-
-
Method Detail
-
request
public Netlicensing request(Context context, String method, String urlTemplate, javax.ws.rs.core.Form request, Map<String,Object> queryParams) throws NetLicensingException
Helper method for performing request to NetLicensing API services. Knows about context for the NetLicensing API calls, does authentication, provides error handling based on status of the response.- Parameters:
context
- context for the NetLicensing API callmethod
- the HTTP method to be used, i.e. GET, POST, DELETEurlTemplate
- the REST URL templaterequest
- The request body to be sent to the server. May be null.queryParams
- The REST query parameters values. May be null if there are no parameters.- Returns:
Netlicensing
response object- Throws:
NetLicensingException
-
processResponse
protected <RES> RES processResponse(MetaInfo[] meta, Netlicensing netlicensing, Class<RES> resultType) throws NetLicensingException
- Throws:
NetLicensingException
-
-