Class SevenZipCipher

  • All Implemented Interfaces:
    com.aspose.ms.System.IDisposable, com.aspose.ms.System.Security.Cryptography.ICryptoTransform

    public abstract class SevenZipCipher
    extends Object
    implements com.aspose.ms.System.Security.Cryptography.ICryptoTransform

    Base class for AES cipher used for 7-zip encryption.

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      abstract boolean canReuseTransform()
      Gets a value indicating whether the current transform can be reused.
      abstract boolean canTransformMultipleBlocks()
      Gets a value indicating whether multiple blocks can be transformed.
      abstract void dispose()
      Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
      abstract int getInputBlockSize()
      Gets the input block size.
      abstract int getOutputBlockSize()
      Gets the output block size.
      abstract int transformBlock​(byte[] inputBuffer, int inputOffset, int inputCount, byte[] outputBuffer, int outputOffset)
      Transforms the specified region of the input byte array and copies the resulting transform to the specified region of the output byte array.
      abstract byte[] transformFinalBlock​(byte[] inputBuffer, int inputOffset, int inputCount)
      Transforms the specified region of the specified byte array.
    • Method Detail

      • dispose

        public abstract void dispose()

        Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

        Specified by:
        dispose in interface com.aspose.ms.System.IDisposable
      • transformBlock

        public abstract int transformBlock​(byte[] inputBuffer,
                                           int inputOffset,
                                           int inputCount,
                                           byte[] outputBuffer,
                                           int outputOffset)

        Transforms the specified region of the input byte array and copies the resulting transform to the specified region of the output byte array.

        Specified by:
        transformBlock in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Parameters:
        inputBuffer - the input for which to compute the transform
        inputOffset - the offset into the input byte array from which to begin using data
        inputCount - the number of bytes in the input byte array to use as data
        outputBuffer - the output to which to write the transform
        outputOffset - the offset into the output byte array from which to begin writing data
        Returns:
        the number of bytes written
      • transformFinalBlock

        public abstract byte[] transformFinalBlock​(byte[] inputBuffer,
                                                   int inputOffset,
                                                   int inputCount)

        Transforms the specified region of the specified byte array.

        Specified by:
        transformFinalBlock in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Parameters:
        inputBuffer - the input for which to compute the transform
        inputOffset - the offset into the input byte array from which to begin using data
        inputCount - the number of bytes in the input byte array to use as data
        Returns:
        the computed transform
      • canReuseTransform

        public abstract boolean canReuseTransform()

        Gets a value indicating whether the current transform can be reused.

        Specified by:
        canReuseTransform in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Returns:
        a value indicating whether the current transform can be reused
      • canTransformMultipleBlocks

        public abstract boolean canTransformMultipleBlocks()

        Gets a value indicating whether multiple blocks can be transformed.

        Specified by:
        canTransformMultipleBlocks in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Returns:
        a value indicating whether multiple blocks can be transformed
      • getInputBlockSize

        public abstract int getInputBlockSize()

        Gets the input block size.

        Specified by:
        getInputBlockSize in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Returns:
        the input block size
      • getOutputBlockSize

        public abstract int getOutputBlockSize()

        Gets the output block size.

        Specified by:
        getOutputBlockSize in interface com.aspose.ms.System.Security.Cryptography.ICryptoTransform
        Returns:
        the output block size