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 of this object
    • 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 of 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 of 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
    • of

      public static VulkanShaderModuleCreateInfo of(Set<VulkanShaderModuleCreateFlag> flags, ByteBuffer data, long size)
      Construct a new immutable VulkanShaderModuleCreateInfo instance.
      Parameters:
      flags - The value for the flags attribute
      data - The value for the data attribute
      size - The value for the size attribute
      Returns:
      An immutable VulkanShaderModuleCreateInfo instance
    • of

      public static VulkanShaderModuleCreateInfo of(Iterable<VulkanShaderModuleCreateFlag> flags, ByteBuffer data, long size)
      Construct a new immutable VulkanShaderModuleCreateInfo instance.
      Parameters:
      flags - The value for the flags attribute
      data - The value for the data attribute
      size - The value for the size attribute
      Returns:
      An immutable VulkanShaderModuleCreateInfo instance
    • 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) // required size
          .build();
       
      Returns:
      A new VulkanShaderModuleCreateInfo builder