Class VulkanCopyDescriptorSet.Builder
java.lang.Object
com.io7m.jcoronado.api.VulkanCopyDescriptorSet.Builder
- Enclosing class:
VulkanCopyDescriptorSet
Builds instances of type
VulkanCopyDescriptorSet.
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 TypeMethodDescriptionbuild()Builds a newVulkanCopyDescriptorSet.from(VulkanCopyDescriptorSetType instance) Fill a builder with attribute values from the providedVulkanCopyDescriptorSetTypeinstance.setDescriptorCount(int descriptorCount) Initializes the value for thedescriptorCountattribute.setDestinationArrayElement(int destinationArrayElement) Initializes the value for thedestinationArrayElementattribute.setDestinationBinding(int destinationBinding) Initializes the value for thedestinationBindingattribute.setDestinationSet(VulkanDescriptorSetType destinationSet) Initializes the value for thedestinationSetattribute.setSourceArrayElement(int sourceArrayElement) Initializes the value for thesourceArrayElementattribute.setSourceBinding(int sourceBinding) Initializes the value for thesourceBindingattribute.setSourceSet(VulkanDescriptorSetType sourceSet) Initializes the value for thesourceSetattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedVulkanCopyDescriptorSetTypeinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
setSourceSet
Initializes the value for thesourceSetattribute.- Parameters:
sourceSet- The value for sourceSet- Returns:
thisbuilder for use in a chained invocation
-
setSourceBinding
Initializes the value for thesourceBindingattribute.- Parameters:
sourceBinding- The value for sourceBinding- Returns:
thisbuilder for use in a chained invocation
-
setSourceArrayElement
Initializes the value for thesourceArrayElementattribute.- Parameters:
sourceArrayElement- The value for sourceArrayElement- Returns:
thisbuilder for use in a chained invocation
-
setDestinationSet
public final VulkanCopyDescriptorSet.Builder setDestinationSet(VulkanDescriptorSetType destinationSet) Initializes the value for thedestinationSetattribute.- Parameters:
destinationSet- The value for destinationSet- Returns:
thisbuilder for use in a chained invocation
-
setDestinationBinding
Initializes the value for thedestinationBindingattribute.- Parameters:
destinationBinding- The value for destinationBinding- Returns:
thisbuilder for use in a chained invocation
-
setDestinationArrayElement
public final VulkanCopyDescriptorSet.Builder setDestinationArrayElement(int destinationArrayElement) Initializes the value for thedestinationArrayElementattribute.- Parameters:
destinationArrayElement- The value for destinationArrayElement- Returns:
thisbuilder for use in a chained invocation
-
setDescriptorCount
Initializes the value for thedescriptorCountattribute.- Parameters:
descriptorCount- The value for descriptorCount- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newVulkanCopyDescriptorSet.- Returns:
- An immutable instance of VulkanCopyDescriptorSet
- Throws:
IllegalStateException- if any required attributes are missing
-