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

package com.azure.resourcemanager.synapse.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 SqlPoolVulnerabilityAssessmentScans. */
public interface SqlPoolVulnerabilityAssessmentScans {
    /**
     * Lists the vulnerability assessment scans of a SQL pool
     *
     * <p>Lists the vulnerability assessment scans of a SQL pool.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @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 a list of vulnerability assessment scan records as paginated response with {@link PagedIterable}.
     */
    PagedIterable<VulnerabilityAssessmentScanRecord> list(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName);

    /**
     * Lists the vulnerability assessment scans of a SQL pool
     *
     * <p>Lists the vulnerability assessment scans of a SQL pool.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @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 a list of vulnerability assessment scan records as paginated response with {@link PagedIterable}.
     */
    PagedIterable<VulnerabilityAssessmentScanRecord> list(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        Context context);

    /**
     * Executes a Vulnerability Assessment database scan.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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 initiateScan(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId);

    /**
     * Executes a Vulnerability Assessment database scan.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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.
     */
    void initiateScan(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId,
        Context context);

    /**
     * Convert an existing scan result to a human readable format. If already exists nothing happens.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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 a Sql pool Vulnerability Assessment scan export resource along with {@link Response}.
     */
    Response<SqlPoolVulnerabilityAssessmentScansExport> exportWithResponse(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId,
        Context context);

    /**
     * Convert an existing scan result to a human readable format. If already exists nothing happens.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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 a Sql pool Vulnerability Assessment scan export resource.
     */
    SqlPoolVulnerabilityAssessmentScansExport export(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId);

    /**
     * Gets a vulnerability assessment scan record of a Sql pool.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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 a vulnerability assessment scan record of a Sql pool along with {@link Response}.
     */
    Response<VulnerabilityAssessmentScanRecord> getWithResponse(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId,
        Context context);

    /**
     * Gets a vulnerability assessment scan record of a Sql pool.
     *
     * @param resourceGroupName The name of the resource group. The name is case insensitive.
     * @param workspaceName The name of the workspace.
     * @param sqlPoolName SQL pool name.
     * @param vulnerabilityAssessmentName The name of the vulnerability assessment.
     * @param scanId The vulnerability assessment scan Id of the scan to retrieve.
     * @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 a vulnerability assessment scan record of a Sql pool.
     */
    VulnerabilityAssessmentScanRecord get(
        String resourceGroupName,
        String workspaceName,
        String sqlPoolName,
        VulnerabilityAssessmentName vulnerabilityAssessmentName,
        String scanId);
}
