All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.microsoft.azure.management.eventhub.AuthorizationRule Maven / Gradle / Ivy

Go to download

This package contains Microsoft EventHub Management SDK. This package has been deprecated. A replacement package com.azure.resourcemanager:azure-resourcemanager-eventhubs is available as of 31-March-2022. We strongly encourage you to upgrade to continue receiving updates. See Migration Guide https://aka.ms/java-track2-migration-guide for guidance on upgrading. Refer to our deprecation policy https://azure.github.io/azure-sdk/policies_support.html for more details.

There is a newer version: 1.41.4
Show newest version
/**
 * Copyright (c) Microsoft Corporation. All rights reserved.
 * Licensed under the MIT License. See License.txt in the project root for
 * license information.
 */

package com.microsoft.azure.management.eventhub;

import com.microsoft.azure.management.apigeneration.Beta;
import com.microsoft.azure.management.apigeneration.Fluent;
import com.microsoft.azure.management.eventhub.implementation.AuthorizationRuleInner;
import com.microsoft.azure.management.eventhub.implementation.EventHubManager;
import com.microsoft.azure.management.resources.fluentcore.arm.models.HasManager;
import com.microsoft.azure.management.resources.fluentcore.model.HasInner;
import com.microsoft.azure.management.resources.fluentcore.model.Refreshable;
import rx.Observable;

import java.util.List;

/**
 * The base type representing authorization rule of event hub namespace and event hub.
 *
 * @param  the specific authorization rule type
 */
@Fluent
@Beta(Beta.SinceVersion.V1_7_0)
public interface AuthorizationRule> extends
        NestedResource, HasInner, HasManager,
        Refreshable {
    /**
     * @return rights associated with the authorization rule
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    List rights();
    /**
     * @return a representation of the deferred computation of this call, returning access keys (primary, secondary) and the connection strings
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    Observable getKeysAsync();
    /**
     * @return the access keys (primary, secondary) and the connection strings
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    EventHubAuthorizationKey getKeys();
    /**
     * Regenerates primary or secondary access keys.
     *
     * @param keyType the key to regenerate
     * @return a representation of the deferred computation of this call, returning access keys (primary, secondary) and the connection strings
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    Observable regenerateKeyAsync(KeyType keyType);
    /**
     * Regenerates primary or secondary keys.
     *
     * @param keyType the key to regenerate
     * @return the access keys (primary, secondary) and the connection strings
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    EventHubAuthorizationKey regenerateKey(KeyType keyType);

    /**
     * Grouping of commons authorization rule definition stages shared between event hub namespace authorization rule and event hub authorization rule.
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    interface DefinitionStages {
        /**
         * The stage of the event hub namespace or event hub authorization rule definition allowing to enable listen policy.
         *
         * @param  the next stage of the definition
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithListen {
            /**
             * Specifies that the rule should have listening access enabled.
             *
             * @return the next stage of the definition
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withListenAccess();
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule definition allowing to enable send policy.
         *
         * @param  the next stage of the definition
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithSend {
            /**
             * Specifies that the rule should have sending access enabled.
             *
             * @return the next stage of the definition
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withSendAccess();
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule definition allowing to enable manage policy.
         *
         * @param  the next stage of the definition
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithManage {
            /**
             * Specifies that the rule should have management access enabled.
             *
             * @return the next stage of the definition
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withManageAccess();
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule definition allowing to enable send or manage policy.
         *
         * @param  the next stage of the definition
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithSendOrManage extends WithSend, WithManage {
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule definition allowing to enable listen, send or manage policy.
         *
         * @param  the next stage of the definition
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithListenOrSendOrManage extends WithListen, WithSendOrManage {
            /**
             * Specifies that the rule should have sending and listening access enabled.
             *
             * @return the next stage of the definition
             */
            @Beta(Beta.SinceVersion.V1_30_0)
            T withSendAndListenAccess();
        }
    }

    /**
     * Grouping of commons authorization rule update stages shared between event hub namespace authorization rule and event hub authorization rule.
     */
    @Beta(Beta.SinceVersion.V1_7_0)
    interface UpdateStages {
        /**
         * The stage of the event hub namespace or event hub authorization rule update allowing to enable listen policy.
         *
         * @param  the next stage of the update
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithListen {
            /**
             * Specifies that the rule should have listening access enabled.
             *
             * @return the next stage of the update
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withListenAccess();
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule update allowing to enable send policy.
         *
         * @param  the next stage of the update
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithSend {
            /**
             * Specifies that the rule should have sending access enabled.
             *
             * @return the next stage of the update
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withSendAccess();
        }

        /**
         * The stage of event hub namespace or event hub authorization rule update allowing to enable manage policy.
         *
         * @param  the next stage of the update
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithManage {
            /**
             * Specifies that the rule should have sending access enabled.
             *
             * @return the next stage of the update
             */
            @Beta(Beta.SinceVersion.V1_7_0)
            T withManageAccess();
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule update allowing to enable send or manage policy.
         *
         * @param  the next stage of the update
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithSendOrManage extends WithSend, WithManage {
        }

        /**
         * The stage of the event hub namespace or event hub authorization rule update allowing to enable listen, send or manage policy.
         *
         * @param  the next stage of the update
         */
        @Beta(Beta.SinceVersion.V1_7_0)
        interface WithListenOrSendOrManage extends WithListen, WithSendOrManage {
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy