Class VulkanDescriptorBufferInfo
java.lang.Object
com.io7m.jcoronado.api.VulkanDescriptorBufferInfo
- All Implemented Interfaces:
VulkanDescriptorBufferInfoType
public final class VulkanDescriptorBufferInfo
extends Object
implements VulkanDescriptorBufferInfoType
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeVulkanDescriptorBufferInfo. -
Method Summary
Modifier and TypeMethodDescriptionbuffer()builder()Creates a builder forVulkanDescriptorBufferInfo.static VulkanDescriptorBufferInfocopyOf(VulkanDescriptorBufferInfoType instance) Creates an immutable copy of aVulkanDescriptorBufferInfoTypevalue.booleanThis instance is equal to all instances ofVulkanDescriptorBufferInfothat have equal attribute values.inthashCode()Computes a hash code from attributes:buffer,offset,range.static VulkanDescriptorBufferInfoof(VulkanBufferType buffer, long offset, long range) Construct a new immutableVulkanDescriptorBufferInfoinstance.longoffset()longrange()toString()Prints the immutable valueVulkanDescriptorBufferInfowith attribute values.withBuffer(VulkanBufferType value) Copy the current immutable object by setting a value for thebufferattribute.withOffset(long value) Copy the current immutable object by setting a value for theoffsetattribute.withRange(long value) Copy the current immutable object by setting a value for therangeattribute.
-
Method Details
-
buffer
- Specified by:
bufferin interfaceVulkanDescriptorBufferInfoType- Returns:
- The buffer resource
-
offset
public long offset()- Specified by:
offsetin interfaceVulkanDescriptorBufferInfoType- Returns:
- The offset in bytes from the start of buffer. Access to buffer memory via this descriptor uses addressing that is relative to this starting offset.
-
range
public long range()- Specified by:
rangein interfaceVulkanDescriptorBufferInfoType- Returns:
- The size in bytes that is used for this descriptor update, or VK_WHOLE_SIZE to use the range from offset to the end of the buffer.
-
withBuffer
Copy the current immutable object by setting a value for thebufferattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for buffer- Returns:
- A modified copy of the
thisobject
-
withOffset
Copy the current immutable object by setting a value for theoffsetattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for offset- Returns:
- A modified copy of the
thisobject
-
withRange
Copy the current immutable object by setting a value for therangeattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for range- Returns:
- A modified copy of the
thisobject
-
equals
-
hashCode
-
toString
-
of
Construct a new immutableVulkanDescriptorBufferInfoinstance.- Parameters:
buffer- The value for thebufferattributeoffset- The value for theoffsetattributerange- The value for therangeattribute- Returns:
- An immutable VulkanDescriptorBufferInfo instance
-
copyOf
Creates an immutable copy of aVulkanDescriptorBufferInfoTypevalue. 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 VulkanDescriptorBufferInfo instance
-
builder
Creates a builder forVulkanDescriptorBufferInfo.VulkanDescriptorBufferInfo.builder() .setBuffer(com.io7m.jcoronado.api.VulkanBufferType) // requiredbuffer.setOffset(long) // requiredoffset.setRange(long) // requiredrange.build();- Returns:
- A new VulkanDescriptorBufferInfo builder
-