Package org.cdk8s.plus24.k8s
Class StatusCause.Builder
- java.lang.Object
-
- org.cdk8s.plus24.k8s.StatusCause.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<StatusCause>
- Enclosing interface:
- StatusCause
@Stability(Stable) public static final class StatusCause.Builder extends Object implements software.amazon.jsii.Builder<StatusCause>
A builder forStatusCause
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StatusCause
build()
Builds the configured instance.StatusCause.Builder
field(String field)
Sets the value ofStatusCause.getField()
StatusCause.Builder
message(String message)
Sets the value ofStatusCause.getMessage()
StatusCause.Builder
reason(String reason)
Sets the value ofStatusCause.getReason()
-
-
-
Method Detail
-
field
@Stability(Stable) public StatusCause.Builder field(String field)
Sets the value ofStatusCause.getField()
- Parameters:
field
- The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.Examples: "name" - the field "name" on the current resource "items[0].name" - the field "name" on the first array entry in "items"
- Returns:
this
-
message
@Stability(Stable) public StatusCause.Builder message(String message)
Sets the value ofStatusCause.getMessage()
- Parameters:
message
- A human-readable description of the cause of the error. This field may be presented as-is to a reader.- Returns:
this
-
reason
@Stability(Stable) public StatusCause.Builder reason(String reason)
Sets the value ofStatusCause.getReason()
- Parameters:
reason
- A machine-readable description of the cause of the error. If this value is empty there is no information available.- Returns:
this
-
build
@Stability(Stable) public StatusCause build()
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<StatusCause>
- Returns:
- a new instance of
StatusCause
- Throws:
NullPointerException
- if any required attribute was not provided
-
-