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

com.pulumi.azurenative.peering.outputs.GetPeerAsnResult Maven / Gradle / Ivy

There is a newer version: 2.78.0
Show newest version
// *** 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.peering.outputs;

import com.pulumi.azurenative.peering.outputs.ContactDetailResponse;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
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 GetPeerAsnResult {
    /**
     * @return The error message for the validation state
     * 
     */
    private String errorMessage;
    /**
     * @return The ID of the resource.
     * 
     */
    private String id;
    /**
     * @return The name of the resource.
     * 
     */
    private String name;
    /**
     * @return The Autonomous System Number (ASN) of the peer.
     * 
     */
    private @Nullable Integer peerAsn;
    /**
     * @return The contact details of the peer.
     * 
     */
    private @Nullable List peerContactDetail;
    /**
     * @return The name of the peer.
     * 
     */
    private @Nullable String peerName;
    /**
     * @return The type of the resource.
     * 
     */
    private String type;
    /**
     * @return The validation state of the ASN associated with the peer.
     * 
     */
    private String validationState;

    private GetPeerAsnResult() {}
    /**
     * @return The error message for the validation state
     * 
     */
    public String errorMessage() {
        return this.errorMessage;
    }
    /**
     * @return The ID of the resource.
     * 
     */
    public String id() {
        return this.id;
    }
    /**
     * @return The name of the resource.
     * 
     */
    public String name() {
        return this.name;
    }
    /**
     * @return The Autonomous System Number (ASN) of the peer.
     * 
     */
    public Optional peerAsn() {
        return Optional.ofNullable(this.peerAsn);
    }
    /**
     * @return The contact details of the peer.
     * 
     */
    public List peerContactDetail() {
        return this.peerContactDetail == null ? List.of() : this.peerContactDetail;
    }
    /**
     * @return The name of the peer.
     * 
     */
    public Optional peerName() {
        return Optional.ofNullable(this.peerName);
    }
    /**
     * @return The type of the resource.
     * 
     */
    public String type() {
        return this.type;
    }
    /**
     * @return The validation state of the ASN associated with the peer.
     * 
     */
    public String validationState() {
        return this.validationState;
    }

    public static Builder builder() {
        return new Builder();
    }

    public static Builder builder(GetPeerAsnResult defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private String errorMessage;
        private String id;
        private String name;
        private @Nullable Integer peerAsn;
        private @Nullable List peerContactDetail;
        private @Nullable String peerName;
        private String type;
        private String validationState;
        public Builder() {}
        public Builder(GetPeerAsnResult defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.errorMessage = defaults.errorMessage;
    	      this.id = defaults.id;
    	      this.name = defaults.name;
    	      this.peerAsn = defaults.peerAsn;
    	      this.peerContactDetail = defaults.peerContactDetail;
    	      this.peerName = defaults.peerName;
    	      this.type = defaults.type;
    	      this.validationState = defaults.validationState;
        }

        @CustomType.Setter
        public Builder errorMessage(String errorMessage) {
            if (errorMessage == null) {
              throw new MissingRequiredPropertyException("GetPeerAsnResult", "errorMessage");
            }
            this.errorMessage = errorMessage;
            return this;
        }
        @CustomType.Setter
        public Builder id(String id) {
            if (id == null) {
              throw new MissingRequiredPropertyException("GetPeerAsnResult", "id");
            }
            this.id = id;
            return this;
        }
        @CustomType.Setter
        public Builder name(String name) {
            if (name == null) {
              throw new MissingRequiredPropertyException("GetPeerAsnResult", "name");
            }
            this.name = name;
            return this;
        }
        @CustomType.Setter
        public Builder peerAsn(@Nullable Integer peerAsn) {

            this.peerAsn = peerAsn;
            return this;
        }
        @CustomType.Setter
        public Builder peerContactDetail(@Nullable List peerContactDetail) {

            this.peerContactDetail = peerContactDetail;
            return this;
        }
        public Builder peerContactDetail(ContactDetailResponse... peerContactDetail) {
            return peerContactDetail(List.of(peerContactDetail));
        }
        @CustomType.Setter
        public Builder peerName(@Nullable String peerName) {

            this.peerName = peerName;
            return this;
        }
        @CustomType.Setter
        public Builder type(String type) {
            if (type == null) {
              throw new MissingRequiredPropertyException("GetPeerAsnResult", "type");
            }
            this.type = type;
            return this;
        }
        @CustomType.Setter
        public Builder validationState(String validationState) {
            if (validationState == null) {
              throw new MissingRequiredPropertyException("GetPeerAsnResult", "validationState");
            }
            this.validationState = validationState;
            return this;
        }
        public GetPeerAsnResult build() {
            final var _resultValue = new GetPeerAsnResult();
            _resultValue.errorMessage = errorMessage;
            _resultValue.id = id;
            _resultValue.name = name;
            _resultValue.peerAsn = peerAsn;
            _resultValue.peerContactDetail = peerContactDetail;
            _resultValue.peerName = peerName;
            _resultValue.type = type;
            _resultValue.validationState = validationState;
            return _resultValue;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy