Interface IOutItemBase

All Known Subinterfaces:
IOutItem7z, IOutItemAllFormats, IOutItemBZip2, IOutItemGZip, IOutItemTar, IOutItemXz, IOutItemZip
All Known Implementing Classes:
OutItem

public interface IOutItemBase
Base interface of the archive item data interfaces: The single known implementation is OutItem. This base interface provides access to the getters and setters methods, that are shared by all archive formats.

The purpose of the archive-format-specific interfaces IOutItemXxx is to hide methods unrelated to the corresponding archive format. For example, GZip format doesn't support the attributes property and so the IOutItemGZip interface doesn't contain the corresponding getters and setters. The Zip archive format on the other hand does support the attributes property defining the methods:
Since:
9.20-2.00
Author:
Boris Brodski
  • Method Details

    • getOutArchive

      IOutArchive<?> getOutArchive()
      Return corresponding IOutArchive object.
      Returns:
      IOutArchive
    • getArchiveFormat

      ArchiveFormat getArchiveFormat()
      Return current archive format
      Returns:
      archive format
    • getIndex

      int getIndex()
      Return the index of the item being described in the new archive.
      Returns:
      the index of the item in the archive (0-based)
    • getDataSize

      Long getDataSize()
      Get property PropID.SIZE.
      Returns:
      size.
      See Also:
    • setDataSize

      void setDataSize(Long size)
      Set property PropID.SIZE.
      Parameters:
      size - see PropID.SIZE
      See Also:
    • getUpdateIsNewData

      Boolean getUpdateIsNewData()
      Get whether the archive item data (content) has changed. If isNewData is true, isNewProperties must also be true

      Note: only relevant for archive update operations!
      Returns:
      true - the archive item has new data (always true for new archives),
      false - the archive item data from the old archive can be reused.
    • setUpdateIsNewData

      void setUpdateIsNewData(Boolean updateIsNewData)
      Set whether the archive item data (content) has changed. If isNewData is true, isNewProperties must also be true.

      Note: only relevant for archive update operations!
      Parameters:
      updateIsNewData - true - the archive item has new data (always true for new archives),
      false - the archive item data from the old archive can be reused.
    • getUpdateIsNewProperties

      Boolean getUpdateIsNewProperties()
      Get whether the archive item properties have changed. If isNewData is true, isNewProperties must also be true

      Note: only relevant for archive update operations!
      Returns:
      true - the archive item has new properties (always true for new archives).
      false - the archive item properties from the old archive should be reused.
    • setUpdateIsNewProperties

      void setUpdateIsNewProperties(Boolean updateIsNewProperties)
      Set whether the archive item properties have changed. If isNewData is true, isNewProperties must also be true

      Note: only relevant for archive update operations!
      Parameters:
      updateIsNewProperties - true - the archive item has new properties (always true for new archives).
      false - the archive item properties from the old archive should be reused.
    • getUpdateOldArchiveItemIndex

      Integer getUpdateOldArchiveItemIndex()
      Get the index of the archive item in the archive being updated (old archive). Mandatory, if isNewData or isNewProperties set.

      Note: only relevant for archive update operations!
      Returns:
      corresponding index of the archive item in the old archive (starting from 0).
      -1 if both isNewData and isNewProperties are true.
    • setUpdateOldArchiveItemIndex

      void setUpdateOldArchiveItemIndex(Integer updateOldArchiveItemIndex)
      Set the index of the archive item in the archive being updated (old archive).

      Note: only relevant for archive update operations!
      Parameters:
      updateOldArchiveItemIndex - corresponding index of the archive item in the old archive (starting from 0).
      -1 if there is no corresponding archive item in the old archive or if doesn't matter (for new archives).