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

package com.azure.resourcemanager.peering.models;

import com.azure.core.util.Context;
import com.azure.resourcemanager.peering.fluent.models.PeeringRegisteredAsnInner;

/** An immutable client-side representation of PeeringRegisteredAsn. */
public interface PeeringRegisteredAsn {
    /**
     * 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 asn property: The customer's ASN from which traffic originates.
     *
     * @return the asn value.
     */
    Integer asn();

    /**
     * Gets the peeringServicePrefixKey property: The peering service prefix key that is to be shared with the customer.
     *
     * @return the peeringServicePrefixKey value.
     */
    String peeringServicePrefixKey();

    /**
     * Gets the provisioningState property: The provisioning state of the resource.
     *
     * @return the provisioningState value.
     */
    ProvisioningState provisioningState();

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

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

    /** The entirety of the PeeringRegisteredAsn definition. */
    interface Definition
        extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
    }
    /** The PeeringRegisteredAsn definition stages. */
    interface DefinitionStages {
        /** The first stage of the PeeringRegisteredAsn definition. */
        interface Blank extends WithParentResource {
        }
        /** The stage of the PeeringRegisteredAsn definition allowing to specify parent resource. */
        interface WithParentResource {
            /**
             * Specifies resourceGroupName, peeringName.
             *
             * @param resourceGroupName The name of the resource group.
             * @param peeringName The name of the peering.
             * @return the next definition stage.
             */
            WithCreate withExistingPeering(String resourceGroupName, String peeringName);
        }
        /**
         * The stage of the PeeringRegisteredAsn 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.WithAsn {
            /**
             * Executes the create request.
             *
             * @return the created resource.
             */
            PeeringRegisteredAsn create();

            /**
             * Executes the create request.
             *
             * @param context The context to associate with this operation.
             * @return the created resource.
             */
            PeeringRegisteredAsn create(Context context);
        }
        /** The stage of the PeeringRegisteredAsn definition allowing to specify asn. */
        interface WithAsn {
            /**
             * Specifies the asn property: The customer's ASN from which traffic originates..
             *
             * @param asn The customer's ASN from which traffic originates.
             * @return the next definition stage.
             */
            WithCreate withAsn(Integer asn);
        }
    }
    /**
     * Begins update for the PeeringRegisteredAsn resource.
     *
     * @return the stage of resource update.
     */
    PeeringRegisteredAsn.Update update();

    /** The template for PeeringRegisteredAsn update. */
    interface Update extends UpdateStages.WithAsn {
        /**
         * Executes the update request.
         *
         * @return the updated resource.
         */
        PeeringRegisteredAsn apply();

        /**
         * Executes the update request.
         *
         * @param context The context to associate with this operation.
         * @return the updated resource.
         */
        PeeringRegisteredAsn apply(Context context);
    }
    /** The PeeringRegisteredAsn update stages. */
    interface UpdateStages {
        /** The stage of the PeeringRegisteredAsn update allowing to specify asn. */
        interface WithAsn {
            /**
             * Specifies the asn property: The customer's ASN from which traffic originates..
             *
             * @param asn The customer's ASN from which traffic originates.
             * @return the next definition stage.
             */
            Update withAsn(Integer asn);
        }
    }
    /**
     * Refreshes the resource to sync with Azure.
     *
     * @return the refreshed resource.
     */
    PeeringRegisteredAsn refresh();

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