// 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.SystemData;
import com.azure.core.util.Context;
import com.azure.resourcemanager.workloads.fluent.models.ProviderInstanceInner;

/** An immutable client-side representation of ProviderInstance. */
public interface ProviderInstance {
    /**
     * 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 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 provider instance.
     *
     * @return the provisioningState value.
     */
    WorkloadMonitorProvisioningState provisioningState();

    /**
     * Gets the errors property: Defines the provider instance errors.
     *
     * @return the errors value.
     */
    ProviderInstancePropertiesErrors errors();

    /**
     * Gets the providerSettings property: Defines the provider specific properties.
     *
     * @return the providerSettings value.
     */
    ProviderSpecificProperties providerSettings();

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

    /** The entirety of the ProviderInstance definition. */
    interface Definition
        extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
    }
    /** The ProviderInstance definition stages. */
    interface DefinitionStages {
        /** The first stage of the ProviderInstance definition. */
        interface Blank extends WithParentResource {
        }
        /** The stage of the ProviderInstance definition allowing to specify parent resource. */
        interface WithParentResource {
            /**
             * Specifies resourceGroupName, monitorName.
             *
             * @param resourceGroupName The name of the resource group. The name is case insensitive.
             * @param monitorName Name of the SAP monitor resource.
             * @return the next definition stage.
             */
            WithCreate withExistingMonitor(String resourceGroupName, String monitorName);
        }
        /**
         * The stage of the ProviderInstance 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.WithIdentity, DefinitionStages.WithProviderSettings {
            /**
             * Executes the create request.
             *
             * @return the created resource.
             */
            ProviderInstance create();

            /**
             * Executes the create request.
             *
             * @param context The context to associate with this operation.
             * @return the created resource.
             */
            ProviderInstance create(Context context);
        }
        /** The stage of the ProviderInstance 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 ProviderInstance definition allowing to specify providerSettings. */
        interface WithProviderSettings {
            /**
             * Specifies the providerSettings property: Defines the provider specific properties..
             *
             * @param providerSettings Defines the provider specific properties.
             * @return the next definition stage.
             */
            WithCreate withProviderSettings(ProviderSpecificProperties providerSettings);
        }
    }
    /**
     * Refreshes the resource to sync with Azure.
     *
     * @return the refreshed resource.
     */
    ProviderInstance refresh();

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