@Deprecated public class

AttachmentZipKit

extends Object
java.lang.Object
   ↳ com.atlassian.jira.issue.attachment.AttachmentZipKit

This class is deprecated.
Use AttachmentIndexManager instead. Since v6.4.

Class Overview

This class will help when working with zip files

Summary

Nested Classes
interface AttachmentZipKit.AttachmentZipEntries This interface is deprecated. Use AttachmentIndexManager instead. Since v6.4.  
interface AttachmentZipKit.AttachmentZipEntry This interface is deprecated. Use AttachmentIndexManager instead. Since v6.4.  
enum AttachmentZipKit.FileCriteria This enum is deprecated. Use AttachmentIndexManager instead. Since v6.4.  
class AttachmentZipKit.ZipEntryInputStream  
Public Constructors
AttachmentZipKit()
Public Methods
@Deprecated AttachmentZipKit.ZipEntryInputStream extractFile(File zipFile, long entryIndex)
This method is deprecated. Use getAttachmentContents(Attachment, com.atlassian.jira.issue.Issue, int) instead. Since v6.4.
@Deprecated boolean isZip(File file)
This method is deprecated. Use isExpandable(Attachment) instead. Since v6.4.
@Deprecated AttachmentZipKit.AttachmentZipEntries listEntries(File zipFile, int maxEntries, AttachmentZipKit.FileCriteria criteria)
This method is deprecated. Use AttachmentIndexManager instead. Since v6.4.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public AttachmentZipKit ()

Public Methods

@Deprecated public AttachmentZipKit.ZipEntryInputStream extractFile (File zipFile, long entryIndex)

This method is deprecated.
Use getAttachmentContents(Attachment, com.atlassian.jira.issue.Issue, int) instead. Since v6.4.

This will extract an java.io.OutputStream of the contents of the file at entryIndex within the zip file. If no file can be found be at that entryIndex or the entry is a directory then null will be returned.

Parameters
zipFile the zip file in play
entryIndex the entryIndex of the entry to return
Returns
Throws
IOException if things go wrong during reading

@Deprecated public boolean isZip (File file)

This method is deprecated.
Use isExpandable(Attachment) instead. Since v6.4.

This will return true if the file is in fact a valid zip file.

Parameters
file the file in play.
Returns
  • true if its actually a readable zip file.

@Deprecated public AttachmentZipKit.AttachmentZipEntries listEntries (File zipFile, int maxEntries, AttachmentZipKit.FileCriteria criteria)

This method is deprecated.
Use AttachmentIndexManager instead. Since v6.4.

This will return a list of AttachmentZipKit.AttachmentZipEntrys for a given zip file

Parameters
zipFile the ZIP file in play
maxEntries the maximum number of entries to put in th list. If this is -negative then not maximum is used.
criteria the criteria of which entries to return
Returns
  • a list of entries
Throws
IOException if the file cant be read or is not a zip. file.