com.atlassian.jira.issue.attachment
Class WithDirectoryAccessorThumbnailAccessor

java.lang.Object
  extended by com.atlassian.jira.issue.attachment.WithDirectoryAccessorThumbnailAccessor
All Implemented Interfaces:
ThumbnailAccessor
Direct Known Subclasses:
FileSystemThumbnailAccessor

public abstract class WithDirectoryAccessorThumbnailAccessor
extends Object
implements ThumbnailAccessor


Constructor Summary
WithDirectoryAccessorThumbnailAccessor(AttachmentDirectoryAccessor ada)
           
 
Method Summary
 com.atlassian.util.concurrent.Promise<Void> deleteThumbnailDirectory(Issue issue)
          Deletes the thumbnail directory for a given issue, deleting its contents if necessary.
protected  AttachmentDirectoryAccessor getAttachmentDirectoryAccessor()
           
 File getThumbnailDirectory(Issue issue)
          Returns the physical directory of the thumbnails for the given issue, creating if necessary.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.jira.issue.attachment.ThumbnailAccessor
getLegacyThumbnailFile, getThumbnailFile, getThumbnailFile
 

Constructor Detail

WithDirectoryAccessorThumbnailAccessor

public WithDirectoryAccessorThumbnailAccessor(AttachmentDirectoryAccessor ada)
Method Detail

getThumbnailDirectory

@Nonnull
public final File getThumbnailDirectory(@Nonnull
                                                Issue issue)
Description copied from interface: ThumbnailAccessor
Returns the physical directory of the thumbnails for the given issue, creating if necessary.

Specified by:
getThumbnailDirectory in interface ThumbnailAccessor
Parameters:
issue - the issue whose thumbnail directory you want
Returns:
The issue's thumbnail directory.

deleteThumbnailDirectory

public com.atlassian.util.concurrent.Promise<Void> deleteThumbnailDirectory(@Nonnull
                                                                            Issue issue)
Description copied from interface: ThumbnailAccessor
Deletes the thumbnail directory for a given issue, deleting its contents if necessary.

Specified by:
deleteThumbnailDirectory in interface ThumbnailAccessor
Parameters:
issue - The issue whose thumbnail directory you want to delete.
Returns:
A promise that contains a AttachmentCleanupException if there was an error deleting the directory.

getAttachmentDirectoryAccessor

protected final AttachmentDirectoryAccessor getAttachmentDirectoryAccessor()


Copyright © 2002-2014 Atlassian. All Rights Reserved.