// SPDX-License-Identifier: Apache-2.0
/**
 * Options for the `kind cluster create` command.
 */
export class ClusterCreateOptions {
    /**
     * If set, pass config to the kind create cluster command.
     */
    _config;
    /**
     * The Docker image to use for booting the cluster.
     */
    _image;
    /**
     * The name of the cluster.
     */
    _name;
    /**
     * If set, retain nodes for debugging when cluster creation fails.
     */
    _retain;
    /**
     * The duration to wait for the control plane node to be ready.
     */
    _wait;
    constructor(config, image, name, retain = false, wait) {
        if (config) {
            this._config = config;
        }
        if (image) {
            this._image = image;
        }
        if (name) {
            this._name = name;
        }
        this._retain = retain;
        if (wait) {
            this._wait = wait;
        }
    }
    /**
     * Apply the options to the KindExecutionBuilder.
     * @param builder The KindExecutionBuilder to apply options to.
     */
    apply(builder) {
        if (this._config) {
            builder.argument('config', this._config);
        }
        if (this._image) {
            builder.argument('image', this._image);
        }
        if (this._name) {
            builder.argument('name', this._name);
        }
        if (this._retain) {
            builder.flag('retain');
        }
        if (this._wait) {
            builder.argument('wait', this._wait);
        }
    }
    /**
     * The value of the config flag.
     */
    get config() {
        return this._config;
    }
    /**
     * The Docker image to use for booting the cluster.
     */
    get image() {
        return this._image;
    }
    /**
     * The name of the cluster.
     */
    get name() {
        return this._name;
    }
    /**
     * If set, retain nodes for debugging when cluster creation fails.
     */
    get retain() {
        return this._retain;
    }
    /**
     * The duration to wait for the control plane node to be ready.
     */
    get wait() {
        return this._wait;
    }
}
//# sourceMappingURL=cluster-create-options.js.map