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

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

import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.fluidrelay.models.EncryptionProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The properties that can be provided when updating FluidRelayServer resource. */
@Fluent
public final class FluidRelayServerUpdateProperties {
    /*
     * All encryption configuration for a resource.
     */
    @JsonProperty(value = "encryption")
    private EncryptionProperties encryption;

    /**
     * Get the encryption property: All encryption configuration for a resource.
     *
     * @return the encryption value.
     */
    public EncryptionProperties encryption() {
        return this.encryption;
    }

    /**
     * Set the encryption property: All encryption configuration for a resource.
     *
     * @param encryption the encryption value to set.
     * @return the FluidRelayServerUpdateProperties object itself.
     */
    public FluidRelayServerUpdateProperties withEncryption(EncryptionProperties encryption) {
        this.encryption = encryption;
        return this;
    }

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