// 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.annotation.Fluent;
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.security.fluent.models.SecuritySolutionsReferenceDataProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The SecuritySolutionsReferenceData model. */
@Fluent
public final class SecuritySolutionsReferenceData extends ProxyResource {
    /*
     * The properties property.
     */
    @JsonProperty(value = "properties", required = true)
    private SecuritySolutionsReferenceDataProperties innerProperties = new SecuritySolutionsReferenceDataProperties();

    /*
     * Location where the resource is stored
     */
    @JsonProperty(value = "location", access = JsonProperty.Access.WRITE_ONLY)
    private String location;

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

    /**
     * Get the innerProperties property: The properties property.
     *
     * @return the innerProperties value.
     */
    private SecuritySolutionsReferenceDataProperties innerProperties() {
        return this.innerProperties;
    }

    /**
     * Get the location property: Location where the resource is stored.
     *
     * @return the location value.
     */
    public String location() {
        return this.location;
    }

    /**
     * Get the securityFamily property: The security family of the security solution.
     *
     * @return the securityFamily value.
     */
    public SecurityFamily securityFamily() {
        return this.innerProperties() == null ? null : this.innerProperties().securityFamily();
    }

    /**
     * Set the securityFamily property: The security family of the security solution.
     *
     * @param securityFamily the securityFamily value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withSecurityFamily(SecurityFamily securityFamily) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withSecurityFamily(securityFamily);
        return this;
    }

    /**
     * Get the alertVendorName property: The security solutions' vendor name.
     *
     * @return the alertVendorName value.
     */
    public String alertVendorName() {
        return this.innerProperties() == null ? null : this.innerProperties().alertVendorName();
    }

    /**
     * Set the alertVendorName property: The security solutions' vendor name.
     *
     * @param alertVendorName the alertVendorName value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withAlertVendorName(String alertVendorName) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withAlertVendorName(alertVendorName);
        return this;
    }

    /**
     * Get the packageInfoUrl property: The security solutions' package info url.
     *
     * @return the packageInfoUrl value.
     */
    public String packageInfoUrl() {
        return this.innerProperties() == null ? null : this.innerProperties().packageInfoUrl();
    }

    /**
     * Set the packageInfoUrl property: The security solutions' package info url.
     *
     * @param packageInfoUrl the packageInfoUrl value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withPackageInfoUrl(String packageInfoUrl) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withPackageInfoUrl(packageInfoUrl);
        return this;
    }

    /**
     * Get the productName property: The security solutions' product name.
     *
     * @return the productName value.
     */
    public String productName() {
        return this.innerProperties() == null ? null : this.innerProperties().productName();
    }

    /**
     * Set the productName property: The security solutions' product name.
     *
     * @param productName the productName value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withProductName(String productName) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withProductName(productName);
        return this;
    }

    /**
     * Get the publisher property: The security solutions' publisher.
     *
     * @return the publisher value.
     */
    public String publisher() {
        return this.innerProperties() == null ? null : this.innerProperties().publisher();
    }

    /**
     * Set the publisher property: The security solutions' publisher.
     *
     * @param publisher the publisher value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withPublisher(String publisher) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withPublisher(publisher);
        return this;
    }

    /**
     * Get the publisherDisplayName property: The security solutions' publisher display name.
     *
     * @return the publisherDisplayName value.
     */
    public String publisherDisplayName() {
        return this.innerProperties() == null ? null : this.innerProperties().publisherDisplayName();
    }

    /**
     * Set the publisherDisplayName property: The security solutions' publisher display name.
     *
     * @param publisherDisplayName the publisherDisplayName value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withPublisherDisplayName(String publisherDisplayName) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withPublisherDisplayName(publisherDisplayName);
        return this;
    }

    /**
     * Get the template property: The security solutions' template.
     *
     * @return the template value.
     */
    public String template() {
        return this.innerProperties() == null ? null : this.innerProperties().template();
    }

    /**
     * Set the template property: The security solutions' template.
     *
     * @param template the template value to set.
     * @return the SecuritySolutionsReferenceData object itself.
     */
    public SecuritySolutionsReferenceData withTemplate(String template) {
        if (this.innerProperties() == null) {
            this.innerProperties = new SecuritySolutionsReferenceDataProperties();
        }
        this.innerProperties().withTemplate(template);
        return this;
    }

    /**
     * Validates the instance.
     *
     * @throws IllegalArgumentException thrown if the instance is not valid.
     */
    public void validate() {
        if (innerProperties() == null) {
            throw LOGGER
                .logExceptionAsError(
                    new IllegalArgumentException(
                        "Missing required property innerProperties in model SecuritySolutionsReferenceData"));
        } else {
            innerProperties().validate();
        }
    }

    private static final ClientLogger LOGGER = new ClientLogger(SecuritySolutionsReferenceData.class);
}
