org.apache.commons.compress.archivers.zip

Class X7875_NewUnix

  • All Implemented Interfaces:
    Serializable, Cloneable, ZipExtraField


    public class X7875_NewUnixextends Objectimplements ZipExtraField, Cloneable, Serializable
    An extra field that stores UNIX UID/GID data (owner & group ownership) for a given zip entry. We're using the field definition given in Info-Zip's source archive: zip-3.0.tar.gz/proginfo/extrafld.txt
     Local-header version: Value         Size        Description -----         ----        ----------- 0x7875        Short       tag for this extra block type ("ux") TSize         Short       total data size for this block Version       1 byte      version of this extra field, currently 1 UIDSize       1 byte      Size of UID field UID           Variable    UID for this entry (little endian) GIDSize       1 byte      Size of GID field GID           Variable    GID for this entry (little endian) Central-header version: Value         Size        Description -----         ----        ----------- 0x7855        Short       tag for this extra block type ("Ux") TSize         Short       total data size for this block (0) 
    Since:
    1.5
    See Also:
    Serialized Form
    • Constructor Detail

      • X7875_NewUnix

        public X7875_NewUnix()
        Constructor for X7875_NewUnix.
    • Method Detail

      • getUID

        public long getUID()
        Gets the UID as a long. UID is typically a 32 bit unsigned value on most UNIX systems, so we return a long to avoid integer overflow into the negatives in case values above and including 2^31 are being used.
        Returns:
        the UID value.
      • getGID

        public long getGID()
        Gets the GID as a long. GID is typically a 32 bit unsigned value on most UNIX systems, so we return a long to avoid integer overflow into the negatives in case values above and including 2^31 are being used.
        Returns:
        the GID value.
      • setUID

        public void setUID(long l)
        Sets the UID.
        Parameters:
        l - UID value to set on this extra field.
      • setGID

        public void setGID(long l)
        Sets the GID.
        Parameters:
        l - GID value to set on this extra field.
      • toString

        public String toString()
        Returns a String representation of this class useful for debugging purposes.
        Overrides:
        toString in class Object
        Returns:
        A String representation of this class useful for debugging purposes.

Copyright © 2016 The Apache Software Foundation. All rights reserved.



NOTHING
NOTHING
Add the Maven Dependecy to your project: maven dependecy for com.amazonaws : aws-java-sdk : 1.3.14