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

package com.azure.resourcemanager.mediaservices.models;

import com.azure.core.management.SystemData;
import com.azure.core.util.Context;
import com.azure.resourcemanager.mediaservices.fluent.models.StreamingPolicyInner;
import java.time.OffsetDateTime;

/** An immutable client-side representation of StreamingPolicy. */
public interface StreamingPolicy {
    /**
     * 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 systemData property: The system metadata relating to this resource.
     *
     * @return the systemData value.
     */
    SystemData systemData();

    /**
     * Gets the created property: Creation time of Streaming Policy.
     *
     * @return the created value.
     */
    OffsetDateTime created();

    /**
     * Gets the defaultContentKeyPolicyName property: Default ContentKey used by current Streaming Policy.
     *
     * @return the defaultContentKeyPolicyName value.
     */
    String defaultContentKeyPolicyName();

    /**
     * Gets the envelopeEncryption property: Configuration of EnvelopeEncryption.
     *
     * @return the envelopeEncryption value.
     */
    EnvelopeEncryption envelopeEncryption();

    /**
     * Gets the commonEncryptionCenc property: Configuration of CommonEncryptionCenc.
     *
     * @return the commonEncryptionCenc value.
     */
    CommonEncryptionCenc commonEncryptionCenc();

    /**
     * Gets the commonEncryptionCbcs property: Configuration of CommonEncryptionCbcs.
     *
     * @return the commonEncryptionCbcs value.
     */
    CommonEncryptionCbcs commonEncryptionCbcs();

    /**
     * Gets the noEncryption property: Configurations of NoEncryption.
     *
     * @return the noEncryption value.
     */
    NoEncryption noEncryption();

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

    /** The entirety of the StreamingPolicy definition. */
    interface Definition
        extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
    }
    /** The StreamingPolicy definition stages. */
    interface DefinitionStages {
        /** The first stage of the StreamingPolicy definition. */
        interface Blank extends WithParentResource {
        }
        /** The stage of the StreamingPolicy definition allowing to specify parent resource. */
        interface WithParentResource {
            /**
             * Specifies resourceGroupName, accountName.
             *
             * @param resourceGroupName The name of the resource group within the Azure subscription.
             * @param accountName The Media Services account name.
             * @return the next definition stage.
             */
            WithCreate withExistingMediaService(String resourceGroupName, String accountName);
        }
        /**
         * The stage of the StreamingPolicy 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.WithDefaultContentKeyPolicyName,
                DefinitionStages.WithEnvelopeEncryption,
                DefinitionStages.WithCommonEncryptionCenc,
                DefinitionStages.WithCommonEncryptionCbcs,
                DefinitionStages.WithNoEncryption {
            /**
             * Executes the create request.
             *
             * @return the created resource.
             */
            StreamingPolicy create();

            /**
             * Executes the create request.
             *
             * @param context The context to associate with this operation.
             * @return the created resource.
             */
            StreamingPolicy create(Context context);
        }
        /** The stage of the StreamingPolicy definition allowing to specify defaultContentKeyPolicyName. */
        interface WithDefaultContentKeyPolicyName {
            /**
             * Specifies the defaultContentKeyPolicyName property: Default ContentKey used by current Streaming Policy.
             *
             * @param defaultContentKeyPolicyName Default ContentKey used by current Streaming Policy.
             * @return the next definition stage.
             */
            WithCreate withDefaultContentKeyPolicyName(String defaultContentKeyPolicyName);
        }
        /** The stage of the StreamingPolicy definition allowing to specify envelopeEncryption. */
        interface WithEnvelopeEncryption {
            /**
             * Specifies the envelopeEncryption property: Configuration of EnvelopeEncryption.
             *
             * @param envelopeEncryption Configuration of EnvelopeEncryption.
             * @return the next definition stage.
             */
            WithCreate withEnvelopeEncryption(EnvelopeEncryption envelopeEncryption);
        }
        /** The stage of the StreamingPolicy definition allowing to specify commonEncryptionCenc. */
        interface WithCommonEncryptionCenc {
            /**
             * Specifies the commonEncryptionCenc property: Configuration of CommonEncryptionCenc.
             *
             * @param commonEncryptionCenc Configuration of CommonEncryptionCenc.
             * @return the next definition stage.
             */
            WithCreate withCommonEncryptionCenc(CommonEncryptionCenc commonEncryptionCenc);
        }
        /** The stage of the StreamingPolicy definition allowing to specify commonEncryptionCbcs. */
        interface WithCommonEncryptionCbcs {
            /**
             * Specifies the commonEncryptionCbcs property: Configuration of CommonEncryptionCbcs.
             *
             * @param commonEncryptionCbcs Configuration of CommonEncryptionCbcs.
             * @return the next definition stage.
             */
            WithCreate withCommonEncryptionCbcs(CommonEncryptionCbcs commonEncryptionCbcs);
        }
        /** The stage of the StreamingPolicy definition allowing to specify noEncryption. */
        interface WithNoEncryption {
            /**
             * Specifies the noEncryption property: Configurations of NoEncryption.
             *
             * @param noEncryption Configurations of NoEncryption.
             * @return the next definition stage.
             */
            WithCreate withNoEncryption(NoEncryption noEncryption);
        }
    }
    /**
     * Refreshes the resource to sync with Azure.
     *
     * @return the refreshed resource.
     */
    StreamingPolicy refresh();

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