Package org.exoplatform.onlyoffice
Class OnlyOfficeDocumentUpdateActivityHandler
java.lang.Object
org.exoplatform.container.component.BaseComponentPlugin
org.exoplatform.services.listener.Listener<org.apache.commons.chain.Context,String>
org.exoplatform.wcm.ext.component.activity.listener.FileUpdateActivityListener
org.exoplatform.onlyoffice.OnlyOfficeDocumentUpdateActivityHandler
- All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin,org.exoplatform.services.cms.documents.DocumentUpdateActivityHandler,org.exoplatform.services.listener.ListenerBase<org.apache.commons.chain.Context,String>
public class OnlyOfficeDocumentUpdateActivityHandler
extends org.exoplatform.wcm.ext.component.activity.listener.FileUpdateActivityListener
implements org.exoplatform.services.cms.documents.DocumentUpdateActivityHandler
The listener interface for receiving documentUpdateActivity events.
The class that is interested in processing a documentUpdateActivity
event implements this interface, and the object created
with that class is registered with a component using the
component's addDocumentUpdateActivityListener method. When
the documentUpdateActivity event occurs, that object's appropriate
method is invoked.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final longThe Constant EVENT_DELAY in min.Fields inherited from class org.exoplatform.container.component.BaseComponentPlugin
desc, name -
Constructor Summary
ConstructorsConstructorDescriptionInstantiates a new document update activity listener. -
Method Summary
Modifier and TypeMethodDescriptionbooleanhandleDocumentUpdateEvent(org.exoplatform.services.listener.Event<org.apache.commons.chain.Context, String> event) protected booleanisCommentedNode(javax.jcr.Node node) Checks if a node has comment.Methods inherited from class org.exoplatform.wcm.ext.component.activity.listener.FileUpdateActivityListener
onEventMethods inherited from class org.exoplatform.container.component.BaseComponentPlugin
getDescription, getName, setDescription, setNameMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.exoplatform.services.listener.ListenerBase
getName
-
Field Details
-
EVENT_DELAY
protected static final long EVENT_DELAYThe Constant EVENT_DELAY in min.- See Also:
-
-
Constructor Details
-
OnlyOfficeDocumentUpdateActivityHandler
public OnlyOfficeDocumentUpdateActivityHandler()Instantiates a new document update activity listener.
-
-
Method Details
-
handleDocumentUpdateEvent
public boolean handleDocumentUpdateEvent(org.exoplatform.services.listener.Event<org.apache.commons.chain.Context, String> event) throws Exception- Specified by:
handleDocumentUpdateEventin interfaceorg.exoplatform.services.cms.documents.DocumentUpdateActivityHandler- Throws:
Exception
-
isCommentedNode
protected boolean isCommentedNode(javax.jcr.Node node) throws javax.jcr.RepositoryException Checks if a node has comment.- Parameters:
node- the node- Returns:
- true if the node is commented
- Throws:
javax.jcr.RepositoryException- the repository exception
-