# Class VulkanMemoryBarrier.Builder

java.lang.Object
com.io7m.jcoronado.api.VulkanMemoryBarrier.Builder

Enclosing class:
  `VulkanMemoryBarrier`

public static final class VulkanMemoryBarrier.Builder extends Object
Builds instances of type `VulkanMemoryBarrier`. Initialize attributes and then invoke the `build()` method to create an immutable instance.

`Builder` is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `final VulkanMemoryBarrier.Builder`
  `addAllDstAccessMask(Iterable<VulkanAccessFlag> elements)`
  Adds elements to `dstAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `addAllSrcAccessMask(Iterable<VulkanAccessFlag> elements)`
  Adds elements to `srcAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `addDstAccessMask(VulkanAccessFlag element)`
  Adds one element to `dstAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `addDstAccessMask(VulkanAccessFlag... elements)`
  Adds elements to `dstAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `addSrcAccessMask(VulkanAccessFlag element)`
  Adds one element to `srcAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `addSrcAccessMask(VulkanAccessFlag... elements)`
  Adds elements to `srcAccessMask` set.
  `VulkanMemoryBarrier`
  `build()`
  Builds a new `VulkanMemoryBarrier`.
  `final VulkanMemoryBarrier.Builder`
  `from(VulkanMemoryBarrierType instance)`
  Fill a builder with attribute values from the provided `VulkanMemoryBarrierType` instance.
  `final VulkanMemoryBarrier.Builder`
  `setDstAccessMask(Iterable<VulkanAccessFlag> elements)`
  Sets or replaces all elements for `dstAccessMask` set.
  `final VulkanMemoryBarrier.Builder`
  `setSrcAccessMask(Iterable<VulkanAccessFlag> elements)`
  Sets or replaces all elements for `srcAccessMask` set.

  ### Methods inherited from class Object

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

- ## Method Details

  - ### from

    public final VulkanMemoryBarrier.Builder from(VulkanMemoryBarrierType instance)
    Fill a builder with attribute values from the provided `VulkanMemoryBarrierType` instance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.
    Parameters:
      `instance` - The instance from which to copy values
    Returns:
      `this` builder for use in a chained invocation

  - ### addSrcAccessMask

    public final VulkanMemoryBarrier.Builder addSrcAccessMask(VulkanAccessFlag element)
    Adds one element to `srcAccessMask` set.
    Parameters:
      `element` - A srcAccessMask element
    Returns:
      `this` builder for use in a chained invocation

  - ### addSrcAccessMask

    public final VulkanMemoryBarrier.Builder addSrcAccessMask(VulkanAccessFlag... elements)
    Adds elements to `srcAccessMask` set.
    Parameters:
      `elements` - An array of srcAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### setSrcAccessMask

    public final VulkanMemoryBarrier.Builder setSrcAccessMask(Iterable<VulkanAccessFlag> elements)
    Sets or replaces all elements for `srcAccessMask` set.
    Parameters:
      `elements` - An iterable of srcAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### addAllSrcAccessMask

    public final VulkanMemoryBarrier.Builder addAllSrcAccessMask(Iterable<VulkanAccessFlag> elements)
    Adds elements to `srcAccessMask` set.
    Parameters:
      `elements` - An iterable of srcAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### addDstAccessMask

    public final VulkanMemoryBarrier.Builder addDstAccessMask(VulkanAccessFlag element)
    Adds one element to `dstAccessMask` set.
    Parameters:
      `element` - A dstAccessMask element
    Returns:
      `this` builder for use in a chained invocation

  - ### addDstAccessMask

    public final VulkanMemoryBarrier.Builder addDstAccessMask(VulkanAccessFlag... elements)
    Adds elements to `dstAccessMask` set.
    Parameters:
      `elements` - An array of dstAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### setDstAccessMask

    public final VulkanMemoryBarrier.Builder setDstAccessMask(Iterable<VulkanAccessFlag> elements)
    Sets or replaces all elements for `dstAccessMask` set.
    Parameters:
      `elements` - An iterable of dstAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### addAllDstAccessMask

    public final VulkanMemoryBarrier.Builder addAllDstAccessMask(Iterable<VulkanAccessFlag> elements)
    Adds elements to `dstAccessMask` set.
    Parameters:
      `elements` - An iterable of dstAccessMask elements
    Returns:
      `this` builder for use in a chained invocation

  - ### build

    public VulkanMemoryBarrier build()
    Builds a new `VulkanMemoryBarrier`.
    Returns:
      An immutable instance of VulkanMemoryBarrier
    Throws:
      `IllegalStateException` - if any required attributes are missing