- java.lang.Object
-
- com.io7m.jcoronado.api.VulkanInstanceCreateInfo
-
- All Implemented Interfaces:
VulkanInstanceCreateInfoType
public final class VulkanInstanceCreateInfo extends java.lang.Object implements VulkanInstanceCreateInfoType
Information required to create a Vulkan instance.- See Also:
- "VkInstanceCreateInfo"
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VulkanInstanceCreateInfo.Builder
Builds instances of typeVulkanInstanceCreateInfo
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description VulkanApplicationInfo
applicationInfo()
static VulkanInstanceCreateInfo.Builder
builder()
Creates a builder forVulkanInstanceCreateInfo
.static VulkanInstanceCreateInfo
copyOf(VulkanInstanceCreateInfoType instance)
Creates an immutable copy of aVulkanInstanceCreateInfoType
value.java.util.Set<java.lang.String>
enabledExtensions()
java.util.Set<java.lang.String>
enabledLayers()
boolean
equals(java.lang.Object another)
This instance is equal to all instances ofVulkanInstanceCreateInfo
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:applicationInfo
,enabledExtensions
,enabledLayers
.static VulkanInstanceCreateInfo
of(VulkanApplicationInfo applicationInfo, java.lang.Iterable<java.lang.String> enabledExtensions, java.lang.Iterable<java.lang.String> enabledLayers)
Construct a new immutableVulkanInstanceCreateInfo
instance.static VulkanInstanceCreateInfo
of(VulkanApplicationInfo applicationInfo, java.util.Set<java.lang.String> enabledExtensions, java.util.Set<java.lang.String> enabledLayers)
Construct a new immutableVulkanInstanceCreateInfo
instance.java.lang.String
toString()
Prints the immutable valueVulkanInstanceCreateInfo
with attribute values.VulkanInstanceCreateInfo
withApplicationInfo(VulkanApplicationInfo value)
Copy the current immutable object by setting a value for theapplicationInfo
attribute.VulkanInstanceCreateInfo
withEnabledExtensions(java.lang.Iterable<java.lang.String> elements)
Copy the current immutable object with elements that replace the content ofenabledExtensions
.VulkanInstanceCreateInfo
withEnabledExtensions(java.lang.String... elements)
Copy the current immutable object with elements that replace the content ofenabledExtensions
.VulkanInstanceCreateInfo
withEnabledLayers(java.lang.Iterable<java.lang.String> elements)
Copy the current immutable object with elements that replace the content ofenabledLayers
.VulkanInstanceCreateInfo
withEnabledLayers(java.lang.String... elements)
Copy the current immutable object with elements that replace the content ofenabledLayers
.
-
-
-
Method Detail
-
applicationInfo
public VulkanApplicationInfo applicationInfo()
- Specified by:
applicationInfo
in interfaceVulkanInstanceCreateInfoType
- Returns:
- The application info
-
enabledExtensions
public java.util.Set<java.lang.String> enabledExtensions()
- Specified by:
enabledExtensions
in interfaceVulkanInstanceCreateInfoType
- Returns:
- The names of all extensions that should be enabled
-
enabledLayers
public java.util.Set<java.lang.String> enabledLayers()
- Specified by:
enabledLayers
in interfaceVulkanInstanceCreateInfoType
- Returns:
- The names of all layers that should be enabled
-
withApplicationInfo
public final VulkanInstanceCreateInfo withApplicationInfo(VulkanApplicationInfo value)
Copy the current immutable object by setting a value for theapplicationInfo
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for applicationInfo- Returns:
- A modified copy of the
this
object
-
withEnabledExtensions
public final VulkanInstanceCreateInfo withEnabledExtensions(java.lang.String... elements)
Copy the current immutable object with elements that replace the content ofenabledExtensions
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withEnabledExtensions
public final VulkanInstanceCreateInfo withEnabledExtensions(java.lang.Iterable<java.lang.String> elements)
Copy the current immutable object with elements that replace the content ofenabledExtensions
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of enabledExtensions elements to set- Returns:
- A modified copy of
this
object
-
withEnabledLayers
public final VulkanInstanceCreateInfo withEnabledLayers(java.lang.String... elements)
Copy the current immutable object with elements that replace the content ofenabledLayers
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withEnabledLayers
public final VulkanInstanceCreateInfo withEnabledLayers(java.lang.Iterable<java.lang.String> elements)
Copy the current immutable object with elements that replace the content ofenabledLayers
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of enabledLayers elements to set- Returns:
- A modified copy of
this
object
-
equals
public boolean equals(java.lang.Object another)
This instance is equal to all instances ofVulkanInstanceCreateInfo
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:applicationInfo
,enabledExtensions
,enabledLayers
.- Overrides:
hashCode
in classjava.lang.Object
- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueVulkanInstanceCreateInfo
with attribute values.- Overrides:
toString
in classjava.lang.Object
- Returns:
- A string representation of the value
-
of
public static VulkanInstanceCreateInfo of(VulkanApplicationInfo applicationInfo, java.util.Set<java.lang.String> enabledExtensions, java.util.Set<java.lang.String> enabledLayers)
Construct a new immutableVulkanInstanceCreateInfo
instance.- Parameters:
applicationInfo
- The value for theapplicationInfo
attributeenabledExtensions
- The value for theenabledExtensions
attributeenabledLayers
- The value for theenabledLayers
attribute- Returns:
- An immutable VulkanInstanceCreateInfo instance
-
of
public static VulkanInstanceCreateInfo of(VulkanApplicationInfo applicationInfo, java.lang.Iterable<java.lang.String> enabledExtensions, java.lang.Iterable<java.lang.String> enabledLayers)
Construct a new immutableVulkanInstanceCreateInfo
instance.- Parameters:
applicationInfo
- The value for theapplicationInfo
attributeenabledExtensions
- The value for theenabledExtensions
attributeenabledLayers
- The value for theenabledLayers
attribute- Returns:
- An immutable VulkanInstanceCreateInfo instance
-
copyOf
public static VulkanInstanceCreateInfo copyOf(VulkanInstanceCreateInfoType instance)
Creates an immutable copy of aVulkanInstanceCreateInfoType
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 VulkanInstanceCreateInfo instance
-
builder
public static VulkanInstanceCreateInfo.Builder builder()
Creates a builder forVulkanInstanceCreateInfo
.- Returns:
- A new VulkanInstanceCreateInfo builder
-
-