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

package com.azure.resourcemanager.apimanagement.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** Properties specific to the Backend Type. */
@Fluent
public final class BackendProperties {
    /*
     * Backend Service Fabric Cluster Properties
     */
    @JsonProperty(value = "serviceFabricCluster")
    private BackendServiceFabricClusterProperties serviceFabricCluster;

    /**
     * Get the serviceFabricCluster property: Backend Service Fabric Cluster Properties.
     *
     * @return the serviceFabricCluster value.
     */
    public BackendServiceFabricClusterProperties serviceFabricCluster() {
        return this.serviceFabricCluster;
    }

    /**
     * Set the serviceFabricCluster property: Backend Service Fabric Cluster Properties.
     *
     * @param serviceFabricCluster the serviceFabricCluster value to set.
     * @return the BackendProperties object itself.
     */
    public BackendProperties withServiceFabricCluster(BackendServiceFabricClusterProperties serviceFabricCluster) {
        this.serviceFabricCluster = serviceFabricCluster;
        return this;
    }

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