# Class VulkanLWJGLArrays

java.lang.Object
com.io7m.jcoronado.lwjgl.internal.VulkanLWJGLArrays

public final class VulkanLWJGLArrays extends Object
Functions to pack arrays.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static interface`
  `VulkanLWJGLArrays.BufferAllocatorType<T extends org.lwjgl.system.Struct<T>,B extends org.lwjgl.system.StructBuffer<T,B>>`
  The type of functions that can allocate buffers for structures of type `T`.
  `static interface`
  `VulkanLWJGLArrays.PackingFunctionType<A,T extends org.lwjgl.system.Struct<T>>`
  The type of functions that can pack values of type `A` into structures of type `T`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static <A, T extends org.lwjgl.system.Struct<T>, B extends org.lwjgl.system.StructBuffer<T, B>>
  B`
  `pack(List<A> values, VulkanLWJGLArrays.PackingFunctionType<A,T> packer, VulkanLWJGLArrays.BufferAllocatorType<T,B> allocator, org.lwjgl.system.MemoryStack stack)`
  Pack an array of values.
  `static <A, T extends org.lwjgl.system.Struct<T>, B extends org.lwjgl.system.StructBuffer<T, B>>
  B`
  `packOrNull(List<A> values, VulkanLWJGLArrays.PackingFunctionType<A,T> packer, VulkanLWJGLArrays.BufferAllocatorType<T,B> allocator, org.lwjgl.system.MemoryStack stack)`
  Pack an array of values.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### pack

    public static <A, T extends org.lwjgl.system.Struct<T>, B extends org.lwjgl.system.StructBuffer<T, B>> B pack(List<A> values, VulkanLWJGLArrays.PackingFunctionType<A,T> packer, VulkanLWJGLArrays.BufferAllocatorType<T,B> allocator, org.lwjgl.system.MemoryStack stack) throws VulkanException
    Pack an array of values.
    Type Parameters:
      `A` - The type of input values
      `T` - The type of output structs
      `B` - The type of buffers
    Parameters:
      `values` - The input values
      `packer` - A value packer
      `allocator` - An allocator
      `stack` - The stack for allocations
    Returns:
      An array of packed structs
    Throws:
      `VulkanException` - On errors

  - ### packOrNull

    public static <A, T extends org.lwjgl.system.Struct<T>, B extends org.lwjgl.system.StructBuffer<T, B>> B packOrNull(List<A> values, VulkanLWJGLArrays.PackingFunctionType<A,T> packer, VulkanLWJGLArrays.BufferAllocatorType<T,B> allocator, org.lwjgl.system.MemoryStack stack) throws VulkanException
    Pack an array of values.
    Type Parameters:
      `A` - The type of input values
      `T` - The type of output structs
      `B` - The type of buffers
    Parameters:
      `values` - The input values
      `packer` - A value packer
      `allocator` - An allocator
      `stack` - The stack for allocations
    Returns:
      An array of packed structs
    Throws:
      `VulkanException` - On errors