# Class VulkanDescriptorImageInfo

java.lang.Object
com.io7m.jcoronado.api.VulkanDescriptorImageInfo

All Implemented Interfaces:
  `VulkanDescriptorImageInfoType`

public final class VulkanDescriptorImageInfo extends Object implements VulkanDescriptorImageInfoType

See Also:
  - "VkDescriptorImageInfo"

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static final class`
  `VulkanDescriptorImageInfo.Builder`
  Builds instances of type `VulkanDescriptorImageInfo`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static VulkanDescriptorImageInfo.Builder`
  `builder()`
  Creates a builder for `VulkanDescriptorImageInfo`.
  `static VulkanDescriptorImageInfo`
  `copyOf(VulkanDescriptorImageInfoType instance)`
  Creates an immutable copy of a `VulkanDescriptorImageInfoType` value.
  `boolean`
  `equals(Object another)`
  This instance is equal to all instances of `VulkanDescriptorImageInfo` that have equal attribute values.
  `int`
  `hashCode()`
  Computes a hash code from attributes: `sampler`, `imageView`, `imageLayout`.
  `VulkanImageLayout`
  `imageLayout()`
  `VulkanImageViewType`
  `imageView()`
  `VulkanSamplerType`
  `sampler()`
  `String`
  `toString()`
  Prints the immutable value `VulkanDescriptorImageInfo` with attribute values.
  `final VulkanDescriptorImageInfo`
  `withImageLayout(VulkanImageLayout value)`
  Copy the current immutable object by setting a value for the `imageLayout` attribute.
  `final VulkanDescriptorImageInfo`
  `withImageView(VulkanImageViewType value)`
  Copy the current immutable object by setting a value for the `imageView` attribute.
  `final VulkanDescriptorImageInfo`
  `withSampler(VulkanSamplerType value)`
  Copy the current immutable object by setting a value for the `sampler` attribute.

  ### Methods inherited from class Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Method Details

  - ### sampler

    public VulkanSamplerType sampler()
    Specified by:
      `sampler` in interface `VulkanDescriptorImageInfoType`
    Returns:
      A sampler handle, and is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLER and VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER if the binding being updated does not use immutable samplers.

  - ### imageView

    public VulkanImageViewType imageView()
    Specified by:
      `imageView` in interface `VulkanDescriptorImageInfoType`
    Returns:
      An image view handle, and is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, and VK_DESCRIPTOR_TYPE_INPUT_ATTACHMENT.

  - ### imageLayout

    public VulkanImageLayout imageLayout()
    Specified by:
      `imageLayout` in interface `VulkanDescriptorImageInfoType`
    Returns:
      The layout that the image subresources accessible from imageView will be in at the time this descriptor is accessed. imageLayout is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, and VK_DESCRIPTOR_TYPE_INPUT_ATTACHMENT.

  - ### withSampler

    public final VulkanDescriptorImageInfo withSampler(VulkanSamplerType value)
    Copy the current immutable object by setting a value for the `sampler` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for sampler
    Returns:
      A modified copy or the `this` object

  - ### withImageView

    public final VulkanDescriptorImageInfo withImageView(VulkanImageViewType value)
    Copy the current immutable object by setting a value for the `imageView` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for imageView
    Returns:
      A modified copy or the `this` object

  - ### withImageLayout

    public final VulkanDescriptorImageInfo withImageLayout(VulkanImageLayout value)
    Copy the current immutable object by setting a value for the `imageLayout` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for imageLayout
    Returns:
      A modified copy or the `this` object

  - ### equals

    public boolean equals(Object another)
    This instance is equal to all instances of `VulkanDescriptorImageInfo` 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: `sampler`, `imageView`, `imageLayout`.
    Overrides:
      `hashCode` in class `Object`
    Returns:
      hashCode value

  - ### toString

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

  - ### copyOf

    public static VulkanDescriptorImageInfo copyOf(VulkanDescriptorImageInfoType instance)
    Creates an immutable copy of a `VulkanDescriptorImageInfoType` 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 VulkanDescriptorImageInfo instance

  - ### builder

    public static VulkanDescriptorImageInfo.Builder builder()
    Creates a builder for `VulkanDescriptorImageInfo`.

        VulkanDescriptorImageInfo.builder()
           .setSampler(com.io7m.jcoronado.api.VulkanSamplerType) // required sampler
           .setImageView(com.io7m.jcoronado.api.VulkanImageViewType) // required imageView
           .setImageLayout(com.io7m.jcoronado.api.VulkanImageLayout) // optional imageLayout
           .build();

    Returns:
      A new VulkanDescriptorImageInfo builder