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

package com.azure.resourcemanager.workloads.models;

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

/** Gets or sets the PrometheusHaCluster provider properties. */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "providerType")
@JsonTypeName("PrometheusHaCluster")
@Fluent
public final class PrometheusHaClusterProviderInstanceProperties extends ProviderSpecificProperties {
    /*
     * URL of the Node Exporter endpoint.
     */
    @JsonProperty(value = "prometheusUrl")
    private String prometheusUrl;

    /*
     * Gets or sets the target machine name.
     */
    @JsonProperty(value = "hostname")
    private String hostname;

    /*
     * Gets or sets the cluster sid.
     */
    @JsonProperty(value = "sid")
    private String sid;

    /*
     * Gets or sets the clusterName.
     */
    @JsonProperty(value = "clusterName")
    private String clusterName;

    /*
     * Gets or sets certificate preference if secure communication is enabled.
     */
    @JsonProperty(value = "sslPreference")
    private SslPreference sslPreference;

    /*
     * Gets or sets the blob URI to SSL certificate for the HA cluster exporter.
     */
    @JsonProperty(value = "sslCertificateUri")
    private String sslCertificateUri;

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

    /**
     * Get the prometheusUrl property: URL of the Node Exporter endpoint.
     *
     * @return the prometheusUrl value.
     */
    public String prometheusUrl() {
        return this.prometheusUrl;
    }

    /**
     * Set the prometheusUrl property: URL of the Node Exporter endpoint.
     *
     * @param prometheusUrl the prometheusUrl value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withPrometheusUrl(String prometheusUrl) {
        this.prometheusUrl = prometheusUrl;
        return this;
    }

    /**
     * Get the hostname property: Gets or sets the target machine name.
     *
     * @return the hostname value.
     */
    public String hostname() {
        return this.hostname;
    }

    /**
     * Set the hostname property: Gets or sets the target machine name.
     *
     * @param hostname the hostname value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withHostname(String hostname) {
        this.hostname = hostname;
        return this;
    }

    /**
     * Get the sid property: Gets or sets the cluster sid.
     *
     * @return the sid value.
     */
    public String sid() {
        return this.sid;
    }

    /**
     * Set the sid property: Gets or sets the cluster sid.
     *
     * @param sid the sid value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withSid(String sid) {
        this.sid = sid;
        return this;
    }

    /**
     * Get the clusterName property: Gets or sets the clusterName.
     *
     * @return the clusterName value.
     */
    public String clusterName() {
        return this.clusterName;
    }

    /**
     * Set the clusterName property: Gets or sets the clusterName.
     *
     * @param clusterName the clusterName value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withClusterName(String clusterName) {
        this.clusterName = clusterName;
        return this;
    }

    /**
     * Get the sslPreference property: Gets or sets certificate preference if secure communication is enabled.
     *
     * @return the sslPreference value.
     */
    public SslPreference sslPreference() {
        return this.sslPreference;
    }

    /**
     * Set the sslPreference property: Gets or sets certificate preference if secure communication is enabled.
     *
     * @param sslPreference the sslPreference value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withSslPreference(SslPreference sslPreference) {
        this.sslPreference = sslPreference;
        return this;
    }

    /**
     * Get the sslCertificateUri property: Gets or sets the blob URI to SSL certificate for the HA cluster exporter.
     *
     * @return the sslCertificateUri value.
     */
    public String sslCertificateUri() {
        return this.sslCertificateUri;
    }

    /**
     * Set the sslCertificateUri property: Gets or sets the blob URI to SSL certificate for the HA cluster exporter.
     *
     * @param sslCertificateUri the sslCertificateUri value to set.
     * @return the PrometheusHaClusterProviderInstanceProperties object itself.
     */
    public PrometheusHaClusterProviderInstanceProperties withSslCertificateUri(String sslCertificateUri) {
        this.sslCertificateUri = sslCertificateUri;
        return this;
    }

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