Package org.mycore.common.events
Class MCREventHandlerBase
java.lang.Object
org.mycore.common.events.MCREventHandlerBase
- All Implemented Interfaces:
MCREventHandler
- Direct Known Subclasses:
MCRAccessCacheEventHandler
,MCRAccessEventHandler
,MCRAccessKeyEventHandler
,MCRClassificationMappingEventHandler
,MCRClassificationMappingEventHandler
,MCRDerivateDefaultClassEventHandler
,MCRExtractRelatedItemsEventHandler
,MCRFileMetaEventHandler
,MCRImageTileEventHandler
,MCRJanitorEventHandlerBase
,MCRLinkTableEventHandler
,MCRMailEventHandler
,MCRMaindocEventHandler
,MCRMetadataHistoryManager
,MCRMODSLinksEventHandler
,MCRObjectCacheFactory
,MCRObjectInfoEventHandler
,MCRPersistTransientUserEventHandler
,MCRPICreationEventHandler
,MCRRemoveAclEventHandler
,MCRServiceFlagEventHandler
,MCRSolrIndexEventHandler
,MCRStaticContentEventHandler
,MCRThumbnailForPdfEventHandler
,MCRUpdateMetsOnDerivateChangeEventHandler
,MCRWorkEventHandler
,MCRXMLMetadataEventHandler
Abstract helper class that can be subclassed to implement event handlers more
easily.
- Author:
- Frank Lützenkirchen, Jens Kupferschmidt
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
doHandleEvent
(MCREvent evt) This method handle all calls for EventHandler for the event types MCRObject, MCRDerivate and MCRFile.void
This method does nothing.protected void
handleClassificationCreated
(MCREvent evt, MCRCategory obj) Handles classification created events.protected void
handleClassificationDeleted
(MCREvent evt, MCRCategory obj) Handles classification deleted events.protected void
handleClassificationRepaired
(MCREvent evt, MCRCategory obj) Handles classification repair events.protected void
handleClassificationUpdated
(MCREvent evt, MCRCategory obj) Handles classification updated events.protected void
handleDerivateCreated
(MCREvent evt, MCRDerivate der) Handles derivate created events.protected void
handleDerivateDeleted
(MCREvent evt, MCRDerivate der) Handles derivate deleted events.protected void
handleDerivateRepaired
(MCREvent evt, MCRDerivate der) Handles derivate repair events.protected void
handleDerivateUpdated
(MCREvent evt, MCRDerivate der) Handles derivate updated events.protected void
handleObjectCreated
(MCREvent evt, MCRObject obj) Handles object created events.protected void
handleObjectDeleted
(MCREvent evt, MCRObject obj) Handles object deleted events.protected void
handleObjectIndex
(MCREvent evt, MCRObject obj) protected void
handleObjectRepaired
(MCREvent evt, MCRObject obj) Handles object repair events.protected void
handleObjectUpdated
(MCREvent evt, MCRObject obj) Handles object updated events.protected void
handlePathCreated
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
handlePathDeleted
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
handlePathRepaired
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
handlePathUpdated
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
undoClassificationCreated
(MCREvent evt, MCRCategory obj) Handles undo of classification created events.protected void
undoClassificationDeleted
(MCREvent evt, MCRCategory obj) Handles undo of classification deleted events.protected void
undoClassificationRepaired
(MCREvent evt, MCRCategory obj) Handles undo of classification repaired events.protected void
undoClassificationUpdated
(MCREvent evt, MCRCategory obj) Handles undo of classification updated events.protected void
undoDerivateCreated
(MCREvent evt, MCRDerivate der) Handles undo of derivate created events.protected void
undoDerivateDeleted
(MCREvent evt, MCRDerivate der) Handles undo of derivate deleted events.protected void
undoDerivateRepaired
(MCREvent evt, MCRDerivate der) Handles undo of derivate repaired events.protected void
undoDerivateUpdated
(MCREvent evt, MCRDerivate der) Handles undo of derivate updated events.void
undoHandleEvent
(MCREvent evt) This method roll back all calls for EventHandler for the event types MCRObject, MCRDerivate and MCRFile.protected void
undoObjectCreated
(MCREvent evt, MCRObject obj) Handles undo of object created events.protected void
undoObjectDeleted
(MCREvent evt, MCRObject obj) Handles undo of object deleted events.protected void
undoObjectRepaired
(MCREvent evt, MCRObject obj) Handles undo of object repaired events.protected void
undoObjectUpdated
(MCREvent evt, MCRObject obj) Handles undo of object updated events.protected void
undoPathCreated
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
undoPathDeleted
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
undoPathRepaired
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
undoPathUpdated
(MCREvent evt, Path path, BasicFileAttributes attrs) protected void
updateDerivateFileIndex
(MCREvent evt, MCRDerivate file) Updates the index content of the given file.protected void
updatePathIndex
(MCREvent evt, Path path, BasicFileAttributes attrs)
-
Constructor Details
-
MCREventHandlerBase
public MCREventHandlerBase()
-
-
Method Details
-
doHandleEvent
This method handle all calls for EventHandler for the event types MCRObject, MCRDerivate and MCRFile.- Specified by:
doHandleEvent
in interfaceMCREventHandler
- Parameters:
evt
- The MCREvent object
-
undoHandleEvent
This method roll back all calls for EventHandler for the event types MCRObject, MCRDerivate and MCRFile.- Specified by:
undoHandleEvent
in interfaceMCREventHandler
- Parameters:
evt
- The MCREvent object
-
doNothing
This method does nothing. It is very useful for debugging events. -
handleClassificationCreated
Handles classification created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
handleClassificationUpdated
Handles classification updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
handleClassificationDeleted
Handles classification deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
handleClassificationRepaired
Handles classification repair events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
handleObjectCreated
Handles object created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
handleObjectUpdated
Handles object updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
handleObjectDeleted
Handles object deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
handleObjectRepaired
Handles object repair events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
handleObjectIndex
-
handleDerivateCreated
Handles derivate created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
handleDerivateUpdated
Handles derivate updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
handleDerivateDeleted
Handles derivate deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
handleDerivateRepaired
Handles derivate repair events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
handlePathUpdated
-
handlePathDeleted
-
handlePathRepaired
-
updatePathIndex
-
handlePathCreated
-
undoClassificationCreated
Handles undo of classification created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
undoClassificationUpdated
Handles undo of classification updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
undoClassificationDeleted
Handles undo of classification deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
undoClassificationRepaired
Handles undo of classification repaired events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRClassification that caused the event
-
undoObjectCreated
Handles undo of object created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
undoObjectUpdated
Handles undo of object updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
undoObjectDeleted
Handles undo of object deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
undoObjectRepaired
Handles undo of object repaired events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredobj
- the MCRObject that caused the event
-
undoDerivateCreated
Handles undo of derivate created events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
undoDerivateUpdated
Handles undo of derivate updated events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
undoDerivateDeleted
Handles undo of derivate deleted events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
undoDerivateRepaired
Handles undo of derivate repaired events. This implementation does nothing and should be overwritted by subclasses.- Parameters:
evt
- the event that occuredder
- the MCRDerivate that caused the event
-
undoPathCreated
-
undoPathUpdated
-
undoPathDeleted
-
undoPathRepaired
-
updateDerivateFileIndex
Updates the index content of the given file.
-