Interface ReviewManagementService
-
- All Known Implementing Classes:
ReviewManagementServiceImpl
public interface ReviewManagementServiceInterface used by Review and Commenting.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidbeginReview(java.lang.String reviewName, java.lang.String reviewDescription, java.lang.String deadline, java.lang.String[] reviewers, java.lang.String assetPath)Starts the review.voidcleanReview(java.lang.String assetPath, javax.jcr.Session session, boolean updateReviewProperties)Cleans the review.voidendReview(java.lang.String assetPath)Ends the review.java.util.Map<java.lang.String,java.lang.String>fetchReviewInfo(ResourceResolver resourceResolver, java.lang.String assetPath)Returns all the information related to the ongoing review on the asset.ResourceResolvergetFnDServiceUserResourceResolver()This function returns the resource resolver for fd-service system user.booleanisUnderReview(ResourceResolver resourceResolver, java.lang.String assetPath)Checks if the asset is currently under review or notvoidupdateReview(java.lang.String assetPath, java.lang.String reviewDescription, java.lang.String deadline, java.lang.String[] reviewers)Updates the review.
-
-
-
Method Detail
-
fetchReviewInfo
java.util.Map<java.lang.String,java.lang.String> fetchReviewInfo(ResourceResolver resourceResolver, java.lang.String assetPath) throws FormsMgrException
Returns all the information related to the ongoing review on the asset.- Parameters:
resourceResolver-assetPath- Path to the node of the asset.- Returns:
- Map with keys being the attributes (for example reviewName, reviewInitiator, reviewDescription, reviewProjectName, reviewGroup, reviewDeadline, underReview) of the review and their respective values.
- Throws:
FormsMgrException
-
isUnderReview
boolean isUnderReview(ResourceResolver resourceResolver, java.lang.String assetPath) throws FormsNDocumentsException
Checks if the asset is currently under review or not- Parameters:
resourceResolver-assetPath- Asset to be checked if under review or not- Returns:
- true if the asset is under review else returns false
- Throws:
FormsNDocumentsException
-
beginReview
void beginReview(java.lang.String reviewName, java.lang.String reviewDescription, java.lang.String deadline, java.lang.String[] reviewers, java.lang.String assetPath) throws FormsMgrExceptionStarts the review. This method is responsible for creating and assigning appropriate tasks for the reviewers.- Parameters:
reviewName- Name of the review.reviewDescription- Description of the review.deadline- Deadline of the review.reviewers- Array of reviewers.assetPath- Asset to start review on.- Throws:
FormsMgrException
-
endReview
void endReview(java.lang.String assetPath) throws FormsMgrExceptionEnds the review. This method is responsible for completing the review, that is it terminates all the active tasks assigned to the reviewers.- Parameters:
assetPath- Asset on which the review needs to be ended.- Throws:
FormsMgrException
-
updateReview
void updateReview(java.lang.String assetPath, java.lang.String reviewDescription, java.lang.String deadline, java.lang.String[] reviewers) throws FormsMgrExceptionUpdates the review. This method is responsible for updation of deadline, addition and removal of reviewers as per the new list of reviewers provided.- Parameters:
assetPath- Asset on which the review needs to be updated.reviewDescription- Description of the review.deadline- New deadline of the review.reviewers- New array of reviewers.- Throws:
FormsMgrException
-
cleanReview
void cleanReview(java.lang.String assetPath, javax.jcr.Session session, boolean updateReviewProperties) throws FormsMgrExceptionCleans the review. This method is responsible for clearing any left out or corrupted state.- Parameters:
assetPath- Asset on which the review needs to be ended.session- Session of initiator.updateReviewProperties- Whether review properties need to be updated in clean review call- Throws:
FormsMgrException
-
getFnDServiceUserResourceResolver
ResourceResolver getFnDServiceUserResourceResolver()
This function returns the resource resolver for fd-service system user.- Returns:
- fnd-service system user resource resolver
-
-