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

package com.azure.resourcemanager.appcontainers.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** Diagnostics data returned from a detector. */
@Fluent
public final class DiagnosticsDataApiResponse {
    /*
     * Table response
     */
    @JsonProperty(value = "table")
    private DiagnosticDataTableResponseObject table;

    /*
     * Details of the table response
     */
    @JsonProperty(value = "renderingProperties")
    private DiagnosticRendering renderingProperties;

    /** Creates an instance of DiagnosticsDataApiResponse class. */
    public DiagnosticsDataApiResponse() {
    }

    /**
     * Get the table property: Table response.
     *
     * @return the table value.
     */
    public DiagnosticDataTableResponseObject table() {
        return this.table;
    }

    /**
     * Set the table property: Table response.
     *
     * @param table the table value to set.
     * @return the DiagnosticsDataApiResponse object itself.
     */
    public DiagnosticsDataApiResponse withTable(DiagnosticDataTableResponseObject table) {
        this.table = table;
        return this;
    }

    /**
     * Get the renderingProperties property: Details of the table response.
     *
     * @return the renderingProperties value.
     */
    public DiagnosticRendering renderingProperties() {
        return this.renderingProperties;
    }

    /**
     * Set the renderingProperties property: Details of the table response.
     *
     * @param renderingProperties the renderingProperties value to set.
     * @return the DiagnosticsDataApiResponse object itself.
     */
    public DiagnosticsDataApiResponse withRenderingProperties(DiagnosticRendering renderingProperties) {
        this.renderingProperties = renderingProperties;
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
        if (table() != null) {
            table().validate();
        }
        if (renderingProperties() != null) {
            renderingProperties().validate();
        }
    }
}
