Module com.io7m.jcoronado.api
Package com.io7m.jcoronado.api
Class VulkanClearValueColorFloatingPoint
- java.lang.Object
-
- com.io7m.jcoronado.api.VulkanClearValueColorFloatingPoint
-
- All Implemented Interfaces:
VulkanClearValueType
,VulkanClearValueType.VulkanClearValueColorFloatingPointType
,VulkanClearValueType.VulkanClearValueColorType
public final class VulkanClearValueColorFloatingPoint extends java.lang.Object implements VulkanClearValueType.VulkanClearValueColorFloatingPointType
A color consisting of floating-point components.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VulkanClearValueColorFloatingPoint.Builder
Builds instances of typeVulkanClearValueColorFloatingPoint
.-
Nested classes/interfaces inherited from interface com.io7m.jcoronado.api.VulkanClearValueType
VulkanClearValueType.Type, VulkanClearValueType.VulkanClearValueColorFloatingPointType, VulkanClearValueType.VulkanClearValueColorIntegerSignedType, VulkanClearValueType.VulkanClearValueColorIntegerUnsignedType, VulkanClearValueType.VulkanClearValueColorType, VulkanClearValueType.VulkanClearValueDepthStencilType
-
Nested classes/interfaces inherited from interface com.io7m.jcoronado.api.VulkanClearValueType.VulkanClearValueColorType
VulkanClearValueType.VulkanClearValueColorType.ColorType
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description float
alpha()
float
blue()
static VulkanClearValueColorFloatingPoint.Builder
builder()
Creates a builder forVulkanClearValueColorFloatingPoint
.static VulkanClearValueColorFloatingPoint
copyOf(VulkanClearValueType.VulkanClearValueColorFloatingPointType instance)
Creates an immutable copy of aVulkanClearValueType.VulkanClearValueColorFloatingPointType
value.boolean
equals(java.lang.Object another)
This instance is equal to all instances ofVulkanClearValueColorFloatingPoint
that have equal attribute values.float
green()
int
hashCode()
Computes a hash code from attributes:red
,green
,blue
,alpha
.static VulkanClearValueColorFloatingPoint
of(float red, float green, float blue, float alpha)
Construct a new immutableVulkanClearValueColorFloatingPoint
instance.float
red()
java.lang.String
toString()
Prints the immutable valueVulkanClearValueColorFloatingPoint
with attribute values.VulkanClearValueColorFloatingPoint
withAlpha(float value)
Copy the current immutable object by setting a value for thealpha
attribute.VulkanClearValueColorFloatingPoint
withBlue(float value)
Copy the current immutable object by setting a value for theblue
attribute.VulkanClearValueColorFloatingPoint
withGreen(float value)
Copy the current immutable object by setting a value for thegreen
attribute.VulkanClearValueColorFloatingPoint
withRed(float value)
Copy the current immutable object by setting a value for thered
attribute.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.io7m.jcoronado.api.VulkanClearValueType.VulkanClearValueColorFloatingPointType
colorType
-
Methods inherited from interface com.io7m.jcoronado.api.VulkanClearValueType.VulkanClearValueColorType
type
-
-
-
-
Method Detail
-
red
public float red()
- Specified by:
red
in interfaceVulkanClearValueType.VulkanClearValueColorFloatingPointType
- Returns:
- The red channel
-
green
public float green()
- Specified by:
green
in interfaceVulkanClearValueType.VulkanClearValueColorFloatingPointType
- Returns:
- The green channel
-
blue
public float blue()
- Specified by:
blue
in interfaceVulkanClearValueType.VulkanClearValueColorFloatingPointType
- Returns:
- The blue channel
-
alpha
public float alpha()
- Specified by:
alpha
in interfaceVulkanClearValueType.VulkanClearValueColorFloatingPointType
- Returns:
- The alpha channel
-
withRed
public final VulkanClearValueColorFloatingPoint withRed(float value)
Copy the current immutable object by setting a value for thered
attribute. A value strict bits equality used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for red- Returns:
- A modified copy of the
this
object
-
withGreen
public final VulkanClearValueColorFloatingPoint withGreen(float value)
Copy the current immutable object by setting a value for thegreen
attribute. A value strict bits equality used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for green- Returns:
- A modified copy of the
this
object
-
withBlue
public final VulkanClearValueColorFloatingPoint withBlue(float value)
Copy the current immutable object by setting a value for theblue
attribute. A value strict bits equality used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for blue- Returns:
- A modified copy of the
this
object
-
withAlpha
public final VulkanClearValueColorFloatingPoint withAlpha(float value)
Copy the current immutable object by setting a value for thealpha
attribute. A value strict bits equality used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for alpha- Returns:
- A modified copy of the
this
object
-
equals
public boolean equals(java.lang.Object another)
This instance is equal to all instances ofVulkanClearValueColorFloatingPoint
that have equal attribute values.- Overrides:
equals
in classjava.lang.Object
- Returns:
true
ifthis
is equal toanother
instance
-
hashCode
public int hashCode()
Computes a hash code from attributes:red
,green
,blue
,alpha
.- Overrides:
hashCode
in classjava.lang.Object
- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueVulkanClearValueColorFloatingPoint
with attribute values.- Overrides:
toString
in classjava.lang.Object
- Returns:
- A string representation of the value
-
of
public static VulkanClearValueColorFloatingPoint of(float red, float green, float blue, float alpha)
Construct a new immutableVulkanClearValueColorFloatingPoint
instance.- Parameters:
red
- The value for thered
attributegreen
- The value for thegreen
attributeblue
- The value for theblue
attributealpha
- The value for thealpha
attribute- Returns:
- An immutable VulkanClearValueColorFloatingPoint instance
-
copyOf
public static VulkanClearValueColorFloatingPoint copyOf(VulkanClearValueType.VulkanClearValueColorFloatingPointType instance)
Creates an immutable copy of aVulkanClearValueType.VulkanClearValueColorFloatingPointType
value. 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 VulkanClearValueColorFloatingPoint instance
-
builder
public static VulkanClearValueColorFloatingPoint.Builder builder()
Creates a builder forVulkanClearValueColorFloatingPoint
.- Returns:
- A new VulkanClearValueColorFloatingPoint builder
-
-