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

package com.azure.resourcemanager.databox.fluent.models;

import com.azure.core.annotation.Immutable;
import com.azure.resourcemanager.databox.models.OverallValidationStatus;
import com.azure.resourcemanager.databox.models.ValidationInputResponse;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** Properties of pre job creation validation response. */
@Immutable
public final class ValidationResponseProperties {
    /*
     * Overall validation status.
     */
    @JsonProperty(value = "status", access = JsonProperty.Access.WRITE_ONLY)
    private OverallValidationStatus status;

    /*
     * List of response details contain validationType and its response as key and value respectively.
     */
    @JsonProperty(value = "individualResponseDetails", access = JsonProperty.Access.WRITE_ONLY)
    private List<ValidationInputResponse> individualResponseDetails;

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

    /**
     * Get the status property: Overall validation status.
     *
     * @return the status value.
     */
    public OverallValidationStatus status() {
        return this.status;
    }

    /**
     * Get the individualResponseDetails property: List of response details contain validationType and its response as
     * key and value respectively.
     *
     * @return the individualResponseDetails value.
     */
    public List<ValidationInputResponse> individualResponseDetails() {
        return this.individualResponseDetails;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
        if (individualResponseDetails() != null) {
            individualResponseDetails().forEach(e -> e.validate());
        }
    }
}
