// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azure.backup.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class ProtectedVMState extends com.pulumi.resources.ResourceArgs {

    public static final ProtectedVMState Empty = new ProtectedVMState();

    /**
     * Specifies the id of the backup policy to use. Required in creation or when `protection_stopped` is not specified.
     * 
     */
    @Import(name="backupPolicyId")
    private @Nullable Output<String> backupPolicyId;

    /**
     * @return Specifies the id of the backup policy to use. Required in creation or when `protection_stopped` is not specified.
     * 
     */
    public Optional<Output<String>> backupPolicyId() {
        return Optional.ofNullable(this.backupPolicyId);
    }

    /**
     * A list of Disks&#39; Logical Unit Numbers(LUN) to be excluded for VM Protection.
     * 
     */
    @Import(name="excludeDiskLuns")
    private @Nullable Output<List<Integer>> excludeDiskLuns;

    /**
     * @return A list of Disks&#39; Logical Unit Numbers(LUN) to be excluded for VM Protection.
     * 
     */
    public Optional<Output<List<Integer>>> excludeDiskLuns() {
        return Optional.ofNullable(this.excludeDiskLuns);
    }

    /**
     * A list of Disks&#39; Logical Unit Numbers(LUN) to be included for VM Protection.
     * 
     */
    @Import(name="includeDiskLuns")
    private @Nullable Output<List<Integer>> includeDiskLuns;

    /**
     * @return A list of Disks&#39; Logical Unit Numbers(LUN) to be included for VM Protection.
     * 
     */
    public Optional<Output<List<Integer>>> includeDiskLuns() {
        return Optional.ofNullable(this.includeDiskLuns);
    }

    /**
     * Specifies Protection state of the backup. Possible values are `Invalid`, `IRPending`, `Protected`, `ProtectionStopped`, `ProtectionError` and `ProtectionPaused`.
     * 
     */
    @Import(name="protectionState")
    private @Nullable Output<String> protectionState;

    /**
     * @return Specifies Protection state of the backup. Possible values are `Invalid`, `IRPending`, `Protected`, `ProtectionStopped`, `ProtectionError` and `ProtectionPaused`.
     * 
     */
    public Optional<Output<String>> protectionState() {
        return Optional.ofNullable(this.protectionState);
    }

    /**
     * Specifies the name of the Recovery Services Vault to use. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="recoveryVaultName")
    private @Nullable Output<String> recoveryVaultName;

    /**
     * @return Specifies the name of the Recovery Services Vault to use. Changing this forces a new resource to be created.
     * 
     */
    public Optional<Output<String>> recoveryVaultName() {
        return Optional.ofNullable(this.recoveryVaultName);
    }

    /**
     * The name of the resource group in which to create the Recovery Services Vault. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="resourceGroupName")
    private @Nullable Output<String> resourceGroupName;

    /**
     * @return The name of the resource group in which to create the Recovery Services Vault. Changing this forces a new resource to be created.
     * 
     */
    public Optional<Output<String>> resourceGroupName() {
        return Optional.ofNullable(this.resourceGroupName);
    }

    /**
     * Specifies the ID of the VM to backup. Changing this forces a new resource to be created.
     * 
     * &gt; **NOTE:** After creation, the `source_vm_id` property can be removed without forcing a new resource to be created; however, setting it to a different ID will create a new resource.
     * This allows the source vm to be deleted without having to remove the backup.
     * 
     */
    @Import(name="sourceVmId")
    private @Nullable Output<String> sourceVmId;

    /**
     * @return Specifies the ID of the VM to backup. Changing this forces a new resource to be created.
     * 
     * &gt; **NOTE:** After creation, the `source_vm_id` property can be removed without forcing a new resource to be created; however, setting it to a different ID will create a new resource.
     * This allows the source vm to be deleted without having to remove the backup.
     * 
     */
    public Optional<Output<String>> sourceVmId() {
        return Optional.ofNullable(this.sourceVmId);
    }

    private ProtectedVMState() {}

    private ProtectedVMState(ProtectedVMState $) {
        this.backupPolicyId = $.backupPolicyId;
        this.excludeDiskLuns = $.excludeDiskLuns;
        this.includeDiskLuns = $.includeDiskLuns;
        this.protectionState = $.protectionState;
        this.recoveryVaultName = $.recoveryVaultName;
        this.resourceGroupName = $.resourceGroupName;
        this.sourceVmId = $.sourceVmId;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(ProtectedVMState defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private ProtectedVMState $;

        public Builder() {
            $ = new ProtectedVMState();
        }

        public Builder(ProtectedVMState defaults) {
            $ = new ProtectedVMState(Objects.requireNonNull(defaults));
        }

        /**
         * @param backupPolicyId Specifies the id of the backup policy to use. Required in creation or when `protection_stopped` is not specified.
         * 
         * @return builder
         * 
         */
        public Builder backupPolicyId(@Nullable Output<String> backupPolicyId) {
            $.backupPolicyId = backupPolicyId;
            return this;
        }

        /**
         * @param backupPolicyId Specifies the id of the backup policy to use. Required in creation or when `protection_stopped` is not specified.
         * 
         * @return builder
         * 
         */
        public Builder backupPolicyId(String backupPolicyId) {
            return backupPolicyId(Output.of(backupPolicyId));
        }

        /**
         * @param excludeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be excluded for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder excludeDiskLuns(@Nullable Output<List<Integer>> excludeDiskLuns) {
            $.excludeDiskLuns = excludeDiskLuns;
            return this;
        }

        /**
         * @param excludeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be excluded for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder excludeDiskLuns(List<Integer> excludeDiskLuns) {
            return excludeDiskLuns(Output.of(excludeDiskLuns));
        }

        /**
         * @param excludeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be excluded for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder excludeDiskLuns(Integer... excludeDiskLuns) {
            return excludeDiskLuns(List.of(excludeDiskLuns));
        }

        /**
         * @param includeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be included for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder includeDiskLuns(@Nullable Output<List<Integer>> includeDiskLuns) {
            $.includeDiskLuns = includeDiskLuns;
            return this;
        }

        /**
         * @param includeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be included for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder includeDiskLuns(List<Integer> includeDiskLuns) {
            return includeDiskLuns(Output.of(includeDiskLuns));
        }

        /**
         * @param includeDiskLuns A list of Disks&#39; Logical Unit Numbers(LUN) to be included for VM Protection.
         * 
         * @return builder
         * 
         */
        public Builder includeDiskLuns(Integer... includeDiskLuns) {
            return includeDiskLuns(List.of(includeDiskLuns));
        }

        /**
         * @param protectionState Specifies Protection state of the backup. Possible values are `Invalid`, `IRPending`, `Protected`, `ProtectionStopped`, `ProtectionError` and `ProtectionPaused`.
         * 
         * @return builder
         * 
         */
        public Builder protectionState(@Nullable Output<String> protectionState) {
            $.protectionState = protectionState;
            return this;
        }

        /**
         * @param protectionState Specifies Protection state of the backup. Possible values are `Invalid`, `IRPending`, `Protected`, `ProtectionStopped`, `ProtectionError` and `ProtectionPaused`.
         * 
         * @return builder
         * 
         */
        public Builder protectionState(String protectionState) {
            return protectionState(Output.of(protectionState));
        }

        /**
         * @param recoveryVaultName Specifies the name of the Recovery Services Vault to use. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder recoveryVaultName(@Nullable Output<String> recoveryVaultName) {
            $.recoveryVaultName = recoveryVaultName;
            return this;
        }

        /**
         * @param recoveryVaultName Specifies the name of the Recovery Services Vault to use. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder recoveryVaultName(String recoveryVaultName) {
            return recoveryVaultName(Output.of(recoveryVaultName));
        }

        /**
         * @param resourceGroupName The name of the resource group in which to create the Recovery Services Vault. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(@Nullable Output<String> resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group in which to create the Recovery Services Vault. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param sourceVmId Specifies the ID of the VM to backup. Changing this forces a new resource to be created.
         * 
         * &gt; **NOTE:** After creation, the `source_vm_id` property can be removed without forcing a new resource to be created; however, setting it to a different ID will create a new resource.
         * This allows the source vm to be deleted without having to remove the backup.
         * 
         * @return builder
         * 
         */
        public Builder sourceVmId(@Nullable Output<String> sourceVmId) {
            $.sourceVmId = sourceVmId;
            return this;
        }

        /**
         * @param sourceVmId Specifies the ID of the VM to backup. Changing this forces a new resource to be created.
         * 
         * &gt; **NOTE:** After creation, the `source_vm_id` property can be removed without forcing a new resource to be created; however, setting it to a different ID will create a new resource.
         * This allows the source vm to be deleted without having to remove the backup.
         * 
         * @return builder
         * 
         */
        public Builder sourceVmId(String sourceVmId) {
            return sourceVmId(Output.of(sourceVmId));
        }

        public ProtectedVMState build() {
            return $;
        }
    }

}
