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

package com.azure.resourcemanager.appplatform.generated;

import com.azure.core.util.Context;
import com.azure.resourcemanager.appplatform.models.ActiveDeploymentCollection;
import java.util.Arrays;

/** Samples for Apps SetActiveDeployments. */
public final class AppsSetActiveDeploymentsSamples {
    /*
     * x-ms-original-file: specification/appplatform/resource-manager/Microsoft.AppPlatform/stable/2022-12-01/examples/Apps_SetActiveDeployments.json
     */
    /**
     * Sample code: Apps_SetActiveDeployments.
     *
     * @param azure The entry point for accessing resource management APIs in Azure.
     */
    public static void appsSetActiveDeployments(com.azure.resourcemanager.AzureResourceManager azure) {
        azure
            .springServices()
            .manager()
            .serviceClient()
            .getApps()
            .setActiveDeployments(
                "myResourceGroup",
                "myservice",
                "myapp",
                new ActiveDeploymentCollection().withActiveDeploymentNames(Arrays.asList("default")),
                Context.NONE);
    }
}
