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

package com.azure.resourcemanager.workloads.models;

import com.azure.core.management.Region;
import com.azure.core.management.SystemData;
import com.azure.core.util.Context;
import com.azure.resourcemanager.workloads.fluent.models.MonitorInner;
import java.util.Map;

/** An immutable client-side representation of Monitor. */
public interface Monitor {
    /**
     * Gets the id property: Fully qualified resource Id for the resource.
     *
     * @return the id value.
     */
    String id();

    /**
     * Gets the name property: The name of the resource.
     *
     * @return the name value.
     */
    String name();

    /**
     * Gets the type property: The type of the resource.
     *
     * @return the type value.
     */
    String type();

    /**
     * Gets the location property: The geo-location where the resource lives.
     *
     * @return the location value.
     */
    String location();

    /**
     * Gets the tags property: Resource tags.
     *
     * @return the tags value.
     */
    Map<String, String> tags();

    /**
     * Gets the identity property: [currently not in use] Managed service identity(user assigned identities).
     *
     * @return the identity value.
     */
    UserAssignedServiceIdentity identity();

    /**
     * Gets the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
     *
     * @return the systemData value.
     */
    SystemData systemData();

    /**
     * Gets the provisioningState property: State of provisioning of the SAP monitor.
     *
     * @return the provisioningState value.
     */
    WorkloadMonitorProvisioningState provisioningState();

    /**
     * Gets the errors property: Defines the SAP monitor errors.
     *
     * @return the errors value.
     */
    MonitorPropertiesErrors errors();

    /**
     * Gets the appLocation property: The SAP monitor resources will be deployed in the SAP monitoring region. The
     * subnet region should be same as the SAP monitoring region.
     *
     * @return the appLocation value.
     */
    String appLocation();

    /**
     * Gets the routingPreference property: Sets the routing preference of the SAP monitor. By default only RFC1918
     * traffic is routed to the customer VNET.
     *
     * @return the routingPreference value.
     */
    RoutingPreference routingPreference();

    /**
     * Gets the zoneRedundancyPreference property: Sets the preference for zone redundancy on resources created for the
     * SAP monitor. By default resources will be created which do not support zone redundancy.
     *
     * @return the zoneRedundancyPreference value.
     */
    String zoneRedundancyPreference();

    /**
     * Gets the managedResourceGroupConfiguration property: Managed resource group configuration.
     *
     * @return the managedResourceGroupConfiguration value.
     */
    ManagedRGConfiguration managedResourceGroupConfiguration();

    /**
     * Gets the logAnalyticsWorkspaceArmId property: The ARM ID of the Log Analytics Workspace that is used for SAP
     * monitoring.
     *
     * @return the logAnalyticsWorkspaceArmId value.
     */
    String logAnalyticsWorkspaceArmId();

    /**
     * Gets the monitorSubnet property: The subnet which the SAP monitor will be deployed in.
     *
     * @return the monitorSubnet value.
     */
    String monitorSubnet();

    /**
     * Gets the msiArmId property: The ARM ID of the MSI used for SAP monitoring.
     *
     * @return the msiArmId value.
     */
    String msiArmId();

    /**
     * Gets the storageAccountArmId property: The ARM ID of the Storage account used for SAP monitoring.
     *
     * @return the storageAccountArmId value.
     */
    String storageAccountArmId();

    /**
     * Gets the region of the resource.
     *
     * @return the region of the resource.
     */
    Region region();

    /**
     * Gets the name of the resource region.
     *
     * @return the name of the resource region.
     */
    String regionName();

    /**
     * Gets the name of the resource group.
     *
     * @return the name of the resource group.
     */
    String resourceGroupName();

    /**
     * Gets the inner com.azure.resourcemanager.workloads.fluent.models.MonitorInner object.
     *
     * @return the inner object.
     */
    MonitorInner innerModel();

    /** The entirety of the Monitor definition. */
    interface Definition
        extends DefinitionStages.Blank,
            DefinitionStages.WithLocation,
            DefinitionStages.WithResourceGroup,
            DefinitionStages.WithCreate {
    }
    /** The Monitor definition stages. */
    interface DefinitionStages {
        /** The first stage of the Monitor definition. */
        interface Blank extends WithLocation {
        }
        /** The stage of the Monitor definition allowing to specify location. */
        interface WithLocation {
            /**
             * Specifies the region for the resource.
             *
             * @param location The geo-location where the resource lives.
             * @return the next definition stage.
             */
            WithResourceGroup withRegion(Region location);

            /**
             * Specifies the region for the resource.
             *
             * @param location The geo-location where the resource lives.
             * @return the next definition stage.
             */
            WithResourceGroup withRegion(String location);
        }
        /** The stage of the Monitor definition allowing to specify parent resource. */
        interface WithResourceGroup {
            /**
             * Specifies resourceGroupName.
             *
             * @param resourceGroupName The name of the resource group. The name is case insensitive.
             * @return the next definition stage.
             */
            WithCreate withExistingResourceGroup(String resourceGroupName);
        }
        /**
         * The stage of the Monitor definition which contains all the minimum required properties for the resource to be
         * created, but also allows for any other optional properties to be specified.
         */
        interface WithCreate
            extends DefinitionStages.WithTags,
                DefinitionStages.WithIdentity,
                DefinitionStages.WithAppLocation,
                DefinitionStages.WithRoutingPreference,
                DefinitionStages.WithZoneRedundancyPreference,
                DefinitionStages.WithManagedResourceGroupConfiguration,
                DefinitionStages.WithLogAnalyticsWorkspaceArmId,
                DefinitionStages.WithMonitorSubnet {
            /**
             * Executes the create request.
             *
             * @return the created resource.
             */
            Monitor create();

            /**
             * Executes the create request.
             *
             * @param context The context to associate with this operation.
             * @return the created resource.
             */
            Monitor create(Context context);
        }
        /** The stage of the Monitor definition allowing to specify tags. */
        interface WithTags {
            /**
             * Specifies the tags property: Resource tags..
             *
             * @param tags Resource tags.
             * @return the next definition stage.
             */
            WithCreate withTags(Map<String, String> tags);
        }
        /** The stage of the Monitor definition allowing to specify identity. */
        interface WithIdentity {
            /**
             * Specifies the identity property: [currently not in use] Managed service identity(user assigned
             * identities).
             *
             * @param identity [currently not in use] Managed service identity(user assigned identities).
             * @return the next definition stage.
             */
            WithCreate withIdentity(UserAssignedServiceIdentity identity);
        }
        /** The stage of the Monitor definition allowing to specify appLocation. */
        interface WithAppLocation {
            /**
             * Specifies the appLocation property: The SAP monitor resources will be deployed in the SAP monitoring
             * region. The subnet region should be same as the SAP monitoring region..
             *
             * @param appLocation The SAP monitor resources will be deployed in the SAP monitoring region. The subnet
             *     region should be same as the SAP monitoring region.
             * @return the next definition stage.
             */
            WithCreate withAppLocation(String appLocation);
        }
        /** The stage of the Monitor definition allowing to specify routingPreference. */
        interface WithRoutingPreference {
            /**
             * Specifies the routingPreference property: Sets the routing preference of the SAP monitor. By default only
             * RFC1918 traffic is routed to the customer VNET..
             *
             * @param routingPreference Sets the routing preference of the SAP monitor. By default only RFC1918 traffic
             *     is routed to the customer VNET.
             * @return the next definition stage.
             */
            WithCreate withRoutingPreference(RoutingPreference routingPreference);
        }
        /** The stage of the Monitor definition allowing to specify zoneRedundancyPreference. */
        interface WithZoneRedundancyPreference {
            /**
             * Specifies the zoneRedundancyPreference property: Sets the preference for zone redundancy on resources
             * created for the SAP monitor. By default resources will be created which do not support zone redundancy..
             *
             * @param zoneRedundancyPreference Sets the preference for zone redundancy on resources created for the SAP
             *     monitor. By default resources will be created which do not support zone redundancy.
             * @return the next definition stage.
             */
            WithCreate withZoneRedundancyPreference(String zoneRedundancyPreference);
        }
        /** The stage of the Monitor definition allowing to specify managedResourceGroupConfiguration. */
        interface WithManagedResourceGroupConfiguration {
            /**
             * Specifies the managedResourceGroupConfiguration property: Managed resource group configuration.
             *
             * @param managedResourceGroupConfiguration Managed resource group configuration.
             * @return the next definition stage.
             */
            WithCreate withManagedResourceGroupConfiguration(ManagedRGConfiguration managedResourceGroupConfiguration);
        }
        /** The stage of the Monitor definition allowing to specify logAnalyticsWorkspaceArmId. */
        interface WithLogAnalyticsWorkspaceArmId {
            /**
             * Specifies the logAnalyticsWorkspaceArmId property: The ARM ID of the Log Analytics Workspace that is used
             * for SAP monitoring..
             *
             * @param logAnalyticsWorkspaceArmId The ARM ID of the Log Analytics Workspace that is used for SAP
             *     monitoring.
             * @return the next definition stage.
             */
            WithCreate withLogAnalyticsWorkspaceArmId(String logAnalyticsWorkspaceArmId);
        }
        /** The stage of the Monitor definition allowing to specify monitorSubnet. */
        interface WithMonitorSubnet {
            /**
             * Specifies the monitorSubnet property: The subnet which the SAP monitor will be deployed in.
             *
             * @param monitorSubnet The subnet which the SAP monitor will be deployed in.
             * @return the next definition stage.
             */
            WithCreate withMonitorSubnet(String monitorSubnet);
        }
    }
    /**
     * Begins update for the Monitor resource.
     *
     * @return the stage of resource update.
     */
    Monitor.Update update();

    /** The template for Monitor update. */
    interface Update extends UpdateStages.WithTags, UpdateStages.WithIdentity {
        /**
         * Executes the update request.
         *
         * @return the updated resource.
         */
        Monitor apply();

        /**
         * Executes the update request.
         *
         * @param context The context to associate with this operation.
         * @return the updated resource.
         */
        Monitor apply(Context context);
    }
    /** The Monitor update stages. */
    interface UpdateStages {
        /** The stage of the Monitor update allowing to specify tags. */
        interface WithTags {
            /**
             * Specifies the tags property: Gets or sets the Resource tags..
             *
             * @param tags Gets or sets the Resource tags.
             * @return the next definition stage.
             */
            Update withTags(Map<String, String> tags);
        }
        /** The stage of the Monitor update allowing to specify identity. */
        interface WithIdentity {
            /**
             * Specifies the identity property: [currently not in use] Managed service identity(user assigned
             * identities).
             *
             * @param identity [currently not in use] Managed service identity(user assigned identities).
             * @return the next definition stage.
             */
            Update withIdentity(UserAssignedServiceIdentity identity);
        }
    }
    /**
     * Refreshes the resource to sync with Azure.
     *
     * @return the refreshed resource.
     */
    Monitor refresh();

    /**
     * Refreshes the resource to sync with Azure.
     *
     * @param context The context to associate with this operation.
     * @return the refreshed resource.
     */
    Monitor refresh(Context context);
}
