Class OutputVector

All Implemented Interfaces:
Proxy

@Generated("org.javagi.JavaGI") public class OutputVector extends ProxyInstance
Structure used for scatter/gather data output. You generally pass in an array of GOutputVectors and the operation will use all the buffers as if they were one buffer.
Since:
2.22
  • Constructor Details

    • OutputVector

      public OutputVector(MemorySegment address)
      Create a OutputVector proxy instance for the provided memory address.
      Parameters:
      address - the memory address of the native object
    • OutputVector

      public OutputVector(Arena arena)
      Allocate a new OutputVector.
      Parameters:
      arena - to control the memory allocation scope
    • OutputVector

      public OutputVector()
      Allocate a new OutputVector. The memory is allocated with Arena.ofAuto().
    • OutputVector

      public OutputVector(MemorySegment buffer, long size, Arena arena)
      Allocate a new OutputVector with the fields set to the provided values.
      Parameters:
      buffer - value for the field buffer
      size - value for the field size
      arena - to control the memory allocation scope
    • OutputVector

      public OutputVector(MemorySegment buffer, long size)
      Allocate a new OutputVector with the fields set to the provided values. The memory is allocated with Arena.ofAuto().
      Parameters:
      buffer - value for the field buffer
      size - value for the field size
  • Method Details

    • getMemoryLayout

      public static MemoryLayout getMemoryLayout()
      The memory layout of the native struct.
      Returns:
      the memory layout
    • readBuffer

      public MemorySegment readBuffer()
      Read the value of the field buffer.
      Returns:
      The value of the field buffer
    • writeBuffer

      public void writeBuffer(MemorySegment buffer)
      Write a value in the field buffer.
      Parameters:
      buffer - The new value for the field buffer
    • readSize

      public long readSize()
      Read the value of the field size.
      Returns:
      The value of the field size
    • writeSize

      public void writeSize(long size)
      Write a value in the field size.
      Parameters:
      size - The new value for the field size