// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.recoveryservicessiterecovery.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.annotation.JsonTypeName;
import java.util.List;
import java.util.Map;

/** HyperVReplicaAzure specific enable protection input. */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "instanceType")
@JsonTypeName("HyperVReplicaAzure")
@Fluent
public final class HyperVReplicaAzureEnableProtectionInput extends EnableProtectionProviderSpecificInput {
    /*
     * The Hyper-V host VM Id.
     */
    @JsonProperty(value = "hvHostVmId")
    private String hvHostVmId;

    /*
     * The VM Name.
     */
    @JsonProperty(value = "vmName")
    private String vmName;

    /*
     * The OS type associated with VM.
     */
    @JsonProperty(value = "osType")
    private String osType;

    /*
     * The OS disk VHD id associated with VM.
     */
    @JsonProperty(value = "vhdId")
    private String vhdId;

    /*
     * The storage account Id.
     */
    @JsonProperty(value = "targetStorageAccountId")
    private String targetStorageAccountId;

    /*
     * The selected target Azure network Id.
     */
    @JsonProperty(value = "targetAzureNetworkId")
    private String targetAzureNetworkId;

    /*
     * The selected target Azure subnet Id.
     */
    @JsonProperty(value = "targetAzureSubnetId")
    private String targetAzureSubnetId;

    /*
     * The selected option to enable RDP\SSH on target vm after failover. String value of
     * SrsDataContract.EnableRDPOnTargetOption enum.
     */
    @JsonProperty(value = "enableRdpOnTargetOption")
    private String enableRdpOnTargetOption;

    /*
     * The target azure VM Name.
     */
    @JsonProperty(value = "targetAzureVmName")
    private String targetAzureVmName;

    /*
     * The storage account to be used for logging during replication.
     */
    @JsonProperty(value = "logStorageAccountId")
    private String logStorageAccountId;

    /*
     * The list of VHD Ids of disks to be protected.
     */
    @JsonProperty(value = "disksToInclude")
    private List<String> disksToInclude;

    /*
     * The Id of the target resource group (for classic deployment) in which the failover VM is to be created.
     */
    @JsonProperty(value = "targetAzureV1ResourceGroupId")
    private String targetAzureV1ResourceGroupId;

    /*
     * The Id of the target resource group (for resource manager deployment) in which the failover VM is to be created.
     */
    @JsonProperty(value = "targetAzureV2ResourceGroupId")
    private String targetAzureV2ResourceGroupId;

    /*
     * A value indicating whether managed disks should be used during failover.
     */
    @JsonProperty(value = "useManagedDisks")
    private String useManagedDisks;

    /*
     * The target availability set ARM Id for resource manager deployment.
     */
    @JsonProperty(value = "targetAvailabilitySetId")
    private String targetAvailabilitySetId;

    /*
     * The target availability zone.
     */
    @JsonProperty(value = "targetAvailabilityZone")
    private String targetAvailabilityZone;

    /*
     * License type.
     */
    @JsonProperty(value = "licenseType")
    private LicenseType licenseType;

    /*
     * The SQL Server license type.
     */
    @JsonProperty(value = "sqlServerLicenseType")
    private SqlServerLicenseType sqlServerLicenseType;

    /*
     * The target VM size.
     */
    @JsonProperty(value = "targetVmSize")
    private String targetVmSize;

    /*
     * The proximity placement group ARM Id.
     */
    @JsonProperty(value = "targetProximityPlacementGroupId")
    private String targetProximityPlacementGroupId;

    /*
     * A value indicating whether managed disks should be used during replication.
     */
    @JsonProperty(value = "useManagedDisksForReplication")
    private String useManagedDisksForReplication;

    /*
     * The DiskType.
     */
    @JsonProperty(value = "diskType")
    private DiskAccountType diskType;

    /*
     * The disks to include list for managed disks.
     */
    @JsonProperty(value = "disksToIncludeForManagedDisks")
    private List<HyperVReplicaAzureDiskInputDetails> disksToIncludeForManagedDisks;

    /*
     * The DiskEncryptionSet ARM Id.
     */
    @JsonProperty(value = "diskEncryptionSetId")
    private String diskEncryptionSetId;

    /*
     * The target VM tags.
     */
    @JsonProperty(value = "targetVmTags")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> targetVmTags;

    /*
     * The tags for the seed managed disks.
     */
    @JsonProperty(value = "seedManagedDiskTags")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> seedManagedDiskTags;

    /*
     * The tags for the target managed disks.
     */
    @JsonProperty(value = "targetManagedDiskTags")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> targetManagedDiskTags;

    /*
     * The tags for the target NICs.
     */
    @JsonProperty(value = "targetNicTags")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> targetNicTags;

    /** Creates an instance of HyperVReplicaAzureEnableProtectionInput class. */
    public HyperVReplicaAzureEnableProtectionInput() {
    }

    /**
     * Get the hvHostVmId property: The Hyper-V host VM Id.
     *
     * @return the hvHostVmId value.
     */
    public String hvHostVmId() {
        return this.hvHostVmId;
    }

    /**
     * Set the hvHostVmId property: The Hyper-V host VM Id.
     *
     * @param hvHostVmId the hvHostVmId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withHvHostVmId(String hvHostVmId) {
        this.hvHostVmId = hvHostVmId;
        return this;
    }

    /**
     * Get the vmName property: The VM Name.
     *
     * @return the vmName value.
     */
    public String vmName() {
        return this.vmName;
    }

    /**
     * Set the vmName property: The VM Name.
     *
     * @param vmName the vmName value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withVmName(String vmName) {
        this.vmName = vmName;
        return this;
    }

    /**
     * Get the osType property: The OS type associated with VM.
     *
     * @return the osType value.
     */
    public String osType() {
        return this.osType;
    }

    /**
     * Set the osType property: The OS type associated with VM.
     *
     * @param osType the osType value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withOsType(String osType) {
        this.osType = osType;
        return this;
    }

    /**
     * Get the vhdId property: The OS disk VHD id associated with VM.
     *
     * @return the vhdId value.
     */
    public String vhdId() {
        return this.vhdId;
    }

    /**
     * Set the vhdId property: The OS disk VHD id associated with VM.
     *
     * @param vhdId the vhdId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withVhdId(String vhdId) {
        this.vhdId = vhdId;
        return this;
    }

    /**
     * Get the targetStorageAccountId property: The storage account Id.
     *
     * @return the targetStorageAccountId value.
     */
    public String targetStorageAccountId() {
        return this.targetStorageAccountId;
    }

    /**
     * Set the targetStorageAccountId property: The storage account Id.
     *
     * @param targetStorageAccountId the targetStorageAccountId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetStorageAccountId(String targetStorageAccountId) {
        this.targetStorageAccountId = targetStorageAccountId;
        return this;
    }

    /**
     * Get the targetAzureNetworkId property: The selected target Azure network Id.
     *
     * @return the targetAzureNetworkId value.
     */
    public String targetAzureNetworkId() {
        return this.targetAzureNetworkId;
    }

    /**
     * Set the targetAzureNetworkId property: The selected target Azure network Id.
     *
     * @param targetAzureNetworkId the targetAzureNetworkId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAzureNetworkId(String targetAzureNetworkId) {
        this.targetAzureNetworkId = targetAzureNetworkId;
        return this;
    }

    /**
     * Get the targetAzureSubnetId property: The selected target Azure subnet Id.
     *
     * @return the targetAzureSubnetId value.
     */
    public String targetAzureSubnetId() {
        return this.targetAzureSubnetId;
    }

    /**
     * Set the targetAzureSubnetId property: The selected target Azure subnet Id.
     *
     * @param targetAzureSubnetId the targetAzureSubnetId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAzureSubnetId(String targetAzureSubnetId) {
        this.targetAzureSubnetId = targetAzureSubnetId;
        return this;
    }

    /**
     * Get the enableRdpOnTargetOption property: The selected option to enable RDP\SSH on target vm after failover.
     * String value of SrsDataContract.EnableRDPOnTargetOption enum.
     *
     * @return the enableRdpOnTargetOption value.
     */
    public String enableRdpOnTargetOption() {
        return this.enableRdpOnTargetOption;
    }

    /**
     * Set the enableRdpOnTargetOption property: The selected option to enable RDP\SSH on target vm after failover.
     * String value of SrsDataContract.EnableRDPOnTargetOption enum.
     *
     * @param enableRdpOnTargetOption the enableRdpOnTargetOption value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withEnableRdpOnTargetOption(String enableRdpOnTargetOption) {
        this.enableRdpOnTargetOption = enableRdpOnTargetOption;
        return this;
    }

    /**
     * Get the targetAzureVmName property: The target azure VM Name.
     *
     * @return the targetAzureVmName value.
     */
    public String targetAzureVmName() {
        return this.targetAzureVmName;
    }

    /**
     * Set the targetAzureVmName property: The target azure VM Name.
     *
     * @param targetAzureVmName the targetAzureVmName value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAzureVmName(String targetAzureVmName) {
        this.targetAzureVmName = targetAzureVmName;
        return this;
    }

    /**
     * Get the logStorageAccountId property: The storage account to be used for logging during replication.
     *
     * @return the logStorageAccountId value.
     */
    public String logStorageAccountId() {
        return this.logStorageAccountId;
    }

    /**
     * Set the logStorageAccountId property: The storage account to be used for logging during replication.
     *
     * @param logStorageAccountId the logStorageAccountId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withLogStorageAccountId(String logStorageAccountId) {
        this.logStorageAccountId = logStorageAccountId;
        return this;
    }

    /**
     * Get the disksToInclude property: The list of VHD Ids of disks to be protected.
     *
     * @return the disksToInclude value.
     */
    public List<String> disksToInclude() {
        return this.disksToInclude;
    }

    /**
     * Set the disksToInclude property: The list of VHD Ids of disks to be protected.
     *
     * @param disksToInclude the disksToInclude value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withDisksToInclude(List<String> disksToInclude) {
        this.disksToInclude = disksToInclude;
        return this;
    }

    /**
     * Get the targetAzureV1ResourceGroupId property: The Id of the target resource group (for classic deployment) in
     * which the failover VM is to be created.
     *
     * @return the targetAzureV1ResourceGroupId value.
     */
    public String targetAzureV1ResourceGroupId() {
        return this.targetAzureV1ResourceGroupId;
    }

    /**
     * Set the targetAzureV1ResourceGroupId property: The Id of the target resource group (for classic deployment) in
     * which the failover VM is to be created.
     *
     * @param targetAzureV1ResourceGroupId the targetAzureV1ResourceGroupId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAzureV1ResourceGroupId(
        String targetAzureV1ResourceGroupId) {
        this.targetAzureV1ResourceGroupId = targetAzureV1ResourceGroupId;
        return this;
    }

    /**
     * Get the targetAzureV2ResourceGroupId property: The Id of the target resource group (for resource manager
     * deployment) in which the failover VM is to be created.
     *
     * @return the targetAzureV2ResourceGroupId value.
     */
    public String targetAzureV2ResourceGroupId() {
        return this.targetAzureV2ResourceGroupId;
    }

    /**
     * Set the targetAzureV2ResourceGroupId property: The Id of the target resource group (for resource manager
     * deployment) in which the failover VM is to be created.
     *
     * @param targetAzureV2ResourceGroupId the targetAzureV2ResourceGroupId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAzureV2ResourceGroupId(
        String targetAzureV2ResourceGroupId) {
        this.targetAzureV2ResourceGroupId = targetAzureV2ResourceGroupId;
        return this;
    }

    /**
     * Get the useManagedDisks property: A value indicating whether managed disks should be used during failover.
     *
     * @return the useManagedDisks value.
     */
    public String useManagedDisks() {
        return this.useManagedDisks;
    }

    /**
     * Set the useManagedDisks property: A value indicating whether managed disks should be used during failover.
     *
     * @param useManagedDisks the useManagedDisks value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withUseManagedDisks(String useManagedDisks) {
        this.useManagedDisks = useManagedDisks;
        return this;
    }

    /**
     * Get the targetAvailabilitySetId property: The target availability set ARM Id for resource manager deployment.
     *
     * @return the targetAvailabilitySetId value.
     */
    public String targetAvailabilitySetId() {
        return this.targetAvailabilitySetId;
    }

    /**
     * Set the targetAvailabilitySetId property: The target availability set ARM Id for resource manager deployment.
     *
     * @param targetAvailabilitySetId the targetAvailabilitySetId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAvailabilitySetId(String targetAvailabilitySetId) {
        this.targetAvailabilitySetId = targetAvailabilitySetId;
        return this;
    }

    /**
     * Get the targetAvailabilityZone property: The target availability zone.
     *
     * @return the targetAvailabilityZone value.
     */
    public String targetAvailabilityZone() {
        return this.targetAvailabilityZone;
    }

    /**
     * Set the targetAvailabilityZone property: The target availability zone.
     *
     * @param targetAvailabilityZone the targetAvailabilityZone value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetAvailabilityZone(String targetAvailabilityZone) {
        this.targetAvailabilityZone = targetAvailabilityZone;
        return this;
    }

    /**
     * Get the licenseType property: License type.
     *
     * @return the licenseType value.
     */
    public LicenseType licenseType() {
        return this.licenseType;
    }

    /**
     * Set the licenseType property: License type.
     *
     * @param licenseType the licenseType value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withLicenseType(LicenseType licenseType) {
        this.licenseType = licenseType;
        return this;
    }

    /**
     * Get the sqlServerLicenseType property: The SQL Server license type.
     *
     * @return the sqlServerLicenseType value.
     */
    public SqlServerLicenseType sqlServerLicenseType() {
        return this.sqlServerLicenseType;
    }

    /**
     * Set the sqlServerLicenseType property: The SQL Server license type.
     *
     * @param sqlServerLicenseType the sqlServerLicenseType value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withSqlServerLicenseType(SqlServerLicenseType sqlServerLicenseType) {
        this.sqlServerLicenseType = sqlServerLicenseType;
        return this;
    }

    /**
     * Get the targetVmSize property: The target VM size.
     *
     * @return the targetVmSize value.
     */
    public String targetVmSize() {
        return this.targetVmSize;
    }

    /**
     * Set the targetVmSize property: The target VM size.
     *
     * @param targetVmSize the targetVmSize value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetVmSize(String targetVmSize) {
        this.targetVmSize = targetVmSize;
        return this;
    }

    /**
     * Get the targetProximityPlacementGroupId property: The proximity placement group ARM Id.
     *
     * @return the targetProximityPlacementGroupId value.
     */
    public String targetProximityPlacementGroupId() {
        return this.targetProximityPlacementGroupId;
    }

    /**
     * Set the targetProximityPlacementGroupId property: The proximity placement group ARM Id.
     *
     * @param targetProximityPlacementGroupId the targetProximityPlacementGroupId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetProximityPlacementGroupId(
        String targetProximityPlacementGroupId) {
        this.targetProximityPlacementGroupId = targetProximityPlacementGroupId;
        return this;
    }

    /**
     * Get the useManagedDisksForReplication property: A value indicating whether managed disks should be used during
     * replication.
     *
     * @return the useManagedDisksForReplication value.
     */
    public String useManagedDisksForReplication() {
        return this.useManagedDisksForReplication;
    }

    /**
     * Set the useManagedDisksForReplication property: A value indicating whether managed disks should be used during
     * replication.
     *
     * @param useManagedDisksForReplication the useManagedDisksForReplication value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withUseManagedDisksForReplication(
        String useManagedDisksForReplication) {
        this.useManagedDisksForReplication = useManagedDisksForReplication;
        return this;
    }

    /**
     * Get the diskType property: The DiskType.
     *
     * @return the diskType value.
     */
    public DiskAccountType diskType() {
        return this.diskType;
    }

    /**
     * Set the diskType property: The DiskType.
     *
     * @param diskType the diskType value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withDiskType(DiskAccountType diskType) {
        this.diskType = diskType;
        return this;
    }

    /**
     * Get the disksToIncludeForManagedDisks property: The disks to include list for managed disks.
     *
     * @return the disksToIncludeForManagedDisks value.
     */
    public List<HyperVReplicaAzureDiskInputDetails> disksToIncludeForManagedDisks() {
        return this.disksToIncludeForManagedDisks;
    }

    /**
     * Set the disksToIncludeForManagedDisks property: The disks to include list for managed disks.
     *
     * @param disksToIncludeForManagedDisks the disksToIncludeForManagedDisks value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withDisksToIncludeForManagedDisks(
        List<HyperVReplicaAzureDiskInputDetails> disksToIncludeForManagedDisks) {
        this.disksToIncludeForManagedDisks = disksToIncludeForManagedDisks;
        return this;
    }

    /**
     * Get the diskEncryptionSetId property: The DiskEncryptionSet ARM Id.
     *
     * @return the diskEncryptionSetId value.
     */
    public String diskEncryptionSetId() {
        return this.diskEncryptionSetId;
    }

    /**
     * Set the diskEncryptionSetId property: The DiskEncryptionSet ARM Id.
     *
     * @param diskEncryptionSetId the diskEncryptionSetId value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withDiskEncryptionSetId(String diskEncryptionSetId) {
        this.diskEncryptionSetId = diskEncryptionSetId;
        return this;
    }

    /**
     * Get the targetVmTags property: The target VM tags.
     *
     * @return the targetVmTags value.
     */
    public Map<String, String> targetVmTags() {
        return this.targetVmTags;
    }

    /**
     * Set the targetVmTags property: The target VM tags.
     *
     * @param targetVmTags the targetVmTags value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetVmTags(Map<String, String> targetVmTags) {
        this.targetVmTags = targetVmTags;
        return this;
    }

    /**
     * Get the seedManagedDiskTags property: The tags for the seed managed disks.
     *
     * @return the seedManagedDiskTags value.
     */
    public Map<String, String> seedManagedDiskTags() {
        return this.seedManagedDiskTags;
    }

    /**
     * Set the seedManagedDiskTags property: The tags for the seed managed disks.
     *
     * @param seedManagedDiskTags the seedManagedDiskTags value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withSeedManagedDiskTags(Map<String, String> seedManagedDiskTags) {
        this.seedManagedDiskTags = seedManagedDiskTags;
        return this;
    }

    /**
     * Get the targetManagedDiskTags property: The tags for the target managed disks.
     *
     * @return the targetManagedDiskTags value.
     */
    public Map<String, String> targetManagedDiskTags() {
        return this.targetManagedDiskTags;
    }

    /**
     * Set the targetManagedDiskTags property: The tags for the target managed disks.
     *
     * @param targetManagedDiskTags the targetManagedDiskTags value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetManagedDiskTags(
        Map<String, String> targetManagedDiskTags) {
        this.targetManagedDiskTags = targetManagedDiskTags;
        return this;
    }

    /**
     * Get the targetNicTags property: The tags for the target NICs.
     *
     * @return the targetNicTags value.
     */
    public Map<String, String> targetNicTags() {
        return this.targetNicTags;
    }

    /**
     * Set the targetNicTags property: The tags for the target NICs.
     *
     * @param targetNicTags the targetNicTags value to set.
     * @return the HyperVReplicaAzureEnableProtectionInput object itself.
     */
    public HyperVReplicaAzureEnableProtectionInput withTargetNicTags(Map<String, String> targetNicTags) {
        this.targetNicTags = targetNicTags;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    @Override
    public void validate() {
        super.validate();
        if (disksToIncludeForManagedDisks() != null) {
            disksToIncludeForManagedDisks().forEach(e -> e.validate());
        }
    }
}
