public class SubmissionStatusService extends Object
| Constructor and Description |
|---|
SubmissionStatusService()
Initiate service
|
SubmissionStatusService(PassClient client)
Supports setting a specific client.
|
| Modifier and Type | Method and Description |
|---|---|
org.dataconservancy.pass.model.Submission.SubmissionStatus |
calculateAndUpdateSubmissionStatus(URI submissionId)
Calculates the appropriate
Submission.SubmissionStatus for the Submission.id provided. |
org.dataconservancy.pass.model.Submission.SubmissionStatus |
calculateAndUpdateSubmissionStatus(URI submissionId,
boolean overrideUIStatus)
Calculates the appropriate
Submission.SubmissionStatus for the Submission provided. |
org.dataconservancy.pass.model.Submission.SubmissionStatus |
calculateSubmissionStatus(org.dataconservancy.pass.model.Submission submission)
Calculates the appropriate
Submission.SubmissionStatus for the Submission provided. |
org.dataconservancy.pass.model.Submission.SubmissionStatus |
calculateSubmissionStatus(URI submissionId)
Calculates the appropriate
Submission.SubmissionStatus for the Submission.id provided. |
public SubmissionStatusService()
public SubmissionStatusService(PassClient client)
client - PASS clientpublic org.dataconservancy.pass.model.Submission.SubmissionStatus calculateSubmissionStatus(URI submissionId)
Submission.SubmissionStatus for the Submission.id provided.
This is based on the status of associated Deposits and RepositoryCopys for
submitted records, and the existing status (if any) and SubmissionEvents for unsubmitted records.submissionId - Submission URIpublic org.dataconservancy.pass.model.Submission.SubmissionStatus calculateSubmissionStatus(org.dataconservancy.pass.model.Submission submission)
Submission.SubmissionStatus for the Submission provided.
This is based on the status of associated Deposits and RepositoryCopys for
submitted records, and the existing status (if any) and SubmissionEvents for unsubmitted records.submission - The submissionpublic org.dataconservancy.pass.model.Submission.SubmissionStatus calculateAndUpdateSubmissionStatus(URI submissionId)
Submission.SubmissionStatus for the Submission.id provided.
This is based on the status of associated Deposits and RepositoryCopys for
submitted records, and SubmissionEvents for unsubmitted records then updates
the status as appropriate.
The UI will typically have responsibility for updating the submissionStatus before
the Submission is submitted. Therefore, by default this service will not replace
the existing status of an unsubmitted record unless the starting value was null (i.e. it has not
been populated yet). To override this constraint, and replace the value anyway, use the method
calculateAndUpdateSubmissionStatus(boolean overrideUIStatus) and supply a parameter of true
submissionId - Submission URIpublic org.dataconservancy.pass.model.Submission.SubmissionStatus calculateAndUpdateSubmissionStatus(URI submissionId, boolean overrideUIStatus)
Submission.SubmissionStatus for the Submission provided.
This is based on the status of associated Deposits and RepositoryCopys for
submitted records, and SubmissionEvents for unsubmitted records then updates
the status as appropriate.
The UI will typically have responsibility for updating the submissionStatus before
the Submission is submitted. Therefore, by default this service will not replace
the existing status of an unsubmitted record unless the starting value was null (i.e. it has not
been populated yet). To override this constraint, set the overrideUIStatus parameter to
true
submissionId - Submission URIoverrideUIStatus - - true will override the current pre-submission status on the
Submission record, regardless of whether it was set by the UI.
false will not replace the current submission value, and favor the value set by the UICopyright © 2019. All rights reserved.