Class VulkanOffset3D
java.lang.Object
com.io7m.jcoronado.api.VulkanOffset3D
- All Implemented Interfaces:
VulkanOffset3DType
Structure specifying a three-dimensional offset.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface VulkanOffset3DType
ZERO -
Method Summary
Modifier and TypeMethodDescriptionstatic VulkanOffset3D.Builderbuilder()Creates a builder forVulkanOffset3D.static VulkanOffset3DcopyOf(VulkanOffset3DType instance) Creates an immutable copy of aVulkanOffset3DTypevalue.booleanThis instance is equal to all instances ofVulkanOffset3Dthat have equal attribute values.inthashCode()Computes a hash code from attributes:x,y,z.toString()Prints the immutable valueVulkanOffset3Dwith attribute values.final VulkanOffset3DwithX(int value) Copy the current immutable object by setting a value for thexattribute.final VulkanOffset3DwithY(int value) Copy the current immutable object by setting a value for theyattribute.final VulkanOffset3DwithZ(int value) Copy the current immutable object by setting a value for thezattribute.intx()inty()intz()
-
Method Details
-
x
public int x()- Specified by:
xin interfaceVulkanOffset3DType- Returns:
- The x offset
-
y
public int y()- Specified by:
yin interfaceVulkanOffset3DType- Returns:
- The y offset
-
z
public int z()- Specified by:
zin interfaceVulkanOffset3DType- Returns:
- The z offset
-
withX
Copy the current immutable object by setting a value for thexattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for x- Returns:
- A modified copy or the
thisobject
-
withY
Copy the current immutable object by setting a value for theyattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for y- Returns:
- A modified copy or the
thisobject
-
withZ
Copy the current immutable object by setting a value for thezattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for z- Returns:
- A modified copy or the
thisobject
-
equals
-
hashCode
-
toString
-
copyOf
Creates an immutable copy of aVulkanOffset3DTypevalue. 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 VulkanOffset3D instance
-
builder
Creates a builder forVulkanOffset3D.VulkanOffset3D.builder() .setX(int) // optional
x.setY(int) // optionaly.setZ(int) // optionalz.build();- Returns:
- A new VulkanOffset3D builder
-