software.aws.awsprototypingsdk.cdkgraph.ICdkGraphProps Maven / Gradle / Ivy
Show all versions of cdk-graph Show documentation
package software.aws.awsprototypingsdk.cdkgraph;
/**
* (experimental) {@link CdkGraph} props.
*/
@javax.annotation.Generated(value = "jsii-pacmak/1.82.0 (build 2d2ddd7)", date = "2023-08-15T05:45:13.714Z")
@software.amazon.jsii.Jsii(module = software.aws.awsprototypingsdk.cdkgraph.$Module.class, fqn = "@aws-prototyping-sdk/cdk-graph.ICdkGraphProps")
@software.amazon.jsii.Jsii.Proxy(ICdkGraphProps.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public interface ICdkGraphProps extends software.amazon.jsii.JsiiSerializable {
/**
* (experimental) List of plugins to extends the graph.
*
* Plugins are invoked at each phases in fifo order.
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
default @org.jetbrains.annotations.Nullable java.util.List getPlugins() {
return null;
}
/**
* @return a {@link Builder} of {@link ICdkGraphProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
static Builder builder() {
return new Builder();
}
/**
* A builder for {@link ICdkGraphProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public static final class Builder implements software.amazon.jsii.Builder {
java.util.List plugins;
/**
* Sets the value of {@link ICdkGraphProps#getPlugins}
* @param plugins List of plugins to extends the graph.
* Plugins are invoked at each phases in fifo order.
* @return {@code this}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@SuppressWarnings("unchecked")
public Builder plugins(java.util.List extends software.aws.awsprototypingsdk.cdkgraph.ICdkGraphPlugin> plugins) {
this.plugins = (java.util.List)plugins;
return this;
}
/**
* Builds the configured instance.
* @return a new instance of {@link ICdkGraphProps}
* @throws NullPointerException if any required attribute was not provided
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@Override
public ICdkGraphProps build() {
return new Jsii$Proxy(this);
}
}
/**
* An implementation for {@link ICdkGraphProps}
*/
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
@software.amazon.jsii.Internal
final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements ICdkGraphProps {
private final java.util.List plugins;
/**
* Constructor that initializes the object based on values retrieved from the JsiiObject.
* @param objRef Reference to the JSII managed object.
*/
protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) {
super(objRef);
this.plugins = software.amazon.jsii.Kernel.get(this, "plugins", software.amazon.jsii.NativeType.listOf(software.amazon.jsii.NativeType.forClass(software.aws.awsprototypingsdk.cdkgraph.ICdkGraphPlugin.class)));
}
/**
* Constructor that initializes the object based on literal property values passed by the {@link Builder}.
*/
@SuppressWarnings("unchecked")
protected Jsii$Proxy(final Builder builder) {
super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
this.plugins = (java.util.List)builder.plugins;
}
@Override
public final java.util.List getPlugins() {
return this.plugins;
}
@Override
@software.amazon.jsii.Internal
public com.fasterxml.jackson.databind.JsonNode $jsii$toJson() {
final com.fasterxml.jackson.databind.ObjectMapper om = software.amazon.jsii.JsiiObjectMapper.INSTANCE;
final com.fasterxml.jackson.databind.node.ObjectNode data = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
if (this.getPlugins() != null) {
data.set("plugins", om.valueToTree(this.getPlugins()));
}
final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
struct.set("fqn", om.valueToTree("@aws-prototyping-sdk/cdk-graph.ICdkGraphProps"));
struct.set("data", data);
final com.fasterxml.jackson.databind.node.ObjectNode obj = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode();
obj.set("$jsii.struct", struct);
return obj;
}
@Override
public final boolean equals(final Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
ICdkGraphProps.Jsii$Proxy that = (ICdkGraphProps.Jsii$Proxy) o;
return this.plugins != null ? this.plugins.equals(that.plugins) : that.plugins == null;
}
@Override
public final int hashCode() {
int result = this.plugins != null ? this.plugins.hashCode() : 0;
return result;
}
}
}