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

package com.azure.resourcemanager.security.models;

import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;

/** Resource collection API of IngestionSettings. */
public interface IngestionSettings {
    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return list of ingestion settings as paginated response with {@link PagedIterable}.
     */
    PagedIterable<IngestionSetting> list();

    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return list of ingestion settings as paginated response with {@link PagedIterable}.
     */
    PagedIterable<IngestionSetting> list(Context context);

    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription along with
     *     {@link Response}.
     */
    Response<IngestionSetting> getWithResponse(String ingestionSettingName, Context context);

    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription.
     */
    IngestionSetting get(String ingestionSettingName);

    /**
     * Deletes the ingestion settings for this subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the {@link Response}.
     */
    Response<Void> deleteWithResponse(String ingestionSettingName, Context context);

    /**
     * Deletes the ingestion settings for this subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     */
    void delete(String ingestionSettingName);

    /**
     * Returns the token that is used for correlating ingested telemetry with the resources in the subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription along with
     *     {@link Response}.
     */
    Response<IngestionSettingToken> listTokensWithResponse(String ingestionSettingName, Context context);

    /**
     * Returns the token that is used for correlating ingested telemetry with the resources in the subscription.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription.
     */
    IngestionSettingToken listTokens(String ingestionSettingName);

    /**
     * Connection strings for ingesting security scan logs and data.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return connection string for ingesting security data and logs along with {@link Response}.
     */
    Response<ConnectionStrings> listConnectionStringsWithResponse(String ingestionSettingName, Context context);

    /**
     * Connection strings for ingesting security scan logs and data.
     *
     * @param ingestionSettingName Name of the ingestion setting.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return connection string for ingesting security data and logs.
     */
    ConnectionStrings listConnectionStrings(String ingestionSettingName);

    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @param id the resource ID.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription along with
     *     {@link Response}.
     */
    IngestionSetting getById(String id);

    /**
     * Settings for ingesting security data and logs to correlate with resources associated with the subscription.
     *
     * @param id the resource ID.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return configures how to correlate scan data and logs with resources associated with the subscription along with
     *     {@link Response}.
     */
    Response<IngestionSetting> getByIdWithResponse(String id, Context context);

    /**
     * Deletes the ingestion settings for this subscription.
     *
     * @param id the resource ID.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     */
    void deleteById(String id);

    /**
     * Deletes the ingestion settings for this subscription.
     *
     * @param id the resource ID.
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return the {@link Response}.
     */
    Response<Void> deleteByIdWithResponse(String id, Context context);

    /**
     * Begins definition for a new IngestionSetting resource.
     *
     * @param name resource name.
     * @return the first stage of the new IngestionSetting definition.
     */
    IngestionSetting.DefinitionStages.Blank define(String name);
}
