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

package com.azure.resourcemanager.azurestackhci.models;

import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingsPatchProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Map;

/** ArcSetting details to update. */
@Fluent
public final class ArcSettingsPatch {
    /*
     * Resource tags.
     */
    @JsonProperty(value = "tags")
    @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
    private Map<String, String> tags;

    /*
     * ArcSettings properties.
     */
    @JsonProperty(value = "properties")
    private ArcSettingsPatchProperties innerProperties;

    /**
     * Get the tags property: Resource tags.
     *
     * @return the tags value.
     */
    public Map<String, String> tags() {
        return this.tags;
    }

    /**
     * Set the tags property: Resource tags.
     *
     * @param tags the tags value to set.
     * @return the ArcSettingsPatch object itself.
     */
    public ArcSettingsPatch withTags(Map<String, String> tags) {
        this.tags = tags;
        return this;
    }

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

    /**
     * Get the connectivityProperties property: contains connectivity related configuration for ARC resources.
     *
     * @return the connectivityProperties value.
     */
    public Object connectivityProperties() {
        return this.innerProperties() == null ? null : this.innerProperties().connectivityProperties();
    }

    /**
     * Set the connectivityProperties property: contains connectivity related configuration for ARC resources.
     *
     * @param connectivityProperties the connectivityProperties value to set.
     * @return the ArcSettingsPatch object itself.
     */
    public ArcSettingsPatch withConnectivityProperties(Object connectivityProperties) {
        if (this.innerProperties() == null) {
            this.innerProperties = new ArcSettingsPatchProperties();
        }
        this.innerProperties().withConnectivityProperties(connectivityProperties);
        return this;
    }

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