// 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.JsonProperty;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.annotation.JsonTypeName;
import java.time.OffsetDateTime;
import java.util.List;

/** A2A provider specific settings. */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "instanceType")
@JsonTypeName("A2A")
@Fluent
public final class A2AReplicationDetails extends ReplicationProviderSpecificSettings {
    /*
     * The fabric specific object Id of the virtual machine.
     */
    @JsonProperty(value = "fabricObjectId")
    private String fabricObjectId;

    /*
     * The initial primary availability zone.
     */
    @JsonProperty(value = "initialPrimaryZone", access = JsonProperty.Access.WRITE_ONLY)
    private String initialPrimaryZone;

    /*
     * The initial primary fabric location.
     */
    @JsonProperty(value = "initialPrimaryFabricLocation", access = JsonProperty.Access.WRITE_ONLY)
    private String initialPrimaryFabricLocation;

    /*
     * The initial recovery availability zone.
     */
    @JsonProperty(value = "initialRecoveryZone", access = JsonProperty.Access.WRITE_ONLY)
    private String initialRecoveryZone;

    /*
     * The initial primary extended location.
     */
    @JsonProperty(value = "initialPrimaryExtendedLocation")
    private ExtendedLocation initialPrimaryExtendedLocation;

    /*
     * The initial recovery extended location.
     */
    @JsonProperty(value = "initialRecoveryExtendedLocation")
    private ExtendedLocation initialRecoveryExtendedLocation;

    /*
     * The initial recovery fabric location.
     */
    @JsonProperty(value = "initialRecoveryFabricLocation", access = JsonProperty.Access.WRITE_ONLY)
    private String initialRecoveryFabricLocation;

    /*
     * The multi vm group Id.
     */
    @JsonProperty(value = "multiVmGroupId")
    private String multiVmGroupId;

    /*
     * The multi vm group name.
     */
    @JsonProperty(value = "multiVmGroupName")
    private String multiVmGroupName;

    /*
     * Whether Multi VM group is auto created or specified by user.
     */
    @JsonProperty(value = "multiVmGroupCreateOption")
    private MultiVmGroupCreateOption multiVmGroupCreateOption;

    /*
     * The management Id.
     */
    @JsonProperty(value = "managementId")
    private String managementId;

    /*
     * The list of protected disks.
     */
    @JsonProperty(value = "protectedDisks")
    private List<A2AProtectedDiskDetails> protectedDisks;

    /*
     * The list of unprotected disks.
     */
    @JsonProperty(value = "unprotectedDisks")
    private List<A2AUnprotectedDiskDetails> unprotectedDisks;

    /*
     * The list of protected managed disks.
     */
    @JsonProperty(value = "protectedManagedDisks")
    private List<A2AProtectedManagedDiskDetails> protectedManagedDisks;

    /*
     * The recovery boot diagnostic storage account Arm Id.
     */
    @JsonProperty(value = "recoveryBootDiagStorageAccountId")
    private String recoveryBootDiagStorageAccountId;

    /*
     * Primary fabric location.
     */
    @JsonProperty(value = "primaryFabricLocation")
    private String primaryFabricLocation;

    /*
     * The recovery fabric location.
     */
    @JsonProperty(value = "recoveryFabricLocation")
    private String recoveryFabricLocation;

    /*
     * The type of operating system.
     */
    @JsonProperty(value = "osType")
    private String osType;

    /*
     * The size of recovery virtual machine.
     */
    @JsonProperty(value = "recoveryAzureVMSize")
    private String recoveryAzureVMSize;

    /*
     * The name of recovery virtual machine.
     */
    @JsonProperty(value = "recoveryAzureVMName")
    private String recoveryAzureVMName;

    /*
     * The recovery resource group.
     */
    @JsonProperty(value = "recoveryAzureResourceGroupId")
    private String recoveryAzureResourceGroupId;

    /*
     * The recovery cloud service.
     */
    @JsonProperty(value = "recoveryCloudService")
    private String recoveryCloudService;

    /*
     * The recovery availability set.
     */
    @JsonProperty(value = "recoveryAvailabilitySet")
    private String recoveryAvailabilitySet;

    /*
     * The recovery virtual network.
     */
    @JsonProperty(value = "selectedRecoveryAzureNetworkId")
    private String selectedRecoveryAzureNetworkId;

    /*
     * The test failover virtual network.
     */
    @JsonProperty(value = "selectedTfoAzureNetworkId")
    private String selectedTfoAzureNetworkId;

    /*
     * The virtual machine nic details.
     */
    @JsonProperty(value = "vmNics")
    private List<VMNicDetails> vmNics;

    /*
     * The synced configuration details.
     */
    @JsonProperty(value = "vmSyncedConfigDetails")
    private AzureToAzureVmSyncedConfigDetails vmSyncedConfigDetails;

    /*
     * The percentage of the monitoring job. The type of the monitoring job is defined by MonitoringJobType property.
     */
    @JsonProperty(value = "monitoringPercentageCompletion")
    private Integer monitoringPercentageCompletion;

    /*
     * The type of the monitoring job. The progress is contained in MonitoringPercentageCompletion property.
     */
    @JsonProperty(value = "monitoringJobType")
    private String monitoringJobType;

    /*
     * The last heartbeat received from the source server.
     */
    @JsonProperty(value = "lastHeartbeat")
    private OffsetDateTime lastHeartbeat;

    /*
     * The agent version.
     */
    @JsonProperty(value = "agentVersion")
    private String agentVersion;

    /*
     * Agent expiry date.
     */
    @JsonProperty(value = "agentExpiryDate")
    private OffsetDateTime agentExpiryDate;

    /*
     * A value indicating whether replication agent update is required.
     */
    @JsonProperty(value = "isReplicationAgentUpdateRequired")
    private Boolean isReplicationAgentUpdateRequired;

    /*
     * Agent certificate expiry date.
     */
    @JsonProperty(value = "agentCertificateExpiryDate", access = JsonProperty.Access.WRITE_ONLY)
    private OffsetDateTime agentCertificateExpiryDate;

    /*
     * A value indicating whether agent certificate update is required.
     */
    @JsonProperty(value = "isReplicationAgentCertificateUpdateRequired")
    private Boolean isReplicationAgentCertificateUpdateRequired;

    /*
     * The recovery fabric object Id.
     */
    @JsonProperty(value = "recoveryFabricObjectId")
    private String recoveryFabricObjectId;

    /*
     * The protection state for the vm.
     */
    @JsonProperty(value = "vmProtectionState")
    private String vmProtectionState;

    /*
     * The protection state description for the vm.
     */
    @JsonProperty(value = "vmProtectionStateDescription")
    private String vmProtectionStateDescription;

    /*
     * An id associated with the PE that survives actions like switch protection which change the backing PE/CPE
     * objects internally.The lifecycle id gets carried forward to have a link/continuity in being able to have an Id
     * that denotes the "same" protected item even though other internal Ids/ARM Id might be changing.
     */
    @JsonProperty(value = "lifecycleId")
    private String lifecycleId;

    /*
     * The test failover fabric object Id.
     */
    @JsonProperty(value = "testFailoverRecoveryFabricObjectId")
    private String testFailoverRecoveryFabricObjectId;

    /*
     * The last RPO value in seconds.
     */
    @JsonProperty(value = "rpoInSeconds")
    private Long rpoInSeconds;

    /*
     * The time (in UTC) when the last RPO value was calculated by Protection Service.
     */
    @JsonProperty(value = "lastRpoCalculatedTime")
    private OffsetDateTime lastRpoCalculatedTime;

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

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

    /*
     * The primary Extended Location.
     */
    @JsonProperty(value = "primaryExtendedLocation")
    private ExtendedLocation primaryExtendedLocation;

    /*
     * The recovery Extended Location.
     */
    @JsonProperty(value = "recoveryExtendedLocation")
    private ExtendedLocation recoveryExtendedLocation;

    /*
     * The encryption type of the VM.
     */
    @JsonProperty(value = "vmEncryptionType", access = JsonProperty.Access.WRITE_ONLY)
    private VmEncryptionType vmEncryptionType;

    /*
     * The test failover vm name.
     */
    @JsonProperty(value = "tfoAzureVMName")
    private String tfoAzureVMName;

    /*
     * The recovery azure generation.
     */
    @JsonProperty(value = "recoveryAzureGeneration", access = JsonProperty.Access.WRITE_ONLY)
    private String recoveryAzureGeneration;

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

    /*
     * A value indicating whether the auto protection is enabled.
     */
    @JsonProperty(value = "autoProtectionOfDataDisk")
    private AutoProtectionOfDataDisk autoProtectionOfDataDisk;

    /*
     * The recovery virtual machine scale set id.
     */
    @JsonProperty(value = "recoveryVirtualMachineScaleSetId")
    private String recoveryVirtualMachineScaleSetId;

    /*
     * The recovery capacity reservation group Id.
     */
    @JsonProperty(value = "recoveryCapacityReservationGroupId")
    private String recoveryCapacityReservationGroupId;

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

    /**
     * Get the fabricObjectId property: The fabric specific object Id of the virtual machine.
     *
     * @return the fabricObjectId value.
     */
    public String fabricObjectId() {
        return this.fabricObjectId;
    }

    /**
     * Set the fabricObjectId property: The fabric specific object Id of the virtual machine.
     *
     * @param fabricObjectId the fabricObjectId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withFabricObjectId(String fabricObjectId) {
        this.fabricObjectId = fabricObjectId;
        return this;
    }

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

    /**
     * Get the initialPrimaryFabricLocation property: The initial primary fabric location.
     *
     * @return the initialPrimaryFabricLocation value.
     */
    public String initialPrimaryFabricLocation() {
        return this.initialPrimaryFabricLocation;
    }

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

    /**
     * Get the initialPrimaryExtendedLocation property: The initial primary extended location.
     *
     * @return the initialPrimaryExtendedLocation value.
     */
    public ExtendedLocation initialPrimaryExtendedLocation() {
        return this.initialPrimaryExtendedLocation;
    }

    /**
     * Set the initialPrimaryExtendedLocation property: The initial primary extended location.
     *
     * @param initialPrimaryExtendedLocation the initialPrimaryExtendedLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withInitialPrimaryExtendedLocation(ExtendedLocation initialPrimaryExtendedLocation) {
        this.initialPrimaryExtendedLocation = initialPrimaryExtendedLocation;
        return this;
    }

    /**
     * Get the initialRecoveryExtendedLocation property: The initial recovery extended location.
     *
     * @return the initialRecoveryExtendedLocation value.
     */
    public ExtendedLocation initialRecoveryExtendedLocation() {
        return this.initialRecoveryExtendedLocation;
    }

    /**
     * Set the initialRecoveryExtendedLocation property: The initial recovery extended location.
     *
     * @param initialRecoveryExtendedLocation the initialRecoveryExtendedLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withInitialRecoveryExtendedLocation(ExtendedLocation initialRecoveryExtendedLocation) {
        this.initialRecoveryExtendedLocation = initialRecoveryExtendedLocation;
        return this;
    }

    /**
     * Get the initialRecoveryFabricLocation property: The initial recovery fabric location.
     *
     * @return the initialRecoveryFabricLocation value.
     */
    public String initialRecoveryFabricLocation() {
        return this.initialRecoveryFabricLocation;
    }

    /**
     * Get the multiVmGroupId property: The multi vm group Id.
     *
     * @return the multiVmGroupId value.
     */
    public String multiVmGroupId() {
        return this.multiVmGroupId;
    }

    /**
     * Set the multiVmGroupId property: The multi vm group Id.
     *
     * @param multiVmGroupId the multiVmGroupId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withMultiVmGroupId(String multiVmGroupId) {
        this.multiVmGroupId = multiVmGroupId;
        return this;
    }

    /**
     * Get the multiVmGroupName property: The multi vm group name.
     *
     * @return the multiVmGroupName value.
     */
    public String multiVmGroupName() {
        return this.multiVmGroupName;
    }

    /**
     * Set the multiVmGroupName property: The multi vm group name.
     *
     * @param multiVmGroupName the multiVmGroupName value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withMultiVmGroupName(String multiVmGroupName) {
        this.multiVmGroupName = multiVmGroupName;
        return this;
    }

    /**
     * Get the multiVmGroupCreateOption property: Whether Multi VM group is auto created or specified by user.
     *
     * @return the multiVmGroupCreateOption value.
     */
    public MultiVmGroupCreateOption multiVmGroupCreateOption() {
        return this.multiVmGroupCreateOption;
    }

    /**
     * Set the multiVmGroupCreateOption property: Whether Multi VM group is auto created or specified by user.
     *
     * @param multiVmGroupCreateOption the multiVmGroupCreateOption value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withMultiVmGroupCreateOption(MultiVmGroupCreateOption multiVmGroupCreateOption) {
        this.multiVmGroupCreateOption = multiVmGroupCreateOption;
        return this;
    }

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

    /**
     * Set the managementId property: The management Id.
     *
     * @param managementId the managementId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withManagementId(String managementId) {
        this.managementId = managementId;
        return this;
    }

    /**
     * Get the protectedDisks property: The list of protected disks.
     *
     * @return the protectedDisks value.
     */
    public List<A2AProtectedDiskDetails> protectedDisks() {
        return this.protectedDisks;
    }

    /**
     * Set the protectedDisks property: The list of protected disks.
     *
     * @param protectedDisks the protectedDisks value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withProtectedDisks(List<A2AProtectedDiskDetails> protectedDisks) {
        this.protectedDisks = protectedDisks;
        return this;
    }

    /**
     * Get the unprotectedDisks property: The list of unprotected disks.
     *
     * @return the unprotectedDisks value.
     */
    public List<A2AUnprotectedDiskDetails> unprotectedDisks() {
        return this.unprotectedDisks;
    }

    /**
     * Set the unprotectedDisks property: The list of unprotected disks.
     *
     * @param unprotectedDisks the unprotectedDisks value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withUnprotectedDisks(List<A2AUnprotectedDiskDetails> unprotectedDisks) {
        this.unprotectedDisks = unprotectedDisks;
        return this;
    }

    /**
     * Get the protectedManagedDisks property: The list of protected managed disks.
     *
     * @return the protectedManagedDisks value.
     */
    public List<A2AProtectedManagedDiskDetails> protectedManagedDisks() {
        return this.protectedManagedDisks;
    }

    /**
     * Set the protectedManagedDisks property: The list of protected managed disks.
     *
     * @param protectedManagedDisks the protectedManagedDisks value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withProtectedManagedDisks(List<A2AProtectedManagedDiskDetails> protectedManagedDisks) {
        this.protectedManagedDisks = protectedManagedDisks;
        return this;
    }

    /**
     * Get the recoveryBootDiagStorageAccountId property: The recovery boot diagnostic storage account Arm Id.
     *
     * @return the recoveryBootDiagStorageAccountId value.
     */
    public String recoveryBootDiagStorageAccountId() {
        return this.recoveryBootDiagStorageAccountId;
    }

    /**
     * Set the recoveryBootDiagStorageAccountId property: The recovery boot diagnostic storage account Arm Id.
     *
     * @param recoveryBootDiagStorageAccountId the recoveryBootDiagStorageAccountId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryBootDiagStorageAccountId(String recoveryBootDiagStorageAccountId) {
        this.recoveryBootDiagStorageAccountId = recoveryBootDiagStorageAccountId;
        return this;
    }

    /**
     * Get the primaryFabricLocation property: Primary fabric location.
     *
     * @return the primaryFabricLocation value.
     */
    public String primaryFabricLocation() {
        return this.primaryFabricLocation;
    }

    /**
     * Set the primaryFabricLocation property: Primary fabric location.
     *
     * @param primaryFabricLocation the primaryFabricLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withPrimaryFabricLocation(String primaryFabricLocation) {
        this.primaryFabricLocation = primaryFabricLocation;
        return this;
    }

    /**
     * Get the recoveryFabricLocation property: The recovery fabric location.
     *
     * @return the recoveryFabricLocation value.
     */
    public String recoveryFabricLocation() {
        return this.recoveryFabricLocation;
    }

    /**
     * Set the recoveryFabricLocation property: The recovery fabric location.
     *
     * @param recoveryFabricLocation the recoveryFabricLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryFabricLocation(String recoveryFabricLocation) {
        this.recoveryFabricLocation = recoveryFabricLocation;
        return this;
    }

    /**
     * Get the osType property: The type of operating system.
     *
     * @return the osType value.
     */
    public String osType() {
        return this.osType;
    }

    /**
     * Set the osType property: The type of operating system.
     *
     * @param osType the osType value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withOsType(String osType) {
        this.osType = osType;
        return this;
    }

    /**
     * Get the recoveryAzureVMSize property: The size of recovery virtual machine.
     *
     * @return the recoveryAzureVMSize value.
     */
    public String recoveryAzureVMSize() {
        return this.recoveryAzureVMSize;
    }

    /**
     * Set the recoveryAzureVMSize property: The size of recovery virtual machine.
     *
     * @param recoveryAzureVMSize the recoveryAzureVMSize value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryAzureVMSize(String recoveryAzureVMSize) {
        this.recoveryAzureVMSize = recoveryAzureVMSize;
        return this;
    }

    /**
     * Get the recoveryAzureVMName property: The name of recovery virtual machine.
     *
     * @return the recoveryAzureVMName value.
     */
    public String recoveryAzureVMName() {
        return this.recoveryAzureVMName;
    }

    /**
     * Set the recoveryAzureVMName property: The name of recovery virtual machine.
     *
     * @param recoveryAzureVMName the recoveryAzureVMName value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryAzureVMName(String recoveryAzureVMName) {
        this.recoveryAzureVMName = recoveryAzureVMName;
        return this;
    }

    /**
     * Get the recoveryAzureResourceGroupId property: The recovery resource group.
     *
     * @return the recoveryAzureResourceGroupId value.
     */
    public String recoveryAzureResourceGroupId() {
        return this.recoveryAzureResourceGroupId;
    }

    /**
     * Set the recoveryAzureResourceGroupId property: The recovery resource group.
     *
     * @param recoveryAzureResourceGroupId the recoveryAzureResourceGroupId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryAzureResourceGroupId(String recoveryAzureResourceGroupId) {
        this.recoveryAzureResourceGroupId = recoveryAzureResourceGroupId;
        return this;
    }

    /**
     * Get the recoveryCloudService property: The recovery cloud service.
     *
     * @return the recoveryCloudService value.
     */
    public String recoveryCloudService() {
        return this.recoveryCloudService;
    }

    /**
     * Set the recoveryCloudService property: The recovery cloud service.
     *
     * @param recoveryCloudService the recoveryCloudService value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryCloudService(String recoveryCloudService) {
        this.recoveryCloudService = recoveryCloudService;
        return this;
    }

    /**
     * Get the recoveryAvailabilitySet property: The recovery availability set.
     *
     * @return the recoveryAvailabilitySet value.
     */
    public String recoveryAvailabilitySet() {
        return this.recoveryAvailabilitySet;
    }

    /**
     * Set the recoveryAvailabilitySet property: The recovery availability set.
     *
     * @param recoveryAvailabilitySet the recoveryAvailabilitySet value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryAvailabilitySet(String recoveryAvailabilitySet) {
        this.recoveryAvailabilitySet = recoveryAvailabilitySet;
        return this;
    }

    /**
     * Get the selectedRecoveryAzureNetworkId property: The recovery virtual network.
     *
     * @return the selectedRecoveryAzureNetworkId value.
     */
    public String selectedRecoveryAzureNetworkId() {
        return this.selectedRecoveryAzureNetworkId;
    }

    /**
     * Set the selectedRecoveryAzureNetworkId property: The recovery virtual network.
     *
     * @param selectedRecoveryAzureNetworkId the selectedRecoveryAzureNetworkId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withSelectedRecoveryAzureNetworkId(String selectedRecoveryAzureNetworkId) {
        this.selectedRecoveryAzureNetworkId = selectedRecoveryAzureNetworkId;
        return this;
    }

    /**
     * Get the selectedTfoAzureNetworkId property: The test failover virtual network.
     *
     * @return the selectedTfoAzureNetworkId value.
     */
    public String selectedTfoAzureNetworkId() {
        return this.selectedTfoAzureNetworkId;
    }

    /**
     * Set the selectedTfoAzureNetworkId property: The test failover virtual network.
     *
     * @param selectedTfoAzureNetworkId the selectedTfoAzureNetworkId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withSelectedTfoAzureNetworkId(String selectedTfoAzureNetworkId) {
        this.selectedTfoAzureNetworkId = selectedTfoAzureNetworkId;
        return this;
    }

    /**
     * Get the vmNics property: The virtual machine nic details.
     *
     * @return the vmNics value.
     */
    public List<VMNicDetails> vmNics() {
        return this.vmNics;
    }

    /**
     * Set the vmNics property: The virtual machine nic details.
     *
     * @param vmNics the vmNics value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withVmNics(List<VMNicDetails> vmNics) {
        this.vmNics = vmNics;
        return this;
    }

    /**
     * Get the vmSyncedConfigDetails property: The synced configuration details.
     *
     * @return the vmSyncedConfigDetails value.
     */
    public AzureToAzureVmSyncedConfigDetails vmSyncedConfigDetails() {
        return this.vmSyncedConfigDetails;
    }

    /**
     * Set the vmSyncedConfigDetails property: The synced configuration details.
     *
     * @param vmSyncedConfigDetails the vmSyncedConfigDetails value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withVmSyncedConfigDetails(AzureToAzureVmSyncedConfigDetails vmSyncedConfigDetails) {
        this.vmSyncedConfigDetails = vmSyncedConfigDetails;
        return this;
    }

    /**
     * Get the monitoringPercentageCompletion property: The percentage of the monitoring job. The type of the monitoring
     * job is defined by MonitoringJobType property.
     *
     * @return the monitoringPercentageCompletion value.
     */
    public Integer monitoringPercentageCompletion() {
        return this.monitoringPercentageCompletion;
    }

    /**
     * Set the monitoringPercentageCompletion property: The percentage of the monitoring job. The type of the monitoring
     * job is defined by MonitoringJobType property.
     *
     * @param monitoringPercentageCompletion the monitoringPercentageCompletion value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withMonitoringPercentageCompletion(Integer monitoringPercentageCompletion) {
        this.monitoringPercentageCompletion = monitoringPercentageCompletion;
        return this;
    }

    /**
     * Get the monitoringJobType property: The type of the monitoring job. The progress is contained in
     * MonitoringPercentageCompletion property.
     *
     * @return the monitoringJobType value.
     */
    public String monitoringJobType() {
        return this.monitoringJobType;
    }

    /**
     * Set the monitoringJobType property: The type of the monitoring job. The progress is contained in
     * MonitoringPercentageCompletion property.
     *
     * @param monitoringJobType the monitoringJobType value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withMonitoringJobType(String monitoringJobType) {
        this.monitoringJobType = monitoringJobType;
        return this;
    }

    /**
     * Get the lastHeartbeat property: The last heartbeat received from the source server.
     *
     * @return the lastHeartbeat value.
     */
    public OffsetDateTime lastHeartbeat() {
        return this.lastHeartbeat;
    }

    /**
     * Set the lastHeartbeat property: The last heartbeat received from the source server.
     *
     * @param lastHeartbeat the lastHeartbeat value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withLastHeartbeat(OffsetDateTime lastHeartbeat) {
        this.lastHeartbeat = lastHeartbeat;
        return this;
    }

    /**
     * Get the agentVersion property: The agent version.
     *
     * @return the agentVersion value.
     */
    public String agentVersion() {
        return this.agentVersion;
    }

    /**
     * Set the agentVersion property: The agent version.
     *
     * @param agentVersion the agentVersion value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withAgentVersion(String agentVersion) {
        this.agentVersion = agentVersion;
        return this;
    }

    /**
     * Get the agentExpiryDate property: Agent expiry date.
     *
     * @return the agentExpiryDate value.
     */
    public OffsetDateTime agentExpiryDate() {
        return this.agentExpiryDate;
    }

    /**
     * Set the agentExpiryDate property: Agent expiry date.
     *
     * @param agentExpiryDate the agentExpiryDate value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withAgentExpiryDate(OffsetDateTime agentExpiryDate) {
        this.agentExpiryDate = agentExpiryDate;
        return this;
    }

    /**
     * Get the isReplicationAgentUpdateRequired property: A value indicating whether replication agent update is
     * required.
     *
     * @return the isReplicationAgentUpdateRequired value.
     */
    public Boolean isReplicationAgentUpdateRequired() {
        return this.isReplicationAgentUpdateRequired;
    }

    /**
     * Set the isReplicationAgentUpdateRequired property: A value indicating whether replication agent update is
     * required.
     *
     * @param isReplicationAgentUpdateRequired the isReplicationAgentUpdateRequired value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withIsReplicationAgentUpdateRequired(Boolean isReplicationAgentUpdateRequired) {
        this.isReplicationAgentUpdateRequired = isReplicationAgentUpdateRequired;
        return this;
    }

    /**
     * Get the agentCertificateExpiryDate property: Agent certificate expiry date.
     *
     * @return the agentCertificateExpiryDate value.
     */
    public OffsetDateTime agentCertificateExpiryDate() {
        return this.agentCertificateExpiryDate;
    }

    /**
     * Get the isReplicationAgentCertificateUpdateRequired property: A value indicating whether agent certificate update
     * is required.
     *
     * @return the isReplicationAgentCertificateUpdateRequired value.
     */
    public Boolean isReplicationAgentCertificateUpdateRequired() {
        return this.isReplicationAgentCertificateUpdateRequired;
    }

    /**
     * Set the isReplicationAgentCertificateUpdateRequired property: A value indicating whether agent certificate update
     * is required.
     *
     * @param isReplicationAgentCertificateUpdateRequired the isReplicationAgentCertificateUpdateRequired value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withIsReplicationAgentCertificateUpdateRequired(
        Boolean isReplicationAgentCertificateUpdateRequired) {
        this.isReplicationAgentCertificateUpdateRequired = isReplicationAgentCertificateUpdateRequired;
        return this;
    }

    /**
     * Get the recoveryFabricObjectId property: The recovery fabric object Id.
     *
     * @return the recoveryFabricObjectId value.
     */
    public String recoveryFabricObjectId() {
        return this.recoveryFabricObjectId;
    }

    /**
     * Set the recoveryFabricObjectId property: The recovery fabric object Id.
     *
     * @param recoveryFabricObjectId the recoveryFabricObjectId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryFabricObjectId(String recoveryFabricObjectId) {
        this.recoveryFabricObjectId = recoveryFabricObjectId;
        return this;
    }

    /**
     * Get the vmProtectionState property: The protection state for the vm.
     *
     * @return the vmProtectionState value.
     */
    public String vmProtectionState() {
        return this.vmProtectionState;
    }

    /**
     * Set the vmProtectionState property: The protection state for the vm.
     *
     * @param vmProtectionState the vmProtectionState value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withVmProtectionState(String vmProtectionState) {
        this.vmProtectionState = vmProtectionState;
        return this;
    }

    /**
     * Get the vmProtectionStateDescription property: The protection state description for the vm.
     *
     * @return the vmProtectionStateDescription value.
     */
    public String vmProtectionStateDescription() {
        return this.vmProtectionStateDescription;
    }

    /**
     * Set the vmProtectionStateDescription property: The protection state description for the vm.
     *
     * @param vmProtectionStateDescription the vmProtectionStateDescription value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withVmProtectionStateDescription(String vmProtectionStateDescription) {
        this.vmProtectionStateDescription = vmProtectionStateDescription;
        return this;
    }

    /**
     * Get the lifecycleId property: An id associated with the PE that survives actions like switch protection which
     * change the backing PE/CPE objects internally.The lifecycle id gets carried forward to have a link/continuity in
     * being able to have an Id that denotes the "same" protected item even though other internal Ids/ARM Id might be
     * changing.
     *
     * @return the lifecycleId value.
     */
    public String lifecycleId() {
        return this.lifecycleId;
    }

    /**
     * Set the lifecycleId property: An id associated with the PE that survives actions like switch protection which
     * change the backing PE/CPE objects internally.The lifecycle id gets carried forward to have a link/continuity in
     * being able to have an Id that denotes the "same" protected item even though other internal Ids/ARM Id might be
     * changing.
     *
     * @param lifecycleId the lifecycleId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withLifecycleId(String lifecycleId) {
        this.lifecycleId = lifecycleId;
        return this;
    }

    /**
     * Get the testFailoverRecoveryFabricObjectId property: The test failover fabric object Id.
     *
     * @return the testFailoverRecoveryFabricObjectId value.
     */
    public String testFailoverRecoveryFabricObjectId() {
        return this.testFailoverRecoveryFabricObjectId;
    }

    /**
     * Set the testFailoverRecoveryFabricObjectId property: The test failover fabric object Id.
     *
     * @param testFailoverRecoveryFabricObjectId the testFailoverRecoveryFabricObjectId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withTestFailoverRecoveryFabricObjectId(String testFailoverRecoveryFabricObjectId) {
        this.testFailoverRecoveryFabricObjectId = testFailoverRecoveryFabricObjectId;
        return this;
    }

    /**
     * Get the rpoInSeconds property: The last RPO value in seconds.
     *
     * @return the rpoInSeconds value.
     */
    public Long rpoInSeconds() {
        return this.rpoInSeconds;
    }

    /**
     * Set the rpoInSeconds property: The last RPO value in seconds.
     *
     * @param rpoInSeconds the rpoInSeconds value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRpoInSeconds(Long rpoInSeconds) {
        this.rpoInSeconds = rpoInSeconds;
        return this;
    }

    /**
     * Get the lastRpoCalculatedTime property: The time (in UTC) when the last RPO value was calculated by Protection
     * Service.
     *
     * @return the lastRpoCalculatedTime value.
     */
    public OffsetDateTime lastRpoCalculatedTime() {
        return this.lastRpoCalculatedTime;
    }

    /**
     * Set the lastRpoCalculatedTime property: The time (in UTC) when the last RPO value was calculated by Protection
     * Service.
     *
     * @param lastRpoCalculatedTime the lastRpoCalculatedTime value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withLastRpoCalculatedTime(OffsetDateTime lastRpoCalculatedTime) {
        this.lastRpoCalculatedTime = lastRpoCalculatedTime;
        return this;
    }

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

    /**
     * Set the primaryAvailabilityZone property: The primary availability zone.
     *
     * @param primaryAvailabilityZone the primaryAvailabilityZone value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withPrimaryAvailabilityZone(String primaryAvailabilityZone) {
        this.primaryAvailabilityZone = primaryAvailabilityZone;
        return this;
    }

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

    /**
     * Set the recoveryAvailabilityZone property: The recovery availability zone.
     *
     * @param recoveryAvailabilityZone the recoveryAvailabilityZone value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryAvailabilityZone(String recoveryAvailabilityZone) {
        this.recoveryAvailabilityZone = recoveryAvailabilityZone;
        return this;
    }

    /**
     * Get the primaryExtendedLocation property: The primary Extended Location.
     *
     * @return the primaryExtendedLocation value.
     */
    public ExtendedLocation primaryExtendedLocation() {
        return this.primaryExtendedLocation;
    }

    /**
     * Set the primaryExtendedLocation property: The primary Extended Location.
     *
     * @param primaryExtendedLocation the primaryExtendedLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withPrimaryExtendedLocation(ExtendedLocation primaryExtendedLocation) {
        this.primaryExtendedLocation = primaryExtendedLocation;
        return this;
    }

    /**
     * Get the recoveryExtendedLocation property: The recovery Extended Location.
     *
     * @return the recoveryExtendedLocation value.
     */
    public ExtendedLocation recoveryExtendedLocation() {
        return this.recoveryExtendedLocation;
    }

    /**
     * Set the recoveryExtendedLocation property: The recovery Extended Location.
     *
     * @param recoveryExtendedLocation the recoveryExtendedLocation value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryExtendedLocation(ExtendedLocation recoveryExtendedLocation) {
        this.recoveryExtendedLocation = recoveryExtendedLocation;
        return this;
    }

    /**
     * Get the vmEncryptionType property: The encryption type of the VM.
     *
     * @return the vmEncryptionType value.
     */
    public VmEncryptionType vmEncryptionType() {
        return this.vmEncryptionType;
    }

    /**
     * Get the tfoAzureVMName property: The test failover vm name.
     *
     * @return the tfoAzureVMName value.
     */
    public String tfoAzureVMName() {
        return this.tfoAzureVMName;
    }

    /**
     * Set the tfoAzureVMName property: The test failover vm name.
     *
     * @param tfoAzureVMName the tfoAzureVMName value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withTfoAzureVMName(String tfoAzureVMName) {
        this.tfoAzureVMName = tfoAzureVMName;
        return this;
    }

    /**
     * Get the recoveryAzureGeneration property: The recovery azure generation.
     *
     * @return the recoveryAzureGeneration value.
     */
    public String recoveryAzureGeneration() {
        return this.recoveryAzureGeneration;
    }

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

    /**
     * Set the recoveryProximityPlacementGroupId property: The recovery proximity placement group Id.
     *
     * @param recoveryProximityPlacementGroupId the recoveryProximityPlacementGroupId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryProximityPlacementGroupId(String recoveryProximityPlacementGroupId) {
        this.recoveryProximityPlacementGroupId = recoveryProximityPlacementGroupId;
        return this;
    }

    /**
     * Get the autoProtectionOfDataDisk property: A value indicating whether the auto protection is enabled.
     *
     * @return the autoProtectionOfDataDisk value.
     */
    public AutoProtectionOfDataDisk autoProtectionOfDataDisk() {
        return this.autoProtectionOfDataDisk;
    }

    /**
     * Set the autoProtectionOfDataDisk property: A value indicating whether the auto protection is enabled.
     *
     * @param autoProtectionOfDataDisk the autoProtectionOfDataDisk value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withAutoProtectionOfDataDisk(AutoProtectionOfDataDisk autoProtectionOfDataDisk) {
        this.autoProtectionOfDataDisk = autoProtectionOfDataDisk;
        return this;
    }

    /**
     * Get the recoveryVirtualMachineScaleSetId property: The recovery virtual machine scale set id.
     *
     * @return the recoveryVirtualMachineScaleSetId value.
     */
    public String recoveryVirtualMachineScaleSetId() {
        return this.recoveryVirtualMachineScaleSetId;
    }

    /**
     * Set the recoveryVirtualMachineScaleSetId property: The recovery virtual machine scale set id.
     *
     * @param recoveryVirtualMachineScaleSetId the recoveryVirtualMachineScaleSetId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryVirtualMachineScaleSetId(String recoveryVirtualMachineScaleSetId) {
        this.recoveryVirtualMachineScaleSetId = recoveryVirtualMachineScaleSetId;
        return this;
    }

    /**
     * Get the recoveryCapacityReservationGroupId property: The recovery capacity reservation group Id.
     *
     * @return the recoveryCapacityReservationGroupId value.
     */
    public String recoveryCapacityReservationGroupId() {
        return this.recoveryCapacityReservationGroupId;
    }

    /**
     * Set the recoveryCapacityReservationGroupId property: The recovery capacity reservation group Id.
     *
     * @param recoveryCapacityReservationGroupId the recoveryCapacityReservationGroupId value to set.
     * @return the A2AReplicationDetails object itself.
     */
    public A2AReplicationDetails withRecoveryCapacityReservationGroupId(String recoveryCapacityReservationGroupId) {
        this.recoveryCapacityReservationGroupId = recoveryCapacityReservationGroupId;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    @Override
    public void validate() {
        super.validate();
        if (initialPrimaryExtendedLocation() != null) {
            initialPrimaryExtendedLocation().validate();
        }
        if (initialRecoveryExtendedLocation() != null) {
            initialRecoveryExtendedLocation().validate();
        }
        if (protectedDisks() != null) {
            protectedDisks().forEach(e -> e.validate());
        }
        if (unprotectedDisks() != null) {
            unprotectedDisks().forEach(e -> e.validate());
        }
        if (protectedManagedDisks() != null) {
            protectedManagedDisks().forEach(e -> e.validate());
        }
        if (vmNics() != null) {
            vmNics().forEach(e -> e.validate());
        }
        if (vmSyncedConfigDetails() != null) {
            vmSyncedConfigDetails().validate();
        }
        if (primaryExtendedLocation() != null) {
            primaryExtendedLocation().validate();
        }
        if (recoveryExtendedLocation() != null) {
            recoveryExtendedLocation().validate();
        }
    }
}
