public class KRAS2SServiceImpl extends Object implements S2SService
| Constructor and Description |
|---|
KRAS2SServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkForSubmissionStatusChange(ProposalDevelopmentDocument pdDoc,
S2sAppSubmission appSubmission)
This method checks if status on grants.gov has changed since last check
and returns the status.
|
protected S2sOpportunity |
convert2S2sOpportunity(String providerCode,
OpportunityInformationType oppInfoType)
This method convert OpportunityInformationType to OpportunityInfo
|
protected ArrayList<S2sOpportunity> |
convertToArrayList(String source,
GetOpportunityListResponse resList)
This method convert GetOpportunityListResponse to ArrayList
|
GetApplicationListResponse |
fetchApplicationListResponse(ProposalDevelopmentDocument pdDoc)
This method fetches the application list from Grants.gov for a given
proposal
|
protected boolean |
generateAndValidateForms(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
List<AttachmentData> attList,
ProposalDevelopmentDocument pdDoc) |
protected boolean |
generateAndValidateForms(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
List<AttachmentData> attList,
ProposalDevelopmentDocument pdDoc,
List<org.kuali.rice.kns.util.AuditError> auditErrors)
This method is to generate and validate the generated forms.
|
org.kuali.rice.krad.service.BusinessObjectService |
getBusinessObjectService()
Gets the businessObjectService attribute.
|
org.kuali.rice.core.api.datetime.DateTimeService |
getDateTimeService()
Gets the dateTimeService attribute.
|
protected String |
getGrantApplicationDocument(ProposalDevelopmentDocument pdDoc,
gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms)
This method populates values for
GrantApplicationDocument for a
given ProposalDevelopmentDocument |
PrintService |
getPrintService()
Gets the printService attribute.
|
protected S2SConnectorService |
getS2sConnectorService(S2sOpportunity s2sOpportunity) |
S2SFormGeneratorService |
getS2SFormGeneratorService()
Gets the s2SFormGeneratorService attribute.
|
S2SProposalValidatorService |
getS2SProposalValidatorService()
Gets the s2SProposalValidatorService attribute.
|
S2SUtilService |
getS2sUtilService()
Gets the s2sUtilService attribute.
|
S2SValidatorService |
getS2SValidatorService()
Gets the s2SValidatorService attribute.
|
String |
getStatusDetails(String ggTrackingId,
String proposalNumber)
This method is used to get the application status details.
|
List<S2sOppForms> |
parseOpportunityForms(S2sOpportunity opportunity)
This method returns the list of forms for a given opportunity
|
void |
populateAppSubmission(ProposalDevelopmentDocument pdDoc,
S2sAppSubmission appSubmission,
ApplicationInformationType ggApplication)
This method populates the
S2sAppSubmission BO with details from
ApplicationInformationType |
void |
populateSponsorProposalId(ProposalDevelopmentDocument pdDoc,
S2sAppSubmission appSubmission)
Takes the appSubmission and proposal and if a federal tracking id has been specified, will
set on both the proposal development doc and the related institutional proposal doc
if there is not a sponsor proposal id already.
|
AttachmentDataSource |
printForm(ProposalDevelopmentDocument pdDoc)
This method is used to print selected forms.
|
boolean |
refreshGrantsGov(ProposalDevelopmentDocument pdDoc)
This method checks for the status of submission for the given
ProposalDevelopmentDocument on Grants.gov |
protected void |
saveGrantsGovStatus(ProposalDevelopmentDocument pdDoc,
GetApplicationListResponse applicationListResponse)
This method fetches the status from Grants Gov and saves in case status
is modified
|
protected void |
saveSubmissionDetails(ProposalDevelopmentDocument pdDoc,
S2sAppSubmission appSubmission,
SubmitApplicationResponse response,
String grantApplicationXml,
List<S2sAppAttachments> s2sAppAttachmentList)
This method saves the submission details after successful submission of
proposal
|
List<S2sOpportunity> |
searchOpportunity(String providerCode,
String cfdaNumber,
String opportunityId,
String competitionId)
This method is to find the list of available opportunities for a given
cfda number, opportunity ID and competition ID.
|
void |
setBusinessObjectService(org.kuali.rice.krad.service.BusinessObjectService businessObjectService)
This method is to set businessObjectService
|
void |
setDateTimeService(org.kuali.rice.core.api.datetime.DateTimeService dateTimeService)
Sets the dateTimeService attribute value.
|
protected void |
setFormObject(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
org.apache.xmlbeans.XmlObject formObject)
This method is to set the formObject to MetaGrants Forms Object.
|
void |
setPrintService(PrintService printService)
Sets the printService attribute value.
|
void |
setS2SFormGeneratorService(S2SFormGeneratorService s2SFormGeneratorService)
Setter for
S2SFormGeneratorService |
void |
setS2SProposalValidatorService(S2SProposalValidatorService s2SProposalValidatorService)
Setter for
S2SProposalValidatorService |
void |
setS2SUtilService(S2SUtilService s2SUtilService)
Sets the s2sUtilService attribute value.
|
void |
setS2SValidatorService(S2SValidatorService validatorService)
Sets the s2SValidatorService attribute value.
|
protected void |
setValidationErrorMessage(List<org.kuali.rice.kns.util.AuditError> errors)
This method is to put validation errors on UI
|
boolean |
submitApplication(ProposalDevelopmentDocument pdDoc)
This method is used to submit forms to Grants.gov.
|
boolean |
validateApplication(ProposalDevelopmentDocument proposalDevelopmentDocument)
This method is used to validate application before submission.
|
boolean |
validateApplication(ProposalDevelopmentDocument proposalDevelpmentDocument,
List<org.kuali.rice.kns.util.AuditError> auditErrors)
This method is used to validate application before submission.
|
public String getStatusDetails(String ggTrackingId, String proposalNumber) throws S2SException
getStatusDetails in interface S2SServiceggTrackingId - grants gov tracking id for the application.proposalNumber - Proposal number.S2SExceptionS2SService.getStatusDetails(java.lang.String,
java.lang.String)public List<S2sOppForms> parseOpportunityForms(S2sOpportunity opportunity) throws S2SException
parseOpportunityForms in interface S2SServiceopportunity - List of S2sOppForms which are included in the
given S2sOpportunityS2SExceptionS2SService.parseOpportunityForms(org.kuali.kra.s2s.bo.S2sOpportunity)public boolean refreshGrantsGov(ProposalDevelopmentDocument pdDoc) throws S2SException
ProposalDevelopmentDocument on Grants.govrefreshGrantsGov in interface S2SServicepdDoc - for which status has to be checkedtrue if status has changed, false
otherwiseS2SExceptionS2SService.refreshGrantsGov(org.kuali.kra.proposaldevelopment.document.ProposalDevelopmentDocument)public GetApplicationListResponse fetchApplicationListResponse(ProposalDevelopmentDocument pdDoc) throws S2SException
fetchApplicationListResponse in interface S2SServicepdDoc - GetApplicationListResponseS2SExceptionprotected void saveGrantsGovStatus(ProposalDevelopmentDocument pdDoc, GetApplicationListResponse applicationListResponse) throws S2SException
pdDoc - ProposalDevelopmentDocumentappSubmission - S2sAppSubmissionapplicationListResponse - GetApplicationListResponse response from Grants GovS2SExceptionpublic boolean checkForSubmissionStatusChange(ProposalDevelopmentDocument pdDoc, S2sAppSubmission appSubmission) throws S2SException
checkForSubmissionStatusChange in interface S2SServicepdDoc - appSubmission - S2SExceptionpublic void populateAppSubmission(ProposalDevelopmentDocument pdDoc, S2sAppSubmission appSubmission, ApplicationInformationType ggApplication)
S2sAppSubmission BO with details from
ApplicationInformationTypepopulateAppSubmission in interface S2SServiceappSubmission - ggApplication - public void populateSponsorProposalId(ProposalDevelopmentDocument pdDoc, S2sAppSubmission appSubmission)
S2SServicepublic List<S2sOpportunity> searchOpportunity(String providerCode, String cfdaNumber, String opportunityId, String competitionId) throws S2SException
searchOpportunity in interface S2SServicecfdaNumber - of the opportunity.opportunityId - parameter for the opportunity.competitionId - parameter for the opportunity.S2SExceptionorg.kuali.kra.s2s.service.S2SService#searchOpportunity(java.lang.String,
java.lang.String, java.lang.String)public boolean submitApplication(ProposalDevelopmentDocument pdDoc) throws S2SException
ProposalDevelopmentDocument, validates and then submits
the formssubmitApplication in interface S2SServicepdDoc - Proposal Development Document.S2SExceptionS2SService.submitApplication(org.kuali.kra.proposaldevelopment.document.ProposalDevelopmentDocument)protected String getGrantApplicationDocument(ProposalDevelopmentDocument pdDoc, gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms) throws S2SException
GrantApplicationDocument for a
given ProposalDevelopmentDocumentpdDoc - ProposalDevelopmentDocumentforms - GrantApplicationDocument.GrantApplication.Forms generated XML formsGrantApplicationDocument populated with formsS2SExceptionprotected void saveSubmissionDetails(ProposalDevelopmentDocument pdDoc, S2sAppSubmission appSubmission, SubmitApplicationResponse response, String grantApplicationXml, List<S2sAppAttachments> s2sAppAttachmentList)
pdDoc - ProposalDevelopmentDocument that was submittedappSubmission - S2sAppSubmission submission details of proposalresponse - SubmitApplicationResponse submission response from
grants govgrantApplicationXml - String XML content of submissions2sAppAttachmentList - S2sAppAttachments attachments included in submissionpublic boolean validateApplication(ProposalDevelopmentDocument proposalDevelopmentDocument) throws S2SException
validateApplication in interface S2SServiceproposalDevelopmentDocument - Proposal Development Document.S2SExceptionS2SService.validateApplication(org.kuali.kra.proposaldevelopment.document.ProposalDevelopmentDocument)public boolean validateApplication(ProposalDevelopmentDocument proposalDevelpmentDocument, List<org.kuali.rice.kns.util.AuditError> auditErrors) throws S2SException
S2SServicevalidateApplication in interface S2SServiceproposalDevelpmentDocument - Proposal Development Document.S2SExceptionprotected boolean generateAndValidateForms(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
List<AttachmentData> attList,
ProposalDevelopmentDocument pdDoc)
throws S2SException
S2SExceptionprotected boolean generateAndValidateForms(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
List<AttachmentData> attList,
ProposalDevelopmentDocument pdDoc,
List<org.kuali.rice.kns.util.AuditError> auditErrors)
throws S2SException
forms - FormsattList - List of attachments.pdDoc - Proposal Development Document.S2SExceptionprotected void setFormObject(gov.grants.apply.system.metaGrantApplication.GrantApplicationDocument.GrantApplication.Forms forms,
org.apache.xmlbeans.XmlObject formObject)
forms - Forms object to which the grants.gov form is added.formObject - xml object representing the grants.gov form.protected void setValidationErrorMessage(List<org.kuali.rice.kns.util.AuditError> errors)
errors - List of validation errors which has to be displayed on UI.protected ArrayList<S2sOpportunity> convertToArrayList(String source, GetOpportunityListResponse resList)
resList - {GetOpportunityListResponse}protected S2sOpportunity convert2S2sOpportunity(String providerCode, OpportunityInformationType oppInfoType)
oppInfoType - {OpportunityInformationType}public void setBusinessObjectService(org.kuali.rice.krad.service.BusinessObjectService businessObjectService)
businessObjectService(BusinessObjectService) - public void setS2SFormGeneratorService(S2SFormGeneratorService s2SFormGeneratorService)
S2SFormGeneratorServices2SFormGeneratorService - public void setS2SProposalValidatorService(S2SProposalValidatorService s2SProposalValidatorService)
S2SProposalValidatorServices2SProposalValidatorService - public void setS2SUtilService(S2SUtilService s2SUtilService)
generatorUtilService - The s2sUtilService to set.public AttachmentDataSource printForm(ProposalDevelopmentDocument pdDoc) throws S2SException, PrintingException
printForm in interface S2SServicepdDoc - Proposal Development Document.S2SExceptionPrintingExceptionpublic PrintService getPrintService()
public void setPrintService(PrintService printService)
printService - The printService to set.public S2SFormGeneratorService getS2SFormGeneratorService()
public S2SProposalValidatorService getS2SProposalValidatorService()
public S2SUtilService getS2sUtilService()
public org.kuali.rice.krad.service.BusinessObjectService getBusinessObjectService()
public org.kuali.rice.core.api.datetime.DateTimeService getDateTimeService()
public void setDateTimeService(org.kuali.rice.core.api.datetime.DateTimeService dateTimeService)
dateTimeService - The dateTimeService to set.public S2SValidatorService getS2SValidatorService()
public void setS2SValidatorService(S2SValidatorService validatorService)
validatorService - The s2SValidatorService to set.protected S2SConnectorService getS2sConnectorService(S2sOpportunity s2sOpportunity)
Copyright © 2013 The Kuali Foundation. All Rights Reserved.