Class LZ4FFrameInfo

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class LZ4FFrameInfo extends Struct<LZ4FFrameInfo> implements NativeResource

 struct LZ4F_frameInfo_t {
     LZ4F_blockSizeID_t blockSizeID;
     LZ4F_blockMode_t blockMode;
     LZ4F_contentChecksum_t contentChecksumFlag;
     LZ4F_frameType_t frameType;
     unsigned long long contentSize;
     unsigned dictID;
     LZ4F_blockChecksum_t blockChecksumFlag;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • BLOCKSIZEID

      public static final int BLOCKSIZEID
      The struct member offsets.
    • BLOCKMODE

      public static final int BLOCKMODE
      The struct member offsets.
    • CONTENTCHECKSUMFLAG

      public static final int CONTENTCHECKSUMFLAG
      The struct member offsets.
    • FRAMETYPE

      public static final int FRAMETYPE
      The struct member offsets.
    • CONTENTSIZE

      public static final int CONTENTSIZE
      The struct member offsets.
    • DICTID

      public static final int DICTID
      The struct member offsets.
    • BLOCKCHECKSUMFLAG

      public static final int BLOCKCHECKSUMFLAG
      The struct member offsets.
  • Constructor Details

    • LZ4FFrameInfo

      public LZ4FFrameInfo(ByteBuffer container)
      Creates a LZ4FFrameInfo instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<LZ4FFrameInfo>
    • blockSizeID

      public int blockSizeID()
      Returns:
      the value of the blockSizeID field.
    • blockMode

      public int blockMode()
      Returns:
      the value of the blockMode field.
    • contentChecksumFlag

      public int contentChecksumFlag()
      Returns:
      the value of the contentChecksumFlag field.
    • frameType

      public int frameType()
      Returns:
      the value of the frameType field.
    • contentSize

      public long contentSize()
      Returns:
      the value of the contentSize field.
    • dictID

      public int dictID()
      Returns:
      the value of the dictID field.
    • blockChecksumFlag

      public int blockChecksumFlag()
      Returns:
      the value of the blockChecksumFlag field.
    • blockSizeID

      public LZ4FFrameInfo blockSizeID(int value)
      Sets the specified value to the blockSizeID field.
    • blockMode

      public LZ4FFrameInfo blockMode(int value)
      Sets the specified value to the blockMode field.
    • contentChecksumFlag

      public LZ4FFrameInfo contentChecksumFlag(int value)
      Sets the specified value to the contentChecksumFlag field.
    • frameType

      public LZ4FFrameInfo frameType(int value)
      Sets the specified value to the frameType field.
    • contentSize

      public LZ4FFrameInfo contentSize(long value)
      Sets the specified value to the contentSize field.
    • dictID

      public LZ4FFrameInfo dictID(int value)
      Sets the specified value to the dictID field.
    • blockChecksumFlag

      public LZ4FFrameInfo blockChecksumFlag(int value)
      Sets the specified value to the blockChecksumFlag field.
    • set

      public LZ4FFrameInfo set(int blockSizeID, int blockMode, int contentChecksumFlag, int frameType, long contentSize, int dictID, int blockChecksumFlag)
      Initializes this struct with the specified values.
    • set

      public LZ4FFrameInfo set(LZ4FFrameInfo src)
      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static LZ4FFrameInfo malloc()
      Returns a new LZ4FFrameInfo instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static LZ4FFrameInfo calloc()
      Returns a new LZ4FFrameInfo instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static LZ4FFrameInfo create()
      Returns a new LZ4FFrameInfo instance allocated with BufferUtils.
    • create

      public static LZ4FFrameInfo create(long address)
      Returns a new LZ4FFrameInfo instance for the specified memory address.
    • createSafe

      public static @Nullable LZ4FFrameInfo createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static LZ4FFrameInfo.Buffer malloc(int capacity)
      Returns a new LZ4FFrameInfo.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static LZ4FFrameInfo.Buffer calloc(int capacity)
      Returns a new LZ4FFrameInfo.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static LZ4FFrameInfo.Buffer create(int capacity)
      Returns a new LZ4FFrameInfo.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static LZ4FFrameInfo.Buffer create(long address, int capacity)
      Create a LZ4FFrameInfo.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable LZ4FFrameInfo.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • mallocStack

      @Deprecated public static LZ4FFrameInfo mallocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static LZ4FFrameInfo callocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static LZ4FFrameInfo mallocStack(MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static LZ4FFrameInfo callocStack(MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static LZ4FFrameInfo.Buffer mallocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static LZ4FFrameInfo.Buffer callocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • mallocStack

      @Deprecated public static LZ4FFrameInfo.Buffer mallocStack(int capacity, MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static LZ4FFrameInfo.Buffer callocStack(int capacity, MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • malloc

      public static LZ4FFrameInfo malloc(MemoryStack stack)
      Returns a new LZ4FFrameInfo instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static LZ4FFrameInfo calloc(MemoryStack stack)
      Returns a new LZ4FFrameInfo instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static LZ4FFrameInfo.Buffer malloc(int capacity, MemoryStack stack)
      Returns a new LZ4FFrameInfo.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static LZ4FFrameInfo.Buffer calloc(int capacity, MemoryStack stack)
      Returns a new LZ4FFrameInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • nblockSizeID

      public static int nblockSizeID(long struct)
      Unsafe version of blockSizeID().
    • nblockMode

      public static int nblockMode(long struct)
      Unsafe version of blockMode().
    • ncontentChecksumFlag

      public static int ncontentChecksumFlag(long struct)
      Unsafe version of contentChecksumFlag().
    • nframeType

      public static int nframeType(long struct)
      Unsafe version of frameType().
    • ncontentSize

      public static long ncontentSize(long struct)
      Unsafe version of contentSize().
    • ndictID

      public static int ndictID(long struct)
      Unsafe version of dictID().
    • nblockChecksumFlag

      public static int nblockChecksumFlag(long struct)
      Unsafe version of blockChecksumFlag().
    • nblockSizeID

      public static void nblockSizeID(long struct, int value)
      Unsafe version of blockSizeID.
    • nblockMode

      public static void nblockMode(long struct, int value)
      Unsafe version of blockMode.
    • ncontentChecksumFlag

      public static void ncontentChecksumFlag(long struct, int value)
      Unsafe version of contentChecksumFlag.
    • nframeType

      public static void nframeType(long struct, int value)
      Unsafe version of frameType.
    • ncontentSize

      public static void ncontentSize(long struct, long value)
      Unsafe version of contentSize.
    • ndictID

      public static void ndictID(long struct, int value)
      Unsafe version of dictID.
    • nblockChecksumFlag

      public static void nblockChecksumFlag(long struct, int value)
      Unsafe version of blockChecksumFlag.