com.threerings.jpkg.ar
Interface ArchiveEntry

All Known Implementing Classes:
ArchiveStringEntry, ControlFile, PackageTarFile

public interface ArchiveEntry

An object which represents data which can be added to an Archive.


Method Summary
 int getGroupId()
          Returns the group id which will own this entry in the archive.
 InputStream getInputStream()
          Returns an InputStream from the data contained in this entry.
 int getMode()
          Returns the file permissions mode (e.g.
 String getPath()
          Returns the path name used to identify this entry in the archive.
 long getSize()
          Returns the size of the data contained in this entry in bytes.
 int getUserId()
          Returns the user id which will own this entry in the archive.
 

Method Detail

getInputStream

InputStream getInputStream()
                           throws IOException
Returns an InputStream from the data contained in this entry.

Throws:
IOException

getSize

long getSize()
Returns the size of the data contained in this entry in bytes. An Archive can only store data whose size can be expressed in a 32 bit integer however the interface allows size to be expressed as a long to support for example File objects. The Archive class will guarantee that the size returned by this method can be converted safely into a 32 bit integer.


getPath

String getPath()
Returns the path name used to identify this entry in the archive. Must be 15 characters or less.


getUserId

int getUserId()
Returns the user id which will own this entry in the archive.


getGroupId

int getGroupId()
Returns the group id which will own this entry in the archive.


getMode

int getMode()
Returns the file permissions mode (e.g. 0644) for this entry in the archive.



Copyright © 2007-2008 Three Rings Design, Inc. All Rights Reserved. Released under a BSD license.