Class VulkanShaderModuleCreateInfo

java.lang.Object
com.io7m.jcoronado.api.VulkanShaderModuleCreateInfo
All Implemented Interfaces:
VulkanShaderModuleCreateInfoType

public final class VulkanShaderModuleCreateInfo extends Object implements VulkanShaderModuleCreateInfoType
The type of Vulkan image view creation information.
See Also:
  • "VkShaderModuleCreateInfo"
  • Method Details

    • flags

      Specified by:
      flags in interface VulkanShaderModuleCreateInfoType
      Returns:
      The module creation flags
    • data

      public ByteBuffer data()
      Specified by:
      data in interface VulkanShaderModuleCreateInfoType
      Returns:
      The shader module bytecode
    • size

      public long size()
      Specified by:
      size in interface VulkanShaderModuleCreateInfoType
      Returns:
      The shader code size
    • withFlags

      public final VulkanShaderModuleCreateInfo withFlags(VulkanShaderModuleCreateFlag... elements)
      Copy the current immutable object with elements that replace the content of flags.
      Parameters:
      elements - The elements to set
      Returns:
      A modified copy of this object
    • withFlags

      Copy the current immutable object with elements that replace the content of flags. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      elements - An iterable of flags elements to set
      Returns:
      A modified copy or this if not changed
    • withData

      public final VulkanShaderModuleCreateInfo withData(ByteBuffer value)
      Copy the current immutable object by setting a value for the data attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for data
      Returns:
      A modified copy or the this object
    • withSize

      public final VulkanShaderModuleCreateInfo withSize(long value)
      Copy the current immutable object by setting a value for the size attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for size
      Returns:
      A modified copy or the this object
    • equals

      public boolean equals(Object another)
      This instance is equal to all instances of VulkanShaderModuleCreateInfo that have equal attribute values.
      Overrides:
      equals in class Object
      Returns:
      true if this is equal to another instance
    • hashCode

      public int hashCode()
      Computes a hash code from attributes: flags, data, size.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

      public String toString()
      Prints the immutable value VulkanShaderModuleCreateInfo with attribute values.
      Overrides:
      toString in class Object
      Returns:
      A string representation of the value
    • copyOf

      Creates an immutable copy of a VulkanShaderModuleCreateInfoType value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.
      Parameters:
      instance - The instance to copy
      Returns:
      A copied immutable VulkanShaderModuleCreateInfo instance
    • builder

      public static VulkanShaderModuleCreateInfo.Builder builder()
      Creates a builder for VulkanShaderModuleCreateInfo.
      VulkanShaderModuleCreateInfo.builder()
         .addFlags|addAllFlags(com.io7m.jcoronado.api.VulkanShaderModuleCreateFlag) // flags elements
         .setData(java.nio.ByteBuffer) // required data
         .setSize(long) // optional size
         .build();
      
      Returns:
      A new VulkanShaderModuleCreateInfo builder