com.atlassian.confluence.event.listeners
Class ThumbnailRemovingListener

java.lang.Object
  extended by com.atlassian.confluence.event.listeners.ThumbnailRemovingListener
All Implemented Interfaces:
org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean

public class ThumbnailRemovingListener
extends Object
implements org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean

Removes thumbnails when an attachment is removed or updated. In the case of an update, this allows a new thumbnail to be generated to reflect the latest version.


Constructor Summary
ThumbnailRemovingListener(ThumbnailManager thumbnailManager, AttachmentManager attachmentManager, com.atlassian.event.api.EventPublisher eventPublisher)
           
 
Method Summary
 void afterPropertiesSet()
           
 void destroy()
           
 void handleAttachmentRemoveEvent(AttachmentRemoveEvent event)
           
 void handleAttachmentUpdateEvent(AttachmentUpdateEvent event)
           
 void handleAttachmentVersionRemoveEvent(AttachmentVersionRemoveEvent event)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThumbnailRemovingListener

public ThumbnailRemovingListener(ThumbnailManager thumbnailManager,
                                 @Qualifier(value="attachmentManager")
                                 AttachmentManager attachmentManager,
                                 com.atlassian.event.api.EventPublisher eventPublisher)
Method Detail

handleAttachmentUpdateEvent

@EventListener
public void handleAttachmentUpdateEvent(AttachmentUpdateEvent event)

handleAttachmentRemoveEvent

@EventListener
public void handleAttachmentRemoveEvent(AttachmentRemoveEvent event)

handleAttachmentVersionRemoveEvent

@EventListener
public void handleAttachmentVersionRemoveEvent(AttachmentVersionRemoveEvent event)

destroy

public void destroy()
             throws Exception
Specified by:
destroy in interface org.springframework.beans.factory.DisposableBean
Throws:
Exception

afterPropertiesSet

public void afterPropertiesSet()
                        throws Exception
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Throws:
Exception


Copyright © 2003–2015 Atlassian. All rights reserved.