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

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

import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.vmwarecloudsimple.models.CustomizationPolicyPropertiesType;
import com.azure.resourcemanager.vmwarecloudsimple.models.CustomizationSpecification;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The properties of Customization policy. */
@Fluent
public final class CustomizationPolicyProperties {
    /*
     * Policy description
     */
    @JsonProperty(value = "description")
    private String description;

    /*
     * The Private cloud id
     */
    @JsonProperty(value = "privateCloudId")
    private String privateCloudId;

    /*
     * Detailed customization policy specification
     */
    @JsonProperty(value = "specification")
    private CustomizationSpecification specification;

    /*
     * The type of customization (Linux or Windows)
     */
    @JsonProperty(value = "type")
    private CustomizationPolicyPropertiesType type;

    /*
     * Policy version
     */
    @JsonProperty(value = "version")
    private String version;

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

    /**
     * Get the description property: Policy description.
     *
     * @return the description value.
     */
    public String description() {
        return this.description;
    }

    /**
     * Set the description property: Policy description.
     *
     * @param description the description value to set.
     * @return the CustomizationPolicyProperties object itself.
     */
    public CustomizationPolicyProperties withDescription(String description) {
        this.description = description;
        return this;
    }

    /**
     * Get the privateCloudId property: The Private cloud id.
     *
     * @return the privateCloudId value.
     */
    public String privateCloudId() {
        return this.privateCloudId;
    }

    /**
     * Set the privateCloudId property: The Private cloud id.
     *
     * @param privateCloudId the privateCloudId value to set.
     * @return the CustomizationPolicyProperties object itself.
     */
    public CustomizationPolicyProperties withPrivateCloudId(String privateCloudId) {
        this.privateCloudId = privateCloudId;
        return this;
    }

    /**
     * Get the specification property: Detailed customization policy specification.
     *
     * @return the specification value.
     */
    public CustomizationSpecification specification() {
        return this.specification;
    }

    /**
     * Set the specification property: Detailed customization policy specification.
     *
     * @param specification the specification value to set.
     * @return the CustomizationPolicyProperties object itself.
     */
    public CustomizationPolicyProperties withSpecification(CustomizationSpecification specification) {
        this.specification = specification;
        return this;
    }

    /**
     * Get the type property: The type of customization (Linux or Windows).
     *
     * @return the type value.
     */
    public CustomizationPolicyPropertiesType type() {
        return this.type;
    }

    /**
     * Set the type property: The type of customization (Linux or Windows).
     *
     * @param type the type value to set.
     * @return the CustomizationPolicyProperties object itself.
     */
    public CustomizationPolicyProperties withType(CustomizationPolicyPropertiesType type) {
        this.type = type;
        return this;
    }

    /**
     * Get the version property: Policy version.
     *
     * @return the version value.
     */
    public String version() {
        return this.version;
    }

    /**
     * Set the version property: Policy version.
     *
     * @param version the version value to set.
     * @return the CustomizationPolicyProperties object itself.
     */
    public CustomizationPolicyProperties withVersion(String version) {
        this.version = version;
        return this;
    }

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