com.pulumi.azurenative.network.outputs.ConnectionMonitorHttpConfigurationResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** 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.network.outputs;
import com.pulumi.azurenative.network.outputs.HTTPHeaderResponse;
import com.pulumi.core.annotations.CustomType;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class ConnectionMonitorHttpConfigurationResponse {
/**
* @return The HTTP method to use.
*
*/
private @Nullable String method;
/**
* @return The path component of the URI. For instance, "/dir1/dir2".
*
*/
private @Nullable String path;
/**
* @return The port to connect to.
*
*/
private @Nullable Integer port;
/**
* @return Value indicating whether HTTPS is preferred over HTTP in cases where the choice is not explicit.
*
*/
private @Nullable Boolean preferHTTPS;
/**
* @return The HTTP headers to transmit with the request.
*
*/
private @Nullable List requestHeaders;
/**
* @return HTTP status codes to consider successful. For instance, "2xx,301-304,418".
*
*/
private @Nullable List validStatusCodeRanges;
private ConnectionMonitorHttpConfigurationResponse() {}
/**
* @return The HTTP method to use.
*
*/
public Optional method() {
return Optional.ofNullable(this.method);
}
/**
* @return The path component of the URI. For instance, "/dir1/dir2".
*
*/
public Optional path() {
return Optional.ofNullable(this.path);
}
/**
* @return The port to connect to.
*
*/
public Optional port() {
return Optional.ofNullable(this.port);
}
/**
* @return Value indicating whether HTTPS is preferred over HTTP in cases where the choice is not explicit.
*
*/
public Optional preferHTTPS() {
return Optional.ofNullable(this.preferHTTPS);
}
/**
* @return The HTTP headers to transmit with the request.
*
*/
public List requestHeaders() {
return this.requestHeaders == null ? List.of() : this.requestHeaders;
}
/**
* @return HTTP status codes to consider successful. For instance, "2xx,301-304,418".
*
*/
public List validStatusCodeRanges() {
return this.validStatusCodeRanges == null ? List.of() : this.validStatusCodeRanges;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(ConnectionMonitorHttpConfigurationResponse defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String method;
private @Nullable String path;
private @Nullable Integer port;
private @Nullable Boolean preferHTTPS;
private @Nullable List requestHeaders;
private @Nullable List validStatusCodeRanges;
public Builder() {}
public Builder(ConnectionMonitorHttpConfigurationResponse defaults) {
Objects.requireNonNull(defaults);
this.method = defaults.method;
this.path = defaults.path;
this.port = defaults.port;
this.preferHTTPS = defaults.preferHTTPS;
this.requestHeaders = defaults.requestHeaders;
this.validStatusCodeRanges = defaults.validStatusCodeRanges;
}
@CustomType.Setter
public Builder method(@Nullable String method) {
this.method = method;
return this;
}
@CustomType.Setter
public Builder path(@Nullable String path) {
this.path = path;
return this;
}
@CustomType.Setter
public Builder port(@Nullable Integer port) {
this.port = port;
return this;
}
@CustomType.Setter
public Builder preferHTTPS(@Nullable Boolean preferHTTPS) {
this.preferHTTPS = preferHTTPS;
return this;
}
@CustomType.Setter
public Builder requestHeaders(@Nullable List requestHeaders) {
this.requestHeaders = requestHeaders;
return this;
}
public Builder requestHeaders(HTTPHeaderResponse... requestHeaders) {
return requestHeaders(List.of(requestHeaders));
}
@CustomType.Setter
public Builder validStatusCodeRanges(@Nullable List validStatusCodeRanges) {
this.validStatusCodeRanges = validStatusCodeRanges;
return this;
}
public Builder validStatusCodeRanges(String... validStatusCodeRanges) {
return validStatusCodeRanges(List.of(validStatusCodeRanges));
}
public ConnectionMonitorHttpConfigurationResponse build() {
final var _resultValue = new ConnectionMonitorHttpConfigurationResponse();
_resultValue.method = method;
_resultValue.path = path;
_resultValue.port = port;
_resultValue.preferHTTPS = preferHTTPS;
_resultValue.requestHeaders = requestHeaders;
_resultValue.validStatusCodeRanges = validStatusCodeRanges;
return _resultValue;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy