Class ServiceContractRestService
java.lang.Object
fr.paris.lutece.plugins.identitystore.v3.web.rs.ServiceContractRestService
- All Implemented Interfaces:
IRestService
@Path("/rest/identitystore/v3")
public class ServiceContractRestService
extends Object
implements IRestService
ServiceContractRest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.ResponsecloseServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, Integer serviceContractId, String clientCode, String authorName, String authorType, String strHeaderAppCode) Closes a service contract by specifying an end date.
The service contract is updated from the providedServiceContractDto.javax.ws.rs.core.ResponsecreateServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, String clientCode, String authorName, String authorType, String strHeaderAppCode) Creates a service contract.
The service contract is created from the providedServiceContractDto.javax.ws.rs.core.ResponsegetActiveServiceContract(String strTargetClientCode, String headerClientCode, String authorName, String authorType, String strHeaderAppCode) Get ServiceContractjavax.ws.rs.core.ResponsegetAllServiceContractList(String clientCode, String authorName, String authorType, String strHeaderAppCode) Get ServiceContract Listjavax.ws.rs.core.ResponsegetServiceContract(String clientCode, String authorName, String authorType, Integer serviceContractId, String strHeaderAppCode) Get ServiceContractjavax.ws.rs.core.ResponsegetServiceContractList(String strTargetClientCode, String headerClientCode, String authorName, String authorType, String strHeaderAppCode) Get ServiceContract Listjavax.ws.rs.core.ResponsesearchServiceContractWithMinEndDate(String strLoadDetails, String strMinEndDate, String clientCode, String authorName, String authorType, String strHeaderAppCode) Search service contractjavax.ws.rs.core.ResponseupdateServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, Integer serviceContractId, String clientCode, String authorName, String authorType, String strHeaderAppCode) Updates a service contract.
The service contract is updated from the providedServiceContractDto.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface fr.paris.lutece.plugins.identitystore.v3.web.rs.IRestService
buildJsonResponse
-
Constructor Details
-
ServiceContractRestService
public ServiceContractRestService()
-
-
Method Details
-
getAllServiceContractList
@Path("/contracts") @GET @Produces("application/json") public javax.ws.rs.core.Response getAllServiceContractList(@HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Get ServiceContract List- Parameters:
clientCode- client code- Returns:
- the ServiceContract
- Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
searchServiceContractWithMinEndDate
@Path("/contracts/search") @GET @Produces("application/json") public javax.ws.rs.core.Response searchServiceContractWithMinEndDate(@QueryParam("load_details") @DefaultValue("false") String strLoadDetails, @QueryParam("min_end_date") @DefaultValue("") String strMinEndDate, @HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Search service contract- Parameters:
clientCode- client code- Returns:
- the ServiceContract
- Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
getServiceContractList
@Path("/contracts/list/{target_client_code}") @GET @Produces("application/json") public javax.ws.rs.core.Response getServiceContractList(@PathParam("target_client_code") String strTargetClientCode, @HeaderParam("client_code") String headerClientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Get ServiceContract List- Parameters:
headerClientCode- client code- Returns:
- the ServiceContract
- Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
getActiveServiceContract
@Path("/contract/active/{target_client_code}") @GET @Produces("application/json") public javax.ws.rs.core.Response getActiveServiceContract(@PathParam("target_client_code") String strTargetClientCode, @HeaderParam("client_code") String headerClientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Get ServiceContract- Parameters:
headerClientCode- client code- Returns:
- the ServiceContract
- Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
getServiceContract
@Path("/contracts/{service_contract_id}") @GET @Produces("application/json") public javax.ws.rs.core.Response getServiceContract(@HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @PathParam("service_contract_id") Integer serviceContractId, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Get ServiceContract- Parameters:
clientCode- client codeserviceContractId- service contract ID- Returns:
- the ServiceContract
- Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
createServiceContract
@Path("/contracts") @POST @Consumes("application/json") public javax.ws.rs.core.Response createServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, @HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Creates a service contract.
The service contract is created from the providedServiceContractDto.- Parameters:
serviceContract- the service contract to createclientCode- the application code in the HTTP header- Returns:
- http 200 if creation is ok with
ServiceContractChangeResponse - Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
updateServiceContract
@PUT @Path("/contracts/{service_contract_id}") @Consumes("application/json") public javax.ws.rs.core.Response updateServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, @PathParam("service_contract_id") Integer serviceContractId, @HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Updates a service contract.
The service contract is updated from the providedServiceContractDto.- Parameters:
serviceContract- the service contract to updateserviceContractId- the service contract IDclientCode- the application code in the HTTP header- Returns:
- http 200 if creation is ok with
ServiceContractChangeResponse - Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-
closeServiceContract
@PUT @Path("/contracts/{service_contract_id}/enddate") @Consumes("application/json") public javax.ws.rs.core.Response closeServiceContract(fr.paris.lutece.plugins.identitystore.v3.web.rs.dto.contract.ServiceContractDto serviceContract, @PathParam("service_contract_id") Integer serviceContractId, @HeaderParam("client_code") String clientCode, @HeaderParam("author_name") String authorName, @HeaderParam("author_type") String authorType, @HeaderParam("application_code") @DefaultValue("") String strHeaderAppCode) throws fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException Closes a service contract by specifying an end date.
The service contract is updated from the providedServiceContractDto.- Parameters:
serviceContract- the service contract to updateserviceContractId- the service contract IDclientCode- the application code in the HTTP header- Returns:
- http 200 if creation is ok with
ServiceContractChangeResponse - Throws:
fr.paris.lutece.plugins.identitystore.web.exception.IdentityStoreException
-