Class VulkanImageMemoryBarrier.Builder
java.lang.Object
com.io7m.jcoronado.api.VulkanImageMemoryBarrier.Builder
- Enclosing class:
VulkanImageMemoryBarrier
Builds instances of type
VulkanImageMemoryBarrier.
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 TypeMethodDescriptionaddAllSourceAccessMask(Iterable<VulkanAccessFlag> elements) Adds elements tosourceAccessMaskset.addAllTargetAccessMask(Iterable<VulkanAccessFlag> elements) Adds elements totargetAccessMaskset.addSourceAccessMask(VulkanAccessFlag element) Adds one element tosourceAccessMaskset.addSourceAccessMask(VulkanAccessFlag... elements) Adds elements tosourceAccessMaskset.addTargetAccessMask(VulkanAccessFlag element) Adds one element totargetAccessMaskset.addTargetAccessMask(VulkanAccessFlag... elements) Adds elements totargetAccessMaskset.build()Builds a newVulkanImageMemoryBarrier.from(VulkanImageMemoryBarrierType instance) Fill a builder with attribute values from the providedVulkanImageMemoryBarrierTypeinstance.setImage(VulkanImageType image) Initializes the value for theimageattribute.setNewLayout(VulkanImageLayout newLayout) Initializes the value for thenewLayoutattribute.setOldLayout(VulkanImageLayout oldLayout) Initializes the value for theoldLayoutattribute.setSourceAccessMask(Iterable<VulkanAccessFlag> elements) Sets or replaces all elements forsourceAccessMaskset.setSourceQueueFamilyIndex(VulkanQueueFamilyIndex sourceQueueFamilyIndex) Initializes the value for thesourceQueueFamilyIndexattribute.setSubresourceRange(VulkanImageSubresourceRange subresourceRange) Initializes the value for thesubresourceRangeattribute.setTargetAccessMask(Iterable<VulkanAccessFlag> elements) Sets or replaces all elements fortargetAccessMaskset.setTargetQueueFamilyIndex(VulkanQueueFamilyIndex targetQueueFamilyIndex) Initializes the value for thetargetQueueFamilyIndexattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedVulkanImageMemoryBarrierTypeinstance. 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:
thisbuilder for use in a chained invocation
-
addSourceAccessMask
Adds one element tosourceAccessMaskset.- Parameters:
element- A sourceAccessMask element- Returns:
thisbuilder for use in a chained invocation
-
addSourceAccessMask
Adds elements tosourceAccessMaskset.- Parameters:
elements- An array of sourceAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
setSourceAccessMask
public final VulkanImageMemoryBarrier.Builder setSourceAccessMask(Iterable<VulkanAccessFlag> elements) Sets or replaces all elements forsourceAccessMaskset.- Parameters:
elements- An iterable of sourceAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
addAllSourceAccessMask
public final VulkanImageMemoryBarrier.Builder addAllSourceAccessMask(Iterable<VulkanAccessFlag> elements) Adds elements tosourceAccessMaskset.- Parameters:
elements- An iterable of sourceAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
addTargetAccessMask
Adds one element totargetAccessMaskset.- Parameters:
element- A targetAccessMask element- Returns:
thisbuilder for use in a chained invocation
-
addTargetAccessMask
Adds elements totargetAccessMaskset.- Parameters:
elements- An array of targetAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
setTargetAccessMask
public final VulkanImageMemoryBarrier.Builder setTargetAccessMask(Iterable<VulkanAccessFlag> elements) Sets or replaces all elements fortargetAccessMaskset.- Parameters:
elements- An iterable of targetAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
addAllTargetAccessMask
public final VulkanImageMemoryBarrier.Builder addAllTargetAccessMask(Iterable<VulkanAccessFlag> elements) Adds elements totargetAccessMaskset.- Parameters:
elements- An iterable of targetAccessMask elements- Returns:
thisbuilder for use in a chained invocation
-
setOldLayout
Initializes the value for theoldLayoutattribute.- Parameters:
oldLayout- The value for oldLayout- Returns:
thisbuilder for use in a chained invocation
-
setNewLayout
Initializes the value for thenewLayoutattribute.- Parameters:
newLayout- The value for newLayout- Returns:
thisbuilder for use in a chained invocation
-
setSourceQueueFamilyIndex
public final VulkanImageMemoryBarrier.Builder setSourceQueueFamilyIndex(VulkanQueueFamilyIndex sourceQueueFamilyIndex) Initializes the value for thesourceQueueFamilyIndexattribute.- Parameters:
sourceQueueFamilyIndex- The value for sourceQueueFamilyIndex- Returns:
thisbuilder for use in a chained invocation
-
setTargetQueueFamilyIndex
public final VulkanImageMemoryBarrier.Builder setTargetQueueFamilyIndex(VulkanQueueFamilyIndex targetQueueFamilyIndex) Initializes the value for thetargetQueueFamilyIndexattribute.- Parameters:
targetQueueFamilyIndex- The value for targetQueueFamilyIndex- Returns:
thisbuilder for use in a chained invocation
-
setImage
Initializes the value for theimageattribute.- Parameters:
image- The value for image- Returns:
thisbuilder for use in a chained invocation
-
setSubresourceRange
public final VulkanImageMemoryBarrier.Builder setSubresourceRange(VulkanImageSubresourceRange subresourceRange) Initializes the value for thesubresourceRangeattribute.- Parameters:
subresourceRange- The value for subresourceRange- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newVulkanImageMemoryBarrier.- Returns:
- An immutable instance of VulkanImageMemoryBarrier
- Throws:
IllegalStateException- if any required attributes are missing
-