Class VulkanAttachmentReference
java.lang.Object
com.io7m.jcoronado.api.VulkanAttachmentReference
- All Implemented Interfaces:
VulkanAttachmentReferenceType
public final class VulkanAttachmentReference
extends Object
implements VulkanAttachmentReferenceType
Structure specifying an attachment reference.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeVulkanAttachmentReference. -
Method Summary
Modifier and TypeMethodDescriptionintbuilder()Creates a builder forVulkanAttachmentReference.static VulkanAttachmentReferencecopyOf(VulkanAttachmentReferenceType instance) Creates an immutable copy of aVulkanAttachmentReferenceTypevalue.booleanThis instance is equal to all instances ofVulkanAttachmentReferencethat have equal attribute values.inthashCode()Computes a hash code from attributes:attachment,layout,aspectMask.layout()toString()Prints the immutable valueVulkanAttachmentReferencewith attribute values.withAspectMask(VulkanImageAspectFlag... elements) Copy the current immutable object with elements that replace the content ofaspectMask.withAspectMask(Iterable<VulkanImageAspectFlag> elements) Copy the current immutable object with elements that replace the content ofaspectMask.withAttachment(int value) Copy the current immutable object by setting a value for theattachmentattribute.withLayout(VulkanImageLayout value) Copy the current immutable object by setting a value for thelayoutattribute.
-
Method Details
-
attachment
public int attachment()- Specified by:
attachmentin interfaceVulkanAttachmentReferenceType- Returns:
- The index of the attachment of the render pass
-
layout
- Specified by:
layoutin interfaceVulkanAttachmentReferenceType- Returns:
- The layout the attachment uses during the subpass.
-
aspectMask
- Specified by:
aspectMaskin interfaceVulkanAttachmentReferenceType- Returns:
- A mask of which aspect(s) can be accessed within the specified subpass as an input attachment.
-
withAttachment
Copy the current immutable object by setting a value for theattachmentattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for attachment- Returns:
- A modified copy or the
thisobject
-
withLayout
Copy the current immutable object by setting a value for thelayoutattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for layout- Returns:
- A modified copy or the
thisobject
-
withAspectMask
Copy the current immutable object with elements that replace the content ofaspectMask.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withAspectMask
Copy the current immutable object with elements that replace the content ofaspectMask. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of aspectMask elements to set- Returns:
- A modified copy or
thisif not changed
-
equals
-
hashCode
-
toString
-
copyOf
Creates an immutable copy of aVulkanAttachmentReferenceTypevalue. 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 VulkanAttachmentReference instance
-
builder
Creates a builder forVulkanAttachmentReference.VulkanAttachmentReference.builder() .setAttachment(int) // required
attachment.setLayout(com.io7m.jcoronado.api.VulkanImageLayout) // optionallayout.addAspectMask|addAllAspectMask(com.io7m.jcoronado.api.VulkanImageAspectFlag) //aspectMaskelements .build();- Returns:
- A new VulkanAttachmentReference builder
-