public class TarArchiveSparseEntry extends java.lang.Object implements TarConstants
The C structure for a sparse entry is:
struct posix_header { struct sparse sp[21]; // TarConstants.SPARSELEN_GNU_SPARSE - offset 0 char isextended; // TarConstants.ISEXTENDEDLEN_GNU_SPARSE - offset 504 };Whereas, "struct sparse" is:
struct sparse { char offset[12]; // offset 0 char numbytes[12]; // offset 12 };
ATIMELEN_GNU, CHKSUMLEN, CTIMELEN_GNU, DEVLEN, FORMAT_OLDGNU, FORMAT_POSIX, GIDLEN, GNAMELEN, GNU_LONGLINK, GNU_TMAGIC, ISEXTENDEDLEN_GNU, ISEXTENDEDLEN_GNU_SPARSE, LF_BLK, LF_CHR, LF_CONTIG, LF_DIR, LF_FIFO, LF_GNUTYPE_LONGLINK, LF_GNUTYPE_LONGNAME, LF_GNUTYPE_SPARSE, LF_LINK, LF_NORMAL, LF_OLDNORM, LF_PAX_EXTENDED_HEADER_LC, LF_PAX_EXTENDED_HEADER_UC, LF_PAX_GLOBAL_EXTENDED_HEADER, LF_SYMLINK, LONGNAMESLEN_GNU, MAGIC_OFFSET, MAGIC_POSIX, MAGICLEN, MAXID, MAXSIZE, MODELEN, MODTIMELEN, NAMELEN, OFFSETLEN_GNU, PAD2LEN_GNU, PREFIXLEN, PURE_MAGICLEN, REALSIZELEN_GNU, SIZELEN, SPARSELEN_GNU, SPARSELEN_GNU_SPARSE, TMAGIC, UIDLEN, UNAMELEN, VERSION_GNU_SPACE, VERSION_GNU_ZERO, VERSION_OFFSET, VERSION_POSIX, VERSIONLEN
Constructor and Description |
---|
TarArchiveSparseEntry(byte[] headerBuf)
Construct an entry from an archive's header bytes.
|
Modifier and Type | Method and Description |
---|---|
boolean |
isExtended() |
public TarArchiveSparseEntry(byte[] headerBuf) throws java.io.IOException
headerBuf
- The header bytes from a tar archive entry.java.io.IOException
- on unknown format