All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.azure.resourcemanager.deviceupdate.fluent.models.AccountProperties Maven / Gradle / Ivy

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

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

import com.azure.core.annotation.Fluent;
import com.azure.resourcemanager.deviceupdate.models.Encryption;
import com.azure.resourcemanager.deviceupdate.models.Location;
import com.azure.resourcemanager.deviceupdate.models.ProvisioningState;
import com.azure.resourcemanager.deviceupdate.models.PublicNetworkAccess;
import com.azure.resourcemanager.deviceupdate.models.Sku;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.List;

/**
 * Device Update account properties.
 */
@Fluent
public final class AccountProperties {
    /*
     * Provisioning state.
     */
    @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
    private ProvisioningState provisioningState;

    /*
     * API host name.
     */
    @JsonProperty(value = "hostName", access = JsonProperty.Access.WRITE_ONLY)
    private String hostname;

    /*
     * Whether or not public network access is allowed for the account.
     */
    @JsonProperty(value = "publicNetworkAccess")
    private PublicNetworkAccess publicNetworkAccess;

    /*
     * List of private endpoint connections associated with the account.
     */
    @JsonProperty(value = "privateEndpointConnections")
    private List privateEndpointConnections;

    /*
     * Device Update Sku
     */
    @JsonProperty(value = "sku")
    private Sku sku;

    /*
     * CMK encryption at rest properties
     */
    @JsonProperty(value = "encryption")
    private Encryption encryption;

    /*
     * Device Update account primary and failover location details
     */
    @JsonProperty(value = "locations", access = JsonProperty.Access.WRITE_ONLY)
    private List locations;

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

    /**
     * Get the provisioningState property: Provisioning state.
     * 
     * @return the provisioningState value.
     */
    public ProvisioningState provisioningState() {
        return this.provisioningState;
    }

    /**
     * Get the hostname property: API host name.
     * 
     * @return the hostname value.
     */
    public String hostname() {
        return this.hostname;
    }

    /**
     * Get the publicNetworkAccess property: Whether or not public network access is allowed for the account.
     * 
     * @return the publicNetworkAccess value.
     */
    public PublicNetworkAccess publicNetworkAccess() {
        return this.publicNetworkAccess;
    }

    /**
     * Set the publicNetworkAccess property: Whether or not public network access is allowed for the account.
     * 
     * @param publicNetworkAccess the publicNetworkAccess value to set.
     * @return the AccountProperties object itself.
     */
    public AccountProperties withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
        this.publicNetworkAccess = publicNetworkAccess;
        return this;
    }

    /**
     * Get the privateEndpointConnections property: List of private endpoint connections associated with the account.
     * 
     * @return the privateEndpointConnections value.
     */
    public List privateEndpointConnections() {
        return this.privateEndpointConnections;
    }

    /**
     * Set the privateEndpointConnections property: List of private endpoint connections associated with the account.
     * 
     * @param privateEndpointConnections the privateEndpointConnections value to set.
     * @return the AccountProperties object itself.
     */
    public AccountProperties
        withPrivateEndpointConnections(List privateEndpointConnections) {
        this.privateEndpointConnections = privateEndpointConnections;
        return this;
    }

    /**
     * Get the sku property: Device Update Sku.
     * 
     * @return the sku value.
     */
    public Sku sku() {
        return this.sku;
    }

    /**
     * Set the sku property: Device Update Sku.
     * 
     * @param sku the sku value to set.
     * @return the AccountProperties object itself.
     */
    public AccountProperties withSku(Sku sku) {
        this.sku = sku;
        return this;
    }

    /**
     * Get the encryption property: CMK encryption at rest properties.
     * 
     * @return the encryption value.
     */
    public Encryption encryption() {
        return this.encryption;
    }

    /**
     * Set the encryption property: CMK encryption at rest properties.
     * 
     * @param encryption the encryption value to set.
     * @return the AccountProperties object itself.
     */
    public AccountProperties withEncryption(Encryption encryption) {
        this.encryption = encryption;
        return this;
    }

    /**
     * Get the locations property: Device Update account primary and failover location details.
     * 
     * @return the locations value.
     */
    public List locations() {
        return this.locations;
    }

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy