Interface ExtraFieldParsingBehavior

    • Method Detail

      • createExtraField

        ZipExtraField createExtraField​(ZipShort headerId)
        Creates an instance of ZipExtraField for the given id.

        A good default implementation would be ExtraFieldUtils.createExtraField(

        headerId - the id for the extra field
        an instance of ZipExtraField, must not be null
        Throws: - if an error occurs
        java.lang.InstantiationException - if unable to instantiate the class
        java.lang.IllegalAccessException - if not allowed to instantiate the class
      • fill

        ZipExtraField fill​(ZipExtraField field,
                           byte[] data,
                           int off,
                           int len,
                           boolean local)
        Fills in the extra field data for a single extra field.

        A good default implementation would be ExtraFieldUtils.fillExtraField(, byte[], int, int, boolean).

        field - the extra field instance to fill
        data - the array of extra field data
        off - offset into data where this field's data starts
        len - the length of this field's data
        local - whether the extra field data stems from the local file header. If this is false then the data is part if the central directory header extra data.
        the filled field. Usually this is the same as field but it could be a replacement extra field as well. Must not be null.
        Throws: - if an error occurs