Package org.eclipse.cbi.common.util
Class ZipPosixPermissionFixer
- java.lang.Object
-
- org.eclipse.cbi.common.util.ZipPosixPermissionFixer
-
abstract class ZipPosixPermissionFixer extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
ZipPosixPermissionFixer.CentralDirectoryHeader
(package private) static class
ZipPosixPermissionFixer.EndOfCentralDirectory
end of central dir signature 4 bytes (0x06054b50) number of this disk 2 bytes number of the disk with the start of the central directory 2 bytes total number of entries in the central directory on this disk 2 bytes total number of entries in the central directory 2 bytes size of the central directory 4 bytes offset of start of central directory with respect to the starting disk number 4 bytes .ZIP file comment length 2 bytes .ZIP file comment (variable size)(package private) static class
ZipPosixPermissionFixer.LocalFileHeader
Local file header: local file header signature 4 bytes (0x04034b50) version needed to extract 2 bytes general purpose bit flag 2 bytes compression method 2 bytes last mod file time 2 bytes last mod file date 2 bytes crc-32 4 bytes compressed size 4 bytes uncompressed size 4 bytes file name length 2 bytes extra field length 2 bytes file name (variable size) extra field (variable size)(package private) static class
ZipPosixPermissionFixer.Zip64EndOfCentralDirectory
Zip64 end of central directory record zip64 end of central dir signature 4 bytes (0x06064b50) size of zip64 end of central directory record 8 bytes version made by 2 bytes version needed to extract 2 bytes number of this disk 4 bytes number of the disk with the start of the central directory 4 bytes total number of entries in the central directory on this disk 8 bytes total number of entries in the central directory 8 bytes size of the central directory 8 bytes offset of start of central directory with respect to the starting disk number 8 bytes zip64 extensible data sector (variable size)(package private) static class
ZipPosixPermissionFixer.Zip64EndOfCentralDirectoryLocator
zip64 end of central dir locator signature 4 bytes (0x07064b50) number of the disk with the start of the zip64 end of central directory 4 bytes relative offset of the zip64 end of central directory record 8 bytes total number of disks 4 bytes(package private) static class
ZipPosixPermissionFixer.ZipReader
-
Field Summary
Fields Modifier and Type Field Description private ZipPosixPermissionFixer.ZipReader
zipReader
-
Constructor Summary
Constructors Constructor Description ZipPosixPermissionFixer(ZipPosixPermissionFixer.ZipReader zipReader)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description private ZipPosixPermissionFixer.EndOfCentralDirectory
findEndOfCentralDirectory()
private long
firstCentralDirectoryHeaderPosition()
private long
firstDirectoryHeaderPositionZ64(ZipPosixPermissionFixer.EndOfCentralDirectory eocdrp)
void
fixEntries()
protected abstract void
fixEntry(java.lang.String entryName, java.util.Set<java.nio.file.attribute.PosixFilePermission> posixPermissions)
-
-
-
Field Detail
-
zipReader
private final ZipPosixPermissionFixer.ZipReader zipReader
-
-
Constructor Detail
-
ZipPosixPermissionFixer
public ZipPosixPermissionFixer(ZipPosixPermissionFixer.ZipReader zipReader)
-
-
Method Detail
-
fixEntries
public void fixEntries() throws java.io.IOException
- Throws:
java.io.IOException
-
fixEntry
protected abstract void fixEntry(java.lang.String entryName, java.util.Set<java.nio.file.attribute.PosixFilePermission> posixPermissions) throws java.io.IOException
- Throws:
java.io.IOException
-
firstCentralDirectoryHeaderPosition
private long firstCentralDirectoryHeaderPosition() throws java.io.IOException
- Throws:
java.io.IOException
-
firstDirectoryHeaderPositionZ64
private long firstDirectoryHeaderPositionZ64(ZipPosixPermissionFixer.EndOfCentralDirectory eocdrp) throws java.io.IOException, java.util.zip.ZipException
- Throws:
java.io.IOException
java.util.zip.ZipException
-
findEndOfCentralDirectory
private ZipPosixPermissionFixer.EndOfCentralDirectory findEndOfCentralDirectory() throws java.io.IOException
- Throws:
java.io.IOException
-
-