public interface ContentReviewService
| Modifier and Type | Method and Description |
|---|---|
boolean |
allowAllContent()
Each content review implementation can either accept all files or reject unsupported file formats.
|
boolean |
allowResubmission()
Does the service support resubmissions?
|
void |
checkForReports()
Check for reports for all submitted items that don't have reports yet
|
void |
createAssignment(String siteId,
String taskId,
Map extraAsnnOpts)
This is a vendor specific method needed for some deep integrations
(such as A2) to pre provision assignments on an external content
checking system.
|
Map<String,SortedSet<String>> |
getAcceptableExtensionsToMimeTypes()
Gets a map of acceptable file extensions for this content-review service to their associated mime types (ie. ".rtf" -> ["text/rtf", "application,rtf"])
|
Map<String,SortedSet<String>> |
getAcceptableFileTypesToExtensions()
Gets a map of acceptable file types for this content-review service (as UI presentable names) to their associated file extensions (ie.
|
List<ContentReviewItem> |
getAllContentReviewItems(String siteId,
String taskId)
This is a complement to getReportList, except that it returns all
ContentReviewItems for a site and task, rather than just the ones
whose reports have been completed.
|
Map |
getAssignment(String siteId,
String taskId)
This is a vendor specific method to allow getting information about
a particular assignment in an external plagiarism checking system.
|
ContentReviewItem |
getContentReviewItemByContentId(String contentId)
This method returns all the information related with a ContentReviewItem encapsulated as a ContentReviewResult
Using this method will likely tie you to a particular Content Review implementation.
|
Date |
getDateQueued(String contextId)
The date an item was queued
|
Date |
getDateSubmitted(String contextId)
The date an item was submitted to the queue
|
String |
getEndUserLicenseAgreementLink(String userId)
Returns a hyperlink to a providers EULA, if empty, no EULA will be shown to the user
|
Instant |
getEndUserLicenseAgreementTimestamp()
Returns date for most recent EULA.
|
String |
getEndUserLicenseAgreementVersion()
Returns version for most recent EULA.
|
String |
getIconCssClassforScore(int score,
String contentId)
Get a icon URL that for a specific score
|
String |
getLocalizedStatusMessage(String messageCode)
Get a status message for a submission in the locale of the current user
|
String |
getLocalizedStatusMessage(String messageCode,
Locale locale)
Get a status message for a submission in the locale specified
|
String |
getLocalizedStatusMessage(String messageCode,
String userRef)
Get a status message for a submission in the locale of the specified user
|
default Integer |
getProviderId()
Provides a default implementation for uniquely identifying a provider
|
List<ContentReviewItem> |
getReportList(String siteId)
Get a list of reports for all tasks in a site
|
List<ContentReviewItem> |
getReportList(String siteId,
String taskId)
Get a list of reports for a task
|
String |
getReviewError(String contentId)
Deprecated.
|
String |
getReviewReport(String contentId,
String assignmentRef,
String userId)
Get the URL of the report
|
String |
getReviewReportInstructor(String contentId,
String assignmentRef,
String userId)
Get the URL for a report constructed for an Instructor
|
String |
getReviewReportRedirectUrl(String contentId,
String assignmentRef,
String userId,
boolean isInstructor)
Option for providers to decide whether they want to use redirect logic
for the report URLs.
|
String |
getReviewReportStudent(String contentId,
String assignmentRef,
String userId)
Get the URL of a report constructed for a student
|
int |
getReviewScore(String contentId,
String taskId,
String userId)
Retrieve a score for a item
|
Long |
getReviewStatus(String contentId)
Get the status of a submission
|
String |
getServiceName()
Return the Name of the Service Implementation for Display Purposes
|
Instant |
getUserEULATimestamp(String userId)
Returns date for the user's last agreement to the EULA.
|
String |
getUserEULAVersion(String userId)
Returns version for the user's last agreement to the EULA.
|
boolean |
isAcceptableContent(ContentResource resource)
Is the content resource of a type that can be accepted by the service implementation
|
boolean |
isSiteAcceptable(Site site)
Can this site make use of the content review service
|
void |
processQueue()
Proccess all pending jobs in the Queue
|
void |
queueContent(String userId,
String siteId,
String taskId,
List<ContentResource> content)
Add an item to the Queue for Submission to Turnitin
|
void |
removeFromQueue(String contentId)
Remove an item from the review Queue
|
void |
resetUserDetailsLockedItems(String userId)
Reset the Items for a specific user that where locked because of incomplete user details
|
void |
updateUserEULATimestamp(String userId)
Sets date for the user's last agreement to the EULA to current date
|
void |
webhookEvent(javax.servlet.http.HttpServletRequest request,
int providerId,
Optional<String> customParam)
Webhook event listener that can be used to get messages sent from the provider to Sakai
|
default Integer getProviderId()
Integervoid queueContent(String userId, String siteId, String taskId, List<ContentResource> content) throws QueueException
userId - if nulll current user is usedsiteId - is null current site is usedtaskId - reference to the taskcontent - list of content resources to be queuedQueueExceptionint getReviewScore(String contentId, String taskId, String userId) throws QueueException, ReportException, Exception
contentId - taskId - userId - QueueExceptionReportExceptionExceptionString getReviewReport(String contentId, String assignmentRef, String userId) throws QueueException, ReportException
contentId - assignmentRef - userId - QueueExceptionReportException - * * @deprecated since Nov 2007, use getReviewReportInstructor(String contentId) or getReviewReportInstructor(String contentId)String getReviewReportStudent(String contentId, String assignmentRef, String userId) throws QueueException, ReportException
contentId - assignmentRef - userId - QueueExceptionReportExceptionString getReviewReportInstructor(String contentId, String assignmentRef, String userId) throws QueueException, ReportException
contentId - assignmentRef - userId - QueueExceptionReportExceptionLong getReviewStatus(String contentId) throws QueueException
contentId - QueueExceptionDate getDateQueued(String contextId) throws QueueException
contextId - QueueExceptionDate getDateSubmitted(String contextId) throws QueueException, SubmissionException
contextId - QueueExceptionSubmissionExceptionvoid processQueue()
void checkForReports()
List<ContentReviewItem> getReportList(String siteId, String taskId) throws QueueException, SubmissionException, ReportException
siteId - taskId - QueueExceptionSubmissionExceptionReportExceptionList<ContentReviewItem> getReportList(String siteId) throws QueueException, SubmissionException, ReportException
siteId - QueueExceptionSubmissionExceptionReportExceptionList<ContentReviewItem> getAllContentReviewItems(String siteId, String taskId) throws QueueException, SubmissionException, ReportException
siteId - taskId - QueueExceptionSubmissionExceptionReportExceptionString getServiceName()
void resetUserDetailsLockedItems(String userId)
userId - boolean allowAllContent()
boolean isAcceptableContent(ContentResource resource)
resource - Map<String,SortedSet<String>> getAcceptableExtensionsToMimeTypes()
Map<String,SortedSet<String>> getAcceptableFileTypesToExtensions()
boolean isSiteAcceptable(Site site)
site - String getIconCssClassforScore(int score, String contentId)
score - contentId - boolean allowResubmission()
void removeFromQueue(String contentId)
contentId - String getLocalizedStatusMessage(String messageCode, String userRef)
messageCode - userRef - String getLocalizedStatusMessage(String messageCode)
messageCode - String getReviewError(String contentId)
getLocalizedStatusMessage(String)contentId - String getLocalizedStatusMessage(String messageCode, Locale locale)
messageCode - locale - Map getAssignment(String siteId, String taskId) throws SubmissionException, TransientSubmissionException
siteId - taskId - SubmissionExceptionTransientSubmissionExceptionvoid createAssignment(String siteId, String taskId, Map extraAsnnOpts) throws SubmissionException, TransientSubmissionException
siteId - taskId - extraAsnnOpts - SubmissionExceptionTransientSubmissionExceptionContentReviewItem getContentReviewItemByContentId(String contentId)
contentId - String getEndUserLicenseAgreementLink(String userId)
Instant getEndUserLicenseAgreementTimestamp()
String getEndUserLicenseAgreementVersion()
Instant getUserEULATimestamp(String userId)
userId - String getUserEULAVersion(String userId)
userId - void updateUserEULATimestamp(String userId)
userId - String getReviewReportRedirectUrl(String contentId, String assignmentRef, String userId, boolean isInstructor)
contentId - assignmentRef - userId - isInstructor - Copyright © 2003–2018 Sakai Project. All rights reserved.