All Downloads are FREE. Search and download functionalities are using the official Maven repository.

de.sebastianhesse.examples.projen.test.ConstructWithProperties Maven / Gradle / Ivy

There is a newer version: 0.1.109
Show newest version
package de.sebastianhesse.examples.projen.test;

/**
 * A simple CDK construct illustrating the differences in declaring construct properties with interfaces.
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.32.0 (build 3f4fe23)", date = "2021-08-16T03:24:17.792Z")
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
@software.amazon.jsii.Jsii(module = de.sebastianhesse.examples.projen.test.$Module.class, fqn = "@seeebiii/projen-test.ConstructWithProperties")
public class ConstructWithProperties extends software.amazon.awscdk.core.Construct {

    protected ConstructWithProperties(final software.amazon.jsii.JsiiObjectRef objRef) {
        super(objRef);
    }

    protected ConstructWithProperties(final software.amazon.jsii.JsiiObject.InitializationMode initializationMode) {
        super(initializationMode);
    }

    /**
     * @param parent This parameter is required.
     * @param name This parameter is required.
     * @param props This parameter is required.
     * @param props2 This parameter is required.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    public ConstructWithProperties(final @org.jetbrains.annotations.NotNull software.amazon.awscdk.core.Construct parent, final @org.jetbrains.annotations.NotNull java.lang.String name, final @org.jetbrains.annotations.NotNull de.sebastianhesse.examples.projen.test.StructProperties props, final @org.jetbrains.annotations.NotNull de.sebastianhesse.examples.projen.test.IBehaviorProperties props2) {
        super(software.amazon.jsii.JsiiObject.InitializationMode.JSII);
        software.amazon.jsii.JsiiEngine.getInstance().createNewObject(this, new Object[] { java.util.Objects.requireNonNull(parent, "parent is required"), java.util.Objects.requireNonNull(name, "name is required"), java.util.Objects.requireNonNull(props, "props is required"), java.util.Objects.requireNonNull(props2, "props2 is required") });
    }

    /**
     * A fluent builder for {@link de.sebastianhesse.examples.projen.test.ConstructWithProperties}.
     */
    @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
    public static final class Builder implements software.amazon.jsii.Builder {
        /**
         * @return a new instance of {@link Builder}.
         * @param parent This parameter is required.
         * @param name This parameter is required.
         * @param props2 This parameter is required.
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
        public static Builder create(final software.amazon.awscdk.core.Construct parent, final java.lang.String name, final de.sebastianhesse.examples.projen.test.IBehaviorProperties props2) {
            return new Builder(parent, name, props2);
        }

        private final software.amazon.awscdk.core.Construct parent;
        private final java.lang.String name;
        private final de.sebastianhesse.examples.projen.test.IBehaviorProperties props2;
        private final de.sebastianhesse.examples.projen.test.StructProperties.Builder props;

        private Builder(final software.amazon.awscdk.core.Construct parent, final java.lang.String name, final de.sebastianhesse.examples.projen.test.IBehaviorProperties props2) {
            this.parent = parent;
            this.name = name;
            this.props2 = props2;
            this.props = new de.sebastianhesse.examples.projen.test.StructProperties.Builder();
        }

        /**
         * @return {@code this}
         * @param myProp This parameter is required.
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
        public Builder myProp(final java.lang.String myProp) {
            this.props.myProp(myProp);
            return this;
        }

        /**
         * @returns a newly built instance of {@link de.sebastianhesse.examples.projen.test.ConstructWithProperties}.
         */
        @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Stable)
        @Override
        public de.sebastianhesse.examples.projen.test.ConstructWithProperties build() {
            return new de.sebastianhesse.examples.projen.test.ConstructWithProperties(
                this.parent,
                this.name,
                this.props.build(),
                this.props2
            );
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy