Package org.nuxeo.ecm.core.rest
Class CommentService
- java.lang.Object
-
- org.nuxeo.ecm.webengine.model.impl.AbstractResource<ResourceTypeImpl>
-
- org.nuxeo.ecm.webengine.model.impl.DefaultAdapter
-
- org.nuxeo.ecm.core.rest.CommentService
-
- All Implemented Interfaces:
AdapterResource
,Resource
,Adaptable
@Deprecated public class CommentService extends DefaultAdapter
Deprecated.since 10.3, useorg.nuxeo.ecm.restapi.server.jaxrs.comment.CommentAdapter
instead.Comment Service - manages document comments.Accepts the following methods:
- POST - create a new comment
- Author:
- Bogdan Stefanescu, Sun Seng David TAN, rux allow extending the service for the possible customizations. Some atomic actions are provided with default implementation but allowed for overwriting.
-
-
Constructor Summary
Constructors Constructor Description CommentService()
Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description javax.ws.rs.core.Response
approve()
Deprecated.protected void
approveComent(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow.protected DocumentModel
createCommentDocument(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow creation of localized comment.javax.ws.rs.core.Response
deleteComment()
Deprecated.protected void
deleteComment(DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow.javax.ws.rs.core.Response
doPost(String cText)
Deprecated.static CommentManager
getCommentManager()
Deprecated.static CommentsModerationService
getCommentsModerationService()
Deprecated.protected void
publishComment(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow.javax.ws.rs.core.Response
reject()
Deprecated.protected void
rejectComment(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow.javax.ws.rs.core.Response
remove()
Deprecated.-
Methods inherited from class org.nuxeo.ecm.webengine.model.impl.DefaultAdapter
disptachAdapter, getTarget, isAdapter
-
Methods inherited from class org.nuxeo.ecm.webengine.model.impl.AbstractResource
checkGuard, dispose, getActiveAdapter, getAdapter, getContext, getFacets, getLinks, getModule, getName, getNext, getNextSegment, getPath, getPrevious, getTemplate, getTrailingPath, getType, getURL, getView, hasFacet, initialize, initialize, isInstanceOf, isRoot, newAdapter, newObject, redirect, setNext, setPrevious, setRoot, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.nuxeo.runtime.model.Adaptable
getAdapter
-
Methods inherited from interface org.nuxeo.ecm.webengine.model.Resource
checkGuard, dispose, getActiveAdapter, getContext, getFacets, getLinks, getModule, getName, getNext, getNextSegment, getPath, getPrevious, getTemplate, getTrailingPath, getType, getURL, getView, hasFacet, initialize, isInstanceOf, isRoot, newAdapter, newObject, redirect, setNext, setPrevious, setRoot
-
-
-
-
Method Detail
-
doPost
public javax.ws.rs.core.Response doPost(String cText)
Deprecated.
-
reject
public javax.ws.rs.core.Response reject()
Deprecated.
-
approve
public javax.ws.rs.core.Response approve()
Deprecated.
-
remove
public javax.ws.rs.core.Response remove()
Deprecated.
-
deleteComment
public javax.ws.rs.core.Response deleteComment()
Deprecated.
-
getCommentManager
public static CommentManager getCommentManager()
Deprecated.
-
getCommentsModerationService
public static CommentsModerationService getCommentsModerationService()
Deprecated.
-
createCommentDocument
protected DocumentModel createCommentDocument(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow creation of localized comment. Defaults to create comment in comments root.- Parameters:
session
- the core sessiontarget
- commented documentcomment
- comment itself- Returns:
- the comment created
-
publishComment
protected void publishComment(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow. Defaults to publish right away.- Parameters:
session
- the core sessiontarget
- commented documentcomment
- comment itself
-
deleteComment
protected void deleteComment(DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow. Defaults to delete right away.- Parameters:
target
- commented documentcomment
- comment itself
-
rejectComment
protected void rejectComment(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow. Defaults to reject and delete right away.- Parameters:
target
- commented documentcomment
- comment itself
-
approveComent
protected void approveComent(CoreSession session, DocumentModel target, DocumentModel comment)
Deprecated.Can be overwritten to allow workflow. Defaults to approve right away.- Parameters:
target
- commented documentcomment
- comment itself
-
-