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

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

import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.timeseriesinsights.models.AccessPolicyRole;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/** An object that represents a set of mutable access policy resource properties. */
@Fluent
public final class AccessPolicyMutableProperties {
    /*
     * An description of the access policy.
     */
    @JsonProperty(value = "description")
    private String description;

    /*
     * The list of roles the principal is assigned on the environment.
     */
    @JsonProperty(value = "roles")
    private List<AccessPolicyRole> roles;

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

    /**
     * Get the description property: An description of the access policy.
     *
     * @return the description value.
     */
    public String description() {
        return this.description;
    }

    /**
     * Set the description property: An description of the access policy.
     *
     * @param description the description value to set.
     * @return the AccessPolicyMutableProperties object itself.
     */
    public AccessPolicyMutableProperties withDescription(String description) {
        this.description = description;
        return this;
    }

    /**
     * Get the roles property: The list of roles the principal is assigned on the environment.
     *
     * @return the roles value.
     */
    public List<AccessPolicyRole> roles() {
        return this.roles;
    }

    /**
     * Set the roles property: The list of roles the principal is assigned on the environment.
     *
     * @param roles the roles value to set.
     * @return the AccessPolicyMutableProperties object itself.
     */
    public AccessPolicyMutableProperties withRoles(List<AccessPolicyRole> roles) {
        this.roles = roles;
        return this;
    }

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