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
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addEnquiry(EnquiryForm form)
Add a new enquiry form.List<EnquiryForm>
getAvailableEnquires(EntityParam entityParam, EnquirySelector selector)
Allows to get enquiries according to the given filter.List<EnquiryForm>
getEnquires()
EnquiryForm
getEnquiry(String id)
EnquiryResponseState
getEnquiryResponse(String requestId)
List<EnquiryResponseState>
getEnquiryResponses()
Lists all responsesFormAutomationSupport
getFormAutomationSupport(EnquiryForm form)
boolean
hasForm(String id)
void
ignoreEnquiry(String enquiryId, EntityParam entity)
Marks an enquiry as ignored for the given user.void
processEnquiryResponse(String id, EnquiryResponse finalResponse, 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
removeEnquiryWithoutDependencyChecking(String formId)
Remove an existing enquiry form with no dependency checkingvoid
removePendingStickyRequest(String form, EntityParam entity)
void
sendEnquiry(String enquiryId)
Triggers a (re?)send of enquiry notification message.String
submitEnquiryResponse(EnquiryResponse response, RegistrationContext context)
Submits an enquiry response.void
updateEnquiry(EnquiryForm updatedForm, boolean ignoreRequestsAndInvitations)
Updates an existing enquiry form.
-
-
-
Method Detail
-
addEnquiry
void addEnquiry(EnquiryForm form) throws EngineException
Add a new enquiry form.- Parameters:
form
-- Throws:
EngineException
-
sendEnquiry
void sendEnquiry(String enquiryId) throws EngineException
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:
EngineException
-
removeEnquiry
void removeEnquiry(String formId, boolean dropRequests) throws 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:
EngineException
-
updateEnquiry
void updateEnquiry(EnquiryForm updatedForm, boolean ignoreRequestsAndInvitations) throws 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:
EngineException
-
processEnquiryResponse
void processEnquiryResponse(String id, EnquiryResponse finalResponse, RegistrationRequestAction action, String publicComment, String privateComment) throws 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:
EngineException
-
getEnquires
List<EnquiryForm> getEnquires() throws EngineException
- Returns:
- all available enquires.
- Throws:
EngineException
-
getEnquiry
EnquiryForm getEnquiry(String id) throws EngineException
- Returns:
- enquiry form with given id.
- Throws:
EngineException
-
hasForm
boolean hasForm(String id)
-
ignoreEnquiry
void ignoreEnquiry(String enquiryId, EntityParam entity) throws EngineException
Marks an enquiry as ignored for the given user. This is only possible for enquires which are not mandatory to be filled.- Throws:
EngineException
-
submitEnquiryResponse
String submitEnquiryResponse(EnquiryResponse response, RegistrationContext context) throws EngineException
Submits an enquiry response.- Throws:
EngineException
-
getEnquiryResponses
List<EnquiryResponseState> getEnquiryResponses() throws EngineException
Lists all responses- Throws:
EngineException
-
getEnquiryResponse
EnquiryResponseState getEnquiryResponse(String requestId)
- Returns:
- a specific enquiry response
-
getFormAutomationSupport
FormAutomationSupport getFormAutomationSupport(EnquiryForm form)
- Returns:
- form automation support for a given form
-
removePendingStickyRequest
void removePendingStickyRequest(String form, EntityParam entity) throws EngineException
- Throws:
EngineException
-
removeEnquiryWithoutDependencyChecking
void removeEnquiryWithoutDependencyChecking(String formId) throws EngineException
Remove an existing enquiry form with no dependency checking- Throws:
EngineException
-
getAvailableEnquires
List<EnquiryForm> getAvailableEnquires(EntityParam entityParam, EnquirySelector selector) throws EngineException
Allows to get enquiries according to the given filter.- Parameters:
selector
- filter what should be retrieved- Throws:
EngineException
-
-