Package pl.edu.icm.unity.engine.api
Interface EnquiryManagement
public interface EnquiryManagement
Enquires support: forms, submissions of requests and their processing.
- Author:
- K. Benedyczak
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addEnquiry
(pl.edu.icm.unity.base.registration.EnquiryForm form) Add a new enquiry form.List<pl.edu.icm.unity.base.registration.EnquiryForm>
getAvailableEnquires
(pl.edu.icm.unity.base.entity.EntityParam entityParam, EnquirySelector selector) Allows to get enquiries according to the given filter.List<pl.edu.icm.unity.base.registration.EnquiryForm>
pl.edu.icm.unity.base.registration.EnquiryForm
getEnquiry
(String id) pl.edu.icm.unity.base.registration.EnquiryResponseState
getEnquiryResponse
(String requestId) List<pl.edu.icm.unity.base.registration.EnquiryResponseState>
Lists all responsesgetFormAutomationSupport
(pl.edu.icm.unity.base.registration.EnquiryForm form) boolean
void
ignoreEnquiry
(String enquiryId, pl.edu.icm.unity.base.entity.EntityParam entity) Marks an enquiry as ignored for the given user.void
processEnquiryResponse
(String id, pl.edu.icm.unity.base.registration.EnquiryResponse finalResponse, pl.edu.icm.unity.base.registration.RegistrationRequestAction action, String publicComment, String privateComment) Accepts, deletes or rejects a given enquiry response.void
removeEnquiry
(String formId, boolean dropRequests) Remove an existing enquiry form.void
Remove an existing enquiry form with no dependency checkingvoid
removePendingStickyRequest
(String form, pl.edu.icm.unity.base.entity.EntityParam entity) void
sendEnquiry
(String enquiryId) Triggers a (re?)send of enquiry notification message.submitEnquiryResponse
(pl.edu.icm.unity.base.registration.EnquiryResponse response, pl.edu.icm.unity.base.registration.RegistrationContext context) Submits an enquiry response.void
updateEnquiry
(pl.edu.icm.unity.base.registration.EnquiryForm updatedForm, boolean ignoreRequestsAndInvitations) Updates an existing enquiry form.
-
Method Details
-
addEnquiry
void addEnquiry(pl.edu.icm.unity.base.registration.EnquiryForm form) throws pl.edu.icm.unity.base.exceptions.EngineException Add a new enquiry form.- Parameters:
form
-- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
sendEnquiry
Triggers a (re?)send of enquiry notification message. The message will be send only for those who has not yet filled the enquiry.- Parameters:
enquiryId
-- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
removeEnquiry
void removeEnquiry(String formId, boolean dropRequests) throws pl.edu.icm.unity.base.exceptions.EngineException Remove an existing enquiry form.- Parameters:
formId
-dropRequests
- if true then all requests of this form are deleted. If false, the operation will throw exception if there are any requests for the form.- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
updateEnquiry
void updateEnquiry(pl.edu.icm.unity.base.registration.EnquiryForm updatedForm, boolean ignoreRequestsAndInvitations) throws pl.edu.icm.unity.base.exceptions.EngineException Updates an existing enquiry form. Will be applicable only to those users who has not yet filled the original enquiry.- Parameters:
updatedForm
-ignoreRequestsAndInvitations
- if true then operation will ignore form requests and invitations. If false then it will fail if there are any pending requests of the form.- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
processEnquiryResponse
void processEnquiryResponse(String id, pl.edu.icm.unity.base.registration.EnquiryResponse finalResponse, pl.edu.icm.unity.base.registration.RegistrationRequestAction action, String publicComment, String privateComment) throws pl.edu.icm.unity.base.exceptions.EngineException Accepts, deletes or rejects a given enquiry response. The request can be freely modified at this time too, with one exception: the credentials originally submitted are always preserved.- Parameters:
id
- request id to be processedfinalRequest
- updated request with edits made by adminaction
- what to do with the request.publicComment
- comment to be recorded and sent to the requesterprivateComment
- comment to be internally recored only.- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getEnquires
List<pl.edu.icm.unity.base.registration.EnquiryForm> getEnquires() throws pl.edu.icm.unity.base.exceptions.EngineException- Returns:
- all available enquires.
- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getEnquiry
pl.edu.icm.unity.base.registration.EnquiryForm getEnquiry(String id) throws pl.edu.icm.unity.base.exceptions.EngineException - Returns:
- enquiry form with given id.
- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
hasForm
-
ignoreEnquiry
void ignoreEnquiry(String enquiryId, pl.edu.icm.unity.base.entity.EntityParam entity) throws pl.edu.icm.unity.base.exceptions.EngineException Marks an enquiry as ignored for the given user. This is only possible for enquires which are not mandatory to be filled.- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
submitEnquiryResponse
String submitEnquiryResponse(pl.edu.icm.unity.base.registration.EnquiryResponse response, pl.edu.icm.unity.base.registration.RegistrationContext context) throws pl.edu.icm.unity.base.exceptions.EngineException Submits an enquiry response.- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getEnquiryResponses
List<pl.edu.icm.unity.base.registration.EnquiryResponseState> getEnquiryResponses() throws pl.edu.icm.unity.base.exceptions.EngineExceptionLists all responses- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getEnquiryResponse
- Returns:
- a specific enquiry response
-
getFormAutomationSupport
- Returns:
- form automation support for a given form
-
removePendingStickyRequest
void removePendingStickyRequest(String form, pl.edu.icm.unity.base.entity.EntityParam entity) throws pl.edu.icm.unity.base.exceptions.EngineException - Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
removeEnquiryWithoutDependencyChecking
void removeEnquiryWithoutDependencyChecking(String formId) throws pl.edu.icm.unity.base.exceptions.EngineException Remove an existing enquiry form with no dependency checking- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getAvailableEnquires
List<pl.edu.icm.unity.base.registration.EnquiryForm> getAvailableEnquires(pl.edu.icm.unity.base.entity.EntityParam entityParam, EnquirySelector selector) throws pl.edu.icm.unity.base.exceptions.EngineException Allows to get enquiries according to the given filter.- Parameters:
selector
- filter what should be retrieved- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-