
com.pulumi.azurenative.documentdb.outputs.LocationResponse Maven / Gradle / Ivy
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.documentdb.outputs;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class LocationResponse {
/**
* @return The connection endpoint for the specific region. Example: https://<accountName>-<locationName>.documents.azure.com:443/
*
*/
private String documentEndpoint;
/**
* @return The failover priority of the region. A failover priority of 0 indicates a write region. The maximum value for a failover priority = (total number of regions - 1). Failover priority values must be unique for each of the regions in which the database account exists.
*
*/
private @Nullable Integer failoverPriority;
/**
* @return The unique identifier of the region within the database account. Example: <accountName>-<locationName>.
*
*/
private String id;
/**
* @return Flag to indicate whether or not this region is an AvailabilityZone region
*
*/
private @Nullable Boolean isZoneRedundant;
/**
* @return The name of the region.
*
*/
private @Nullable String locationName;
/**
* @return The status of the Cosmos DB account at the time the operation was called. The status can be one of following. 'Creating' – the Cosmos DB account is being created. When an account is in Creating state, only properties that are specified as input for the Create Cosmos DB account operation are returned. 'Succeeded' – the Cosmos DB account is active for use. 'Updating' – the Cosmos DB account is being updated. 'Deleting' – the Cosmos DB account is being deleted. 'Failed' – the Cosmos DB account failed creation. 'DeletionFailed' – the Cosmos DB account deletion failed.
*
*/
private String provisioningState;
private LocationResponse() {}
/**
* @return The connection endpoint for the specific region. Example: https://<accountName>-<locationName>.documents.azure.com:443/
*
*/
public String documentEndpoint() {
return this.documentEndpoint;
}
/**
* @return The failover priority of the region. A failover priority of 0 indicates a write region. The maximum value for a failover priority = (total number of regions - 1). Failover priority values must be unique for each of the regions in which the database account exists.
*
*/
public Optional failoverPriority() {
return Optional.ofNullable(this.failoverPriority);
}
/**
* @return The unique identifier of the region within the database account. Example: <accountName>-<locationName>.
*
*/
public String id() {
return this.id;
}
/**
* @return Flag to indicate whether or not this region is an AvailabilityZone region
*
*/
public Optional isZoneRedundant() {
return Optional.ofNullable(this.isZoneRedundant);
}
/**
* @return The name of the region.
*
*/
public Optional locationName() {
return Optional.ofNullable(this.locationName);
}
/**
* @return The status of the Cosmos DB account at the time the operation was called. The status can be one of following. 'Creating' – the Cosmos DB account is being created. When an account is in Creating state, only properties that are specified as input for the Create Cosmos DB account operation are returned. 'Succeeded' – the Cosmos DB account is active for use. 'Updating' – the Cosmos DB account is being updated. 'Deleting' – the Cosmos DB account is being deleted. 'Failed' – the Cosmos DB account failed creation. 'DeletionFailed' – the Cosmos DB account deletion failed.
*
*/
public String provisioningState() {
return this.provisioningState;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(LocationResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private String documentEndpoint;
private @Nullable Integer failoverPriority;
private String id;
private @Nullable Boolean isZoneRedundant;
private @Nullable String locationName;
private String provisioningState;
public Builder() {}
public Builder(LocationResponse defaults) {
Objects.requireNonNull(defaults);
this.documentEndpoint = defaults.documentEndpoint;
this.failoverPriority = defaults.failoverPriority;
this.id = defaults.id;
this.isZoneRedundant = defaults.isZoneRedundant;
this.locationName = defaults.locationName;
this.provisioningState = defaults.provisioningState;
}
@CustomType.Setter
public Builder documentEndpoint(String documentEndpoint) {
if (documentEndpoint == null) {
throw new MissingRequiredPropertyException("LocationResponse", "documentEndpoint");
}
this.documentEndpoint = documentEndpoint;
return this;
}
@CustomType.Setter
public Builder failoverPriority(@Nullable Integer failoverPriority) {
this.failoverPriority = failoverPriority;
return this;
}
@CustomType.Setter
public Builder id(String id) {
if (id == null) {
throw new MissingRequiredPropertyException("LocationResponse", "id");
}
this.id = id;
return this;
}
@CustomType.Setter
public Builder isZoneRedundant(@Nullable Boolean isZoneRedundant) {
this.isZoneRedundant = isZoneRedundant;
return this;
}
@CustomType.Setter
public Builder locationName(@Nullable String locationName) {
this.locationName = locationName;
return this;
}
@CustomType.Setter
public Builder provisioningState(String provisioningState) {
if (provisioningState == null) {
throw new MissingRequiredPropertyException("LocationResponse", "provisioningState");
}
this.provisioningState = provisioningState;
return this;
}
public LocationResponse build() {
final var _resultValue = new LocationResponse();
_resultValue.documentEndpoint = documentEndpoint;
_resultValue.failoverPriority = failoverPriority;
_resultValue.id = id;
_resultValue.isZoneRedundant = isZoneRedundant;
_resultValue.locationName = locationName;
_resultValue.provisioningState = provisioningState;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy