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

com.google.cloud.baremetalsolution.v2.VRF Maven / Gradle / Ivy

There is a newer version: 0.54.0
Show newest version
/*
 * Copyright 2023 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/cloud/baremetalsolution/v2/network.proto

package com.google.cloud.baremetalsolution.v2;

/**
 *
 *
 * 
 * A network VRF.
 * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF} */ public final class VRF extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.baremetalsolution.v2.VRF) VRFOrBuilder { private static final long serialVersionUID = 0L; // Use VRF.newBuilder() to construct. private VRF(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private VRF() { name_ = ""; state_ = 0; vlanAttachments_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new VRF(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.class, com.google.cloud.baremetalsolution.v2.VRF.Builder.class); } /** * * *
   * The possible states for this VRF.
   * 
* * Protobuf enum {@code google.cloud.baremetalsolution.v2.VRF.State} */ public enum State implements com.google.protobuf.ProtocolMessageEnum { /** * * *
     * The unspecified state.
     * 
* * STATE_UNSPECIFIED = 0; */ STATE_UNSPECIFIED(0), /** * * *
     * The vrf is provisioning.
     * 
* * PROVISIONING = 1; */ PROVISIONING(1), /** * * *
     * The vrf is provisioned.
     * 
* * PROVISIONED = 2; */ PROVISIONED(2), UNRECOGNIZED(-1), ; /** * * *
     * The unspecified state.
     * 
* * STATE_UNSPECIFIED = 0; */ public static final int STATE_UNSPECIFIED_VALUE = 0; /** * * *
     * The vrf is provisioning.
     * 
* * PROVISIONING = 1; */ public static final int PROVISIONING_VALUE = 1; /** * * *
     * The vrf is provisioned.
     * 
* * PROVISIONED = 2; */ public static final int PROVISIONED_VALUE = 2; public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( "Can't get the number of an unknown enum value."); } return value; } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static State valueOf(int value) { return forNumber(value); } /** * @param value The numeric wire value of the corresponding enum entry. * @return The enum associated with the given numeric wire value. */ public static State forNumber(int value) { switch (value) { case 0: return STATE_UNSPECIFIED; case 1: return PROVISIONING; case 2: return PROVISIONED; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = new com.google.protobuf.Internal.EnumLiteMap() { public State findValueByNumber(int number) { return State.forNumber(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalStateException( "Can't get the descriptor of an unrecognized enum value."); } return getDescriptor().getValues().get(ordinal()); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.VRF.getDescriptor().getEnumTypes().get(0); } private static final State[] VALUES = values(); public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; } return VALUES[desc.getIndex()]; } private final int value; private State(int value) { this.value = value; } // @@protoc_insertion_point(enum_scope:google.cloud.baremetalsolution.v2.VRF.State) } public interface QosPolicyOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.baremetalsolution.v2.VRF.QosPolicy) com.google.protobuf.MessageOrBuilder { /** * * *
     * The bandwidth permitted by the QOS policy, in gbps.
     * 
* * double bandwidth_gbps = 1; * * @return The bandwidthGbps. */ double getBandwidthGbps(); } /** * * *
   * QOS policy parameters.
   * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF.QosPolicy} */ public static final class QosPolicy extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.baremetalsolution.v2.VRF.QosPolicy) QosPolicyOrBuilder { private static final long serialVersionUID = 0L; // Use QosPolicy.newBuilder() to construct. private QosPolicy(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private QosPolicy() {} @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new QosPolicy(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_QosPolicy_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_QosPolicy_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.class, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder.class); } public static final int BANDWIDTH_GBPS_FIELD_NUMBER = 1; private double bandwidthGbps_ = 0D; /** * * *
     * The bandwidth permitted by the QOS policy, in gbps.
     * 
* * double bandwidth_gbps = 1; * * @return The bandwidthGbps. */ @java.lang.Override public double getBandwidthGbps() { return bandwidthGbps_; } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (java.lang.Double.doubleToRawLongBits(bandwidthGbps_) != 0) { output.writeDouble(1, bandwidthGbps_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (java.lang.Double.doubleToRawLongBits(bandwidthGbps_) != 0) { size += com.google.protobuf.CodedOutputStream.computeDoubleSize(1, bandwidthGbps_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.baremetalsolution.v2.VRF.QosPolicy)) { return super.equals(obj); } com.google.cloud.baremetalsolution.v2.VRF.QosPolicy other = (com.google.cloud.baremetalsolution.v2.VRF.QosPolicy) obj; if (java.lang.Double.doubleToLongBits(getBandwidthGbps()) != java.lang.Double.doubleToLongBits(other.getBandwidthGbps())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + BANDWIDTH_GBPS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getBandwidthGbps())); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.baremetalsolution.v2.VRF.QosPolicy prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * QOS policy parameters.
     * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF.QosPolicy} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.baremetalsolution.v2.VRF.QosPolicy) com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_QosPolicy_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_QosPolicy_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.class, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder.class); } // Construct using com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; bandwidthGbps_ = 0D; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_QosPolicy_descriptor; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getDefaultInstanceForType() { return com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance(); } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy build() { com.google.cloud.baremetalsolution.v2.VRF.QosPolicy result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy buildPartial() { com.google.cloud.baremetalsolution.v2.VRF.QosPolicy result = new com.google.cloud.baremetalsolution.v2.VRF.QosPolicy(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.bandwidthGbps_ = bandwidthGbps_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.baremetalsolution.v2.VRF.QosPolicy) { return mergeFrom((com.google.cloud.baremetalsolution.v2.VRF.QosPolicy) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy other) { if (other == com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance()) return this; if (other.getBandwidthGbps() != 0D) { setBandwidthGbps(other.getBandwidthGbps()); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 9: { bandwidthGbps_ = input.readDouble(); bitField0_ |= 0x00000001; break; } // case 9 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private double bandwidthGbps_; /** * * *
       * The bandwidth permitted by the QOS policy, in gbps.
       * 
* * double bandwidth_gbps = 1; * * @return The bandwidthGbps. */ @java.lang.Override public double getBandwidthGbps() { return bandwidthGbps_; } /** * * *
       * The bandwidth permitted by the QOS policy, in gbps.
       * 
* * double bandwidth_gbps = 1; * * @param value The bandwidthGbps to set. * @return This builder for chaining. */ public Builder setBandwidthGbps(double value) { bandwidthGbps_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * The bandwidth permitted by the QOS policy, in gbps.
       * 
* * double bandwidth_gbps = 1; * * @return This builder for chaining. */ public Builder clearBandwidthGbps() { bitField0_ = (bitField0_ & ~0x00000001); bandwidthGbps_ = 0D; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.baremetalsolution.v2.VRF.QosPolicy) } // @@protoc_insertion_point(class_scope:google.cloud.baremetalsolution.v2.VRF.QosPolicy) private static final com.google.cloud.baremetalsolution.v2.VRF.QosPolicy DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.baremetalsolution.v2.VRF.QosPolicy(); } public static com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public QosPolicy parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public interface VlanAttachmentOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.baremetalsolution.v2.VRF.VlanAttachment) com.google.protobuf.MessageOrBuilder { /** * * *
     * The peer vlan ID of the attachment.
     * 
* * int64 peer_vlan_id = 1; * * @return The peerVlanId. */ long getPeerVlanId(); /** * * *
     * The peer IP of the attachment.
     * 
* * string peer_ip = 2; * * @return The peerIp. */ java.lang.String getPeerIp(); /** * * *
     * The peer IP of the attachment.
     * 
* * string peer_ip = 2; * * @return The bytes for peerIp. */ com.google.protobuf.ByteString getPeerIpBytes(); /** * * *
     * The router IP of the attachment.
     * 
* * string router_ip = 3; * * @return The routerIp. */ java.lang.String getRouterIp(); /** * * *
     * The router IP of the attachment.
     * 
* * string router_ip = 3; * * @return The bytes for routerIp. */ com.google.protobuf.ByteString getRouterIpBytes(); /** * * *
     * Input only. Pairing key.
     * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The pairingKey. */ java.lang.String getPairingKey(); /** * * *
     * Input only. Pairing key.
     * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bytes for pairingKey. */ com.google.protobuf.ByteString getPairingKeyBytes(); /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return Whether the qosPolicy field is set. */ boolean hasQosPolicy(); /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return The qosPolicy. */ com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getQosPolicy(); /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder getQosPolicyOrBuilder(); /** * * *
     * Immutable. The identifier of the attachment within vrf.
     * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The id. */ java.lang.String getId(); /** * * *
     * Immutable. The identifier of the attachment within vrf.
     * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The bytes for id. */ com.google.protobuf.ByteString getIdBytes(); /** * * *
     * Optional. The name of the vlan attachment within vrf. This is of the form
     * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
     * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The interconnectAttachment. */ java.lang.String getInterconnectAttachment(); /** * * *
     * Optional. The name of the vlan attachment within vrf. This is of the form
     * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
     * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The bytes for interconnectAttachment. */ com.google.protobuf.ByteString getInterconnectAttachmentBytes(); } /** * * *
   * VLAN attachment details.
   * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF.VlanAttachment} */ public static final class VlanAttachment extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.baremetalsolution.v2.VRF.VlanAttachment) VlanAttachmentOrBuilder { private static final long serialVersionUID = 0L; // Use VlanAttachment.newBuilder() to construct. private VlanAttachment(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private VlanAttachment() { peerIp_ = ""; routerIp_ = ""; pairingKey_ = ""; id_ = ""; interconnectAttachment_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new VlanAttachment(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_VlanAttachment_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_VlanAttachment_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.class, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder.class); } public static final int PEER_VLAN_ID_FIELD_NUMBER = 1; private long peerVlanId_ = 0L; /** * * *
     * The peer vlan ID of the attachment.
     * 
* * int64 peer_vlan_id = 1; * * @return The peerVlanId. */ @java.lang.Override public long getPeerVlanId() { return peerVlanId_; } public static final int PEER_IP_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object peerIp_ = ""; /** * * *
     * The peer IP of the attachment.
     * 
* * string peer_ip = 2; * * @return The peerIp. */ @java.lang.Override public java.lang.String getPeerIp() { java.lang.Object ref = peerIp_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); peerIp_ = s; return s; } } /** * * *
     * The peer IP of the attachment.
     * 
* * string peer_ip = 2; * * @return The bytes for peerIp. */ @java.lang.Override public com.google.protobuf.ByteString getPeerIpBytes() { java.lang.Object ref = peerIp_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); peerIp_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int ROUTER_IP_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object routerIp_ = ""; /** * * *
     * The router IP of the attachment.
     * 
* * string router_ip = 3; * * @return The routerIp. */ @java.lang.Override public java.lang.String getRouterIp() { java.lang.Object ref = routerIp_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); routerIp_ = s; return s; } } /** * * *
     * The router IP of the attachment.
     * 
* * string router_ip = 3; * * @return The bytes for routerIp. */ @java.lang.Override public com.google.protobuf.ByteString getRouterIpBytes() { java.lang.Object ref = routerIp_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); routerIp_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int PAIRING_KEY_FIELD_NUMBER = 4; @SuppressWarnings("serial") private volatile java.lang.Object pairingKey_ = ""; /** * * *
     * Input only. Pairing key.
     * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The pairingKey. */ @java.lang.Override public java.lang.String getPairingKey() { java.lang.Object ref = pairingKey_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pairingKey_ = s; return s; } } /** * * *
     * Input only. Pairing key.
     * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bytes for pairingKey. */ @java.lang.Override public com.google.protobuf.ByteString getPairingKeyBytes() { java.lang.Object ref = pairingKey_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pairingKey_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int QOS_POLICY_FIELD_NUMBER = 5; private com.google.cloud.baremetalsolution.v2.VRF.QosPolicy qosPolicy_; /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return Whether the qosPolicy field is set. */ @java.lang.Override public boolean hasQosPolicy() { return qosPolicy_ != null; } /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return The qosPolicy. */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getQosPolicy() { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } /** * * *
     * The QOS policy applied to this VLAN attachment.
     * This value should be preferred to using qos at vrf level.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder getQosPolicyOrBuilder() { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } public static final int ID_FIELD_NUMBER = 6; @SuppressWarnings("serial") private volatile java.lang.Object id_ = ""; /** * * *
     * Immutable. The identifier of the attachment within vrf.
     * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The id. */ @java.lang.Override public java.lang.String getId() { java.lang.Object ref = id_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); id_ = s; return s; } } /** * * *
     * Immutable. The identifier of the attachment within vrf.
     * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The bytes for id. */ @java.lang.Override public com.google.protobuf.ByteString getIdBytes() { java.lang.Object ref = id_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); id_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int INTERCONNECT_ATTACHMENT_FIELD_NUMBER = 7; @SuppressWarnings("serial") private volatile java.lang.Object interconnectAttachment_ = ""; /** * * *
     * Optional. The name of the vlan attachment within vrf. This is of the form
     * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
     * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The interconnectAttachment. */ @java.lang.Override public java.lang.String getInterconnectAttachment() { java.lang.Object ref = interconnectAttachment_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); interconnectAttachment_ = s; return s; } } /** * * *
     * Optional. The name of the vlan attachment within vrf. This is of the form
     * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
     * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The bytes for interconnectAttachment. */ @java.lang.Override public com.google.protobuf.ByteString getInterconnectAttachmentBytes() { java.lang.Object ref = interconnectAttachment_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); interconnectAttachment_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (peerVlanId_ != 0L) { output.writeInt64(1, peerVlanId_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(peerIp_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, peerIp_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(routerIp_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, routerIp_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pairingKey_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pairingKey_); } if (qosPolicy_ != null) { output.writeMessage(5, getQosPolicy()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 6, id_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(interconnectAttachment_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, interconnectAttachment_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (peerVlanId_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, peerVlanId_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(peerIp_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, peerIp_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(routerIp_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, routerIp_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pairingKey_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pairingKey_); } if (qosPolicy_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getQosPolicy()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, id_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(interconnectAttachment_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, interconnectAttachment_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment)) { return super.equals(obj); } com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment other = (com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment) obj; if (getPeerVlanId() != other.getPeerVlanId()) return false; if (!getPeerIp().equals(other.getPeerIp())) return false; if (!getRouterIp().equals(other.getRouterIp())) return false; if (!getPairingKey().equals(other.getPairingKey())) return false; if (hasQosPolicy() != other.hasQosPolicy()) return false; if (hasQosPolicy()) { if (!getQosPolicy().equals(other.getQosPolicy())) return false; } if (!getId().equals(other.getId())) return false; if (!getInterconnectAttachment().equals(other.getInterconnectAttachment())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + PEER_VLAN_ID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getPeerVlanId()); hash = (37 * hash) + PEER_IP_FIELD_NUMBER; hash = (53 * hash) + getPeerIp().hashCode(); hash = (37 * hash) + ROUTER_IP_FIELD_NUMBER; hash = (53 * hash) + getRouterIp().hashCode(); hash = (37 * hash) + PAIRING_KEY_FIELD_NUMBER; hash = (53 * hash) + getPairingKey().hashCode(); if (hasQosPolicy()) { hash = (37 * hash) + QOS_POLICY_FIELD_NUMBER; hash = (53 * hash) + getQosPolicy().hashCode(); } hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); hash = (37 * hash) + INTERCONNECT_ATTACHMENT_FIELD_NUMBER; hash = (53 * hash) + getInterconnectAttachment().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
     * VLAN attachment details.
     * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF.VlanAttachment} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.baremetalsolution.v2.VRF.VlanAttachment) com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_VlanAttachment_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_VlanAttachment_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.class, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder.class); } // Construct using com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; peerVlanId_ = 0L; peerIp_ = ""; routerIp_ = ""; pairingKey_ = ""; qosPolicy_ = null; if (qosPolicyBuilder_ != null) { qosPolicyBuilder_.dispose(); qosPolicyBuilder_ = null; } id_ = ""; interconnectAttachment_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_VlanAttachment_descriptor; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment getDefaultInstanceForType() { return com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.getDefaultInstance(); } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment build() { com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment buildPartial() { com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment result = new com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.peerVlanId_ = peerVlanId_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.peerIp_ = peerIp_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.routerIp_ = routerIp_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.pairingKey_ = pairingKey_; } if (((from_bitField0_ & 0x00000010) != 0)) { result.qosPolicy_ = qosPolicyBuilder_ == null ? qosPolicy_ : qosPolicyBuilder_.build(); } if (((from_bitField0_ & 0x00000020) != 0)) { result.id_ = id_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.interconnectAttachment_ = interconnectAttachment_; } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment) { return mergeFrom((com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment other) { if (other == com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.getDefaultInstance()) return this; if (other.getPeerVlanId() != 0L) { setPeerVlanId(other.getPeerVlanId()); } if (!other.getPeerIp().isEmpty()) { peerIp_ = other.peerIp_; bitField0_ |= 0x00000002; onChanged(); } if (!other.getRouterIp().isEmpty()) { routerIp_ = other.routerIp_; bitField0_ |= 0x00000004; onChanged(); } if (!other.getPairingKey().isEmpty()) { pairingKey_ = other.pairingKey_; bitField0_ |= 0x00000008; onChanged(); } if (other.hasQosPolicy()) { mergeQosPolicy(other.getQosPolicy()); } if (!other.getId().isEmpty()) { id_ = other.id_; bitField0_ |= 0x00000020; onChanged(); } if (!other.getInterconnectAttachment().isEmpty()) { interconnectAttachment_ = other.interconnectAttachment_; bitField0_ |= 0x00000040; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 8: { peerVlanId_ = input.readInt64(); bitField0_ |= 0x00000001; break; } // case 8 case 18: { peerIp_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { routerIp_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 26 case 34: { pairingKey_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000008; break; } // case 34 case 42: { input.readMessage(getQosPolicyFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000010; break; } // case 42 case 50: { id_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000020; break; } // case 50 case 58: { interconnectAttachment_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000040; break; } // case 58 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private long peerVlanId_; /** * * *
       * The peer vlan ID of the attachment.
       * 
* * int64 peer_vlan_id = 1; * * @return The peerVlanId. */ @java.lang.Override public long getPeerVlanId() { return peerVlanId_; } /** * * *
       * The peer vlan ID of the attachment.
       * 
* * int64 peer_vlan_id = 1; * * @param value The peerVlanId to set. * @return This builder for chaining. */ public Builder setPeerVlanId(long value) { peerVlanId_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
       * The peer vlan ID of the attachment.
       * 
* * int64 peer_vlan_id = 1; * * @return This builder for chaining. */ public Builder clearPeerVlanId() { bitField0_ = (bitField0_ & ~0x00000001); peerVlanId_ = 0L; onChanged(); return this; } private java.lang.Object peerIp_ = ""; /** * * *
       * The peer IP of the attachment.
       * 
* * string peer_ip = 2; * * @return The peerIp. */ public java.lang.String getPeerIp() { java.lang.Object ref = peerIp_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); peerIp_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The peer IP of the attachment.
       * 
* * string peer_ip = 2; * * @return The bytes for peerIp. */ public com.google.protobuf.ByteString getPeerIpBytes() { java.lang.Object ref = peerIp_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); peerIp_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The peer IP of the attachment.
       * 
* * string peer_ip = 2; * * @param value The peerIp to set. * @return This builder for chaining. */ public Builder setPeerIp(java.lang.String value) { if (value == null) { throw new NullPointerException(); } peerIp_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
       * The peer IP of the attachment.
       * 
* * string peer_ip = 2; * * @return This builder for chaining. */ public Builder clearPeerIp() { peerIp_ = getDefaultInstance().getPeerIp(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** * * *
       * The peer IP of the attachment.
       * 
* * string peer_ip = 2; * * @param value The bytes for peerIp to set. * @return This builder for chaining. */ public Builder setPeerIpBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); peerIp_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } private java.lang.Object routerIp_ = ""; /** * * *
       * The router IP of the attachment.
       * 
* * string router_ip = 3; * * @return The routerIp. */ public java.lang.String getRouterIp() { java.lang.Object ref = routerIp_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); routerIp_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * The router IP of the attachment.
       * 
* * string router_ip = 3; * * @return The bytes for routerIp. */ public com.google.protobuf.ByteString getRouterIpBytes() { java.lang.Object ref = routerIp_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); routerIp_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * The router IP of the attachment.
       * 
* * string router_ip = 3; * * @param value The routerIp to set. * @return This builder for chaining. */ public Builder setRouterIp(java.lang.String value) { if (value == null) { throw new NullPointerException(); } routerIp_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
       * The router IP of the attachment.
       * 
* * string router_ip = 3; * * @return This builder for chaining. */ public Builder clearRouterIp() { routerIp_ = getDefaultInstance().getRouterIp(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** * * *
       * The router IP of the attachment.
       * 
* * string router_ip = 3; * * @param value The bytes for routerIp to set. * @return This builder for chaining. */ public Builder setRouterIpBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); routerIp_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } private java.lang.Object pairingKey_ = ""; /** * * *
       * Input only. Pairing key.
       * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The pairingKey. */ public java.lang.String getPairingKey() { java.lang.Object ref = pairingKey_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pairingKey_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Input only. Pairing key.
       * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return The bytes for pairingKey. */ public com.google.protobuf.ByteString getPairingKeyBytes() { java.lang.Object ref = pairingKey_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pairingKey_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Input only. Pairing key.
       * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The pairingKey to set. * @return This builder for chaining. */ public Builder setPairingKey(java.lang.String value) { if (value == null) { throw new NullPointerException(); } pairingKey_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** * * *
       * Input only. Pairing key.
       * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @return This builder for chaining. */ public Builder clearPairingKey() { pairingKey_ = getDefaultInstance().getPairingKey(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); return this; } /** * * *
       * Input only. Pairing key.
       * 
* * string pairing_key = 4 [(.google.api.field_behavior) = INPUT_ONLY]; * * @param value The bytes for pairingKey to set. * @return This builder for chaining. */ public Builder setPairingKeyBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); pairingKey_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } private com.google.cloud.baremetalsolution.v2.VRF.QosPolicy qosPolicy_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder> qosPolicyBuilder_; /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return Whether the qosPolicy field is set. */ public boolean hasQosPolicy() { return ((bitField0_ & 0x00000010) != 0); } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; * * @return The qosPolicy. */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getQosPolicy() { if (qosPolicyBuilder_ == null) { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } else { return qosPolicyBuilder_.getMessage(); } } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public Builder setQosPolicy(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy value) { if (qosPolicyBuilder_ == null) { if (value == null) { throw new NullPointerException(); } qosPolicy_ = value; } else { qosPolicyBuilder_.setMessage(value); } bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public Builder setQosPolicy( com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder builderForValue) { if (qosPolicyBuilder_ == null) { qosPolicy_ = builderForValue.build(); } else { qosPolicyBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public Builder mergeQosPolicy(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy value) { if (qosPolicyBuilder_ == null) { if (((bitField0_ & 0x00000010) != 0) && qosPolicy_ != null && qosPolicy_ != com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance()) { getQosPolicyBuilder().mergeFrom(value); } else { qosPolicy_ = value; } } else { qosPolicyBuilder_.mergeFrom(value); } bitField0_ |= 0x00000010; onChanged(); return this; } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public Builder clearQosPolicy() { bitField0_ = (bitField0_ & ~0x00000010); qosPolicy_ = null; if (qosPolicyBuilder_ != null) { qosPolicyBuilder_.dispose(); qosPolicyBuilder_ = null; } onChanged(); return this; } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder getQosPolicyBuilder() { bitField0_ |= 0x00000010; onChanged(); return getQosPolicyFieldBuilder().getBuilder(); } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder getQosPolicyOrBuilder() { if (qosPolicyBuilder_ != null) { return qosPolicyBuilder_.getMessageOrBuilder(); } else { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } } /** * * *
       * The QOS policy applied to this VLAN attachment.
       * This value should be preferred to using qos at vrf level.
       * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 5; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder> getQosPolicyFieldBuilder() { if (qosPolicyBuilder_ == null) { qosPolicyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder>( getQosPolicy(), getParentForChildren(), isClean()); qosPolicy_ = null; } return qosPolicyBuilder_; } private java.lang.Object id_ = ""; /** * * *
       * Immutable. The identifier of the attachment within vrf.
       * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The id. */ public java.lang.String getId() { java.lang.Object ref = id_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); id_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Immutable. The identifier of the attachment within vrf.
       * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return The bytes for id. */ public com.google.protobuf.ByteString getIdBytes() { java.lang.Object ref = id_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); id_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Immutable. The identifier of the attachment within vrf.
       * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @param value The id to set. * @return This builder for chaining. */ public Builder setId(java.lang.String value) { if (value == null) { throw new NullPointerException(); } id_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** * * *
       * Immutable. The identifier of the attachment within vrf.
       * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @return This builder for chaining. */ public Builder clearId() { id_ = getDefaultInstance().getId(); bitField0_ = (bitField0_ & ~0x00000020); onChanged(); return this; } /** * * *
       * Immutable. The identifier of the attachment within vrf.
       * 
* * string id = 6 [(.google.api.field_behavior) = IMMUTABLE]; * * @param value The bytes for id to set. * @return This builder for chaining. */ public Builder setIdBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); id_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } private java.lang.Object interconnectAttachment_ = ""; /** * * *
       * Optional. The name of the vlan attachment within vrf. This is of the form
       * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
       * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The interconnectAttachment. */ public java.lang.String getInterconnectAttachment() { java.lang.Object ref = interconnectAttachment_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); interconnectAttachment_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
       * Optional. The name of the vlan attachment within vrf. This is of the form
       * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
       * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return The bytes for interconnectAttachment. */ public com.google.protobuf.ByteString getInterconnectAttachmentBytes() { java.lang.Object ref = interconnectAttachment_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); interconnectAttachment_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
       * Optional. The name of the vlan attachment within vrf. This is of the form
       * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
       * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @param value The interconnectAttachment to set. * @return This builder for chaining. */ public Builder setInterconnectAttachment(java.lang.String value) { if (value == null) { throw new NullPointerException(); } interconnectAttachment_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** * * *
       * Optional. The name of the vlan attachment within vrf. This is of the form
       * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
       * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @return This builder for chaining. */ public Builder clearInterconnectAttachment() { interconnectAttachment_ = getDefaultInstance().getInterconnectAttachment(); bitField0_ = (bitField0_ & ~0x00000040); onChanged(); return this; } /** * * *
       * Optional. The name of the vlan attachment within vrf. This is of the form
       * projects/{project_number}/regions/{region}/interconnectAttachments/{interconnect_attachment}
       * 
* * * string interconnect_attachment = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } * * * @param value The bytes for interconnectAttachment to set. * @return This builder for chaining. */ public Builder setInterconnectAttachmentBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); interconnectAttachment_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.baremetalsolution.v2.VRF.VlanAttachment) } // @@protoc_insertion_point(class_scope:google.cloud.baremetalsolution.v2.VRF.VlanAttachment) private static final com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment(); } public static com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public VlanAttachment parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException() .setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment getDefaultInstanceForType() { return DEFAULT_INSTANCE; } } public static final int NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object name_ = ""; /** * * *
   * The name of the VRF.
   * 
* * string name = 1; * * @return The name. */ @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** * * *
   * The name of the VRF.
   * 
* * string name = 1; * * @return The bytes for name. */ @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int STATE_FIELD_NUMBER = 5; private int state_ = 0; /** * * *
   * The possible state of VRF.
   * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
   * The possible state of VRF.
   * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @return The state. */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.State getState() { com.google.cloud.baremetalsolution.v2.VRF.State result = com.google.cloud.baremetalsolution.v2.VRF.State.forNumber(state_); return result == null ? com.google.cloud.baremetalsolution.v2.VRF.State.UNRECOGNIZED : result; } public static final int QOS_POLICY_FIELD_NUMBER = 6; private com.google.cloud.baremetalsolution.v2.VRF.QosPolicy qosPolicy_; /** * * *
   * The QOS policy applied to this VRF.
   * The value is only meaningful when all the vlan attachments have the same
   * QoS. This field should not be used for new integrations, use vlan
   * attachment level qos instead. The field is left for backward-compatibility.
   * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; * * @return Whether the qosPolicy field is set. */ @java.lang.Override public boolean hasQosPolicy() { return qosPolicy_ != null; } /** * * *
   * The QOS policy applied to this VRF.
   * The value is only meaningful when all the vlan attachments have the same
   * QoS. This field should not be used for new integrations, use vlan
   * attachment level qos instead. The field is left for backward-compatibility.
   * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; * * @return The qosPolicy. */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getQosPolicy() { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } /** * * *
   * The QOS policy applied to this VRF.
   * The value is only meaningful when all the vlan attachments have the same
   * QoS. This field should not be used for new integrations, use vlan
   * attachment level qos instead. The field is left for backward-compatibility.
   * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder getQosPolicyOrBuilder() { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } public static final int VLAN_ATTACHMENTS_FIELD_NUMBER = 7; @SuppressWarnings("serial") private java.util.List vlanAttachments_; /** * * *
   * The list of VLAN attachments for the VRF.
   * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ @java.lang.Override public java.util.List getVlanAttachmentsList() { return vlanAttachments_; } /** * * *
   * The list of VLAN attachments for the VRF.
   * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ @java.lang.Override public java.util.List getVlanAttachmentsOrBuilderList() { return vlanAttachments_; } /** * * *
   * The list of VLAN attachments for the VRF.
   * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ @java.lang.Override public int getVlanAttachmentsCount() { return vlanAttachments_.size(); } /** * * *
   * The list of VLAN attachments for the VRF.
   * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment getVlanAttachments(int index) { return vlanAttachments_.get(index); } /** * * *
   * The list of VLAN attachments for the VRF.
   * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder getVlanAttachmentsOrBuilder(int index) { return vlanAttachments_.get(index); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } if (state_ != com.google.cloud.baremetalsolution.v2.VRF.State.STATE_UNSPECIFIED.getNumber()) { output.writeEnum(5, state_); } if (qosPolicy_ != null) { output.writeMessage(6, getQosPolicy()); } for (int i = 0; i < vlanAttachments_.size(); i++) { output.writeMessage(7, vlanAttachments_.get(i)); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } if (state_ != com.google.cloud.baremetalsolution.v2.VRF.State.STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, state_); } if (qosPolicy_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getQosPolicy()); } for (int i = 0; i < vlanAttachments_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, vlanAttachments_.get(i)); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.baremetalsolution.v2.VRF)) { return super.equals(obj); } com.google.cloud.baremetalsolution.v2.VRF other = (com.google.cloud.baremetalsolution.v2.VRF) obj; if (!getName().equals(other.getName())) return false; if (state_ != other.state_) return false; if (hasQosPolicy() != other.hasQosPolicy()) return false; if (hasQosPolicy()) { if (!getQosPolicy().equals(other.getQosPolicy())) return false; } if (!getVlanAttachmentsList().equals(other.getVlanAttachmentsList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; if (hasQosPolicy()) { hash = (37 * hash) + QOS_POLICY_FIELD_NUMBER; hash = (53 * hash) + getQosPolicy().hashCode(); } if (getVlanAttachmentsCount() > 0) { hash = (37 * hash) + VLAN_ATTACHMENTS_FIELD_NUMBER; hash = (53 * hash) + getVlanAttachmentsList().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.baremetalsolution.v2.VRF parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.cloud.baremetalsolution.v2.VRF prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
   * A network VRF.
   * 
* * Protobuf type {@code google.cloud.baremetalsolution.v2.VRF} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.baremetalsolution.v2.VRF) com.google.cloud.baremetalsolution.v2.VRFOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.baremetalsolution.v2.VRF.class, com.google.cloud.baremetalsolution.v2.VRF.Builder.class); } // Construct using com.google.cloud.baremetalsolution.v2.VRF.newBuilder() private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; name_ = ""; state_ = 0; qosPolicy_ = null; if (qosPolicyBuilder_ != null) { qosPolicyBuilder_.dispose(); qosPolicyBuilder_ = null; } if (vlanAttachmentsBuilder_ == null) { vlanAttachments_ = java.util.Collections.emptyList(); } else { vlanAttachments_ = null; vlanAttachmentsBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000008); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.baremetalsolution.v2.NetworkProto .internal_static_google_cloud_baremetalsolution_v2_VRF_descriptor; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF getDefaultInstanceForType() { return com.google.cloud.baremetalsolution.v2.VRF.getDefaultInstance(); } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF build() { com.google.cloud.baremetalsolution.v2.VRF result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF buildPartial() { com.google.cloud.baremetalsolution.v2.VRF result = new com.google.cloud.baremetalsolution.v2.VRF(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(com.google.cloud.baremetalsolution.v2.VRF result) { if (vlanAttachmentsBuilder_ == null) { if (((bitField0_ & 0x00000008) != 0)) { vlanAttachments_ = java.util.Collections.unmodifiableList(vlanAttachments_); bitField0_ = (bitField0_ & ~0x00000008); } result.vlanAttachments_ = vlanAttachments_; } else { result.vlanAttachments_ = vlanAttachmentsBuilder_.build(); } } private void buildPartial0(com.google.cloud.baremetalsolution.v2.VRF result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.name_ = name_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.state_ = state_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.qosPolicy_ = qosPolicyBuilder_ == null ? qosPolicy_ : qosPolicyBuilder_.build(); } } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.baremetalsolution.v2.VRF) { return mergeFrom((com.google.cloud.baremetalsolution.v2.VRF) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.baremetalsolution.v2.VRF other) { if (other == com.google.cloud.baremetalsolution.v2.VRF.getDefaultInstance()) return this; if (!other.getName().isEmpty()) { name_ = other.name_; bitField0_ |= 0x00000001; onChanged(); } if (other.state_ != 0) { setStateValue(other.getStateValue()); } if (other.hasQosPolicy()) { mergeQosPolicy(other.getQosPolicy()); } if (vlanAttachmentsBuilder_ == null) { if (!other.vlanAttachments_.isEmpty()) { if (vlanAttachments_.isEmpty()) { vlanAttachments_ = other.vlanAttachments_; bitField0_ = (bitField0_ & ~0x00000008); } else { ensureVlanAttachmentsIsMutable(); vlanAttachments_.addAll(other.vlanAttachments_); } onChanged(); } } else { if (!other.vlanAttachments_.isEmpty()) { if (vlanAttachmentsBuilder_.isEmpty()) { vlanAttachmentsBuilder_.dispose(); vlanAttachmentsBuilder_ = null; vlanAttachments_ = other.vlanAttachments_; bitField0_ = (bitField0_ & ~0x00000008); vlanAttachmentsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getVlanAttachmentsFieldBuilder() : null; } else { vlanAttachmentsBuilder_.addAllMessages(other.vlanAttachments_); } } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { name_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 40: { state_ = input.readEnum(); bitField0_ |= 0x00000002; break; } // case 40 case 50: { input.readMessage(getQosPolicyFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000004; break; } // case 50 case 58: { com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment m = input.readMessage( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.parser(), extensionRegistry); if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); vlanAttachments_.add(m); } else { vlanAttachmentsBuilder_.addMessage(m); } break; } // case 58 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object name_ = ""; /** * * *
     * The name of the VRF.
     * 
* * string name = 1; * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } else { return (java.lang.String) ref; } } /** * * *
     * The name of the VRF.
     * 
* * string name = 1; * * @return The bytes for name. */ public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * The name of the VRF.
     * 
* * string name = 1; * * @param value The name to set. * @return This builder for chaining. */ public Builder setName(java.lang.String value) { if (value == null) { throw new NullPointerException(); } name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** * * *
     * The name of the VRF.
     * 
* * string name = 1; * * @return This builder for chaining. */ public Builder clearName() { name_ = getDefaultInstance().getName(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** * * *
     * The name of the VRF.
     * 
* * string name = 1; * * @param value The bytes for name to set. * @return This builder for chaining. */ public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); name_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private int state_ = 0; /** * * *
     * The possible state of VRF.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** * * *
     * The possible state of VRF.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @param value The enum numeric value on the wire for state to set. * @return This builder for chaining. */ public Builder setStateValue(int value) { state_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** * * *
     * The possible state of VRF.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @return The state. */ @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF.State getState() { com.google.cloud.baremetalsolution.v2.VRF.State result = com.google.cloud.baremetalsolution.v2.VRF.State.forNumber(state_); return result == null ? com.google.cloud.baremetalsolution.v2.VRF.State.UNRECOGNIZED : result; } /** * * *
     * The possible state of VRF.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @param value The state to set. * @return This builder for chaining. */ public Builder setState(com.google.cloud.baremetalsolution.v2.VRF.State value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000002; state_ = value.getNumber(); onChanged(); return this; } /** * * *
     * The possible state of VRF.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.State state = 5; * * @return This builder for chaining. */ public Builder clearState() { bitField0_ = (bitField0_ & ~0x00000002); state_ = 0; onChanged(); return this; } private com.google.cloud.baremetalsolution.v2.VRF.QosPolicy qosPolicy_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder> qosPolicyBuilder_; /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; * * @return Whether the qosPolicy field is set. */ public boolean hasQosPolicy() { return ((bitField0_ & 0x00000004) != 0); } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; * * @return The qosPolicy. */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy getQosPolicy() { if (qosPolicyBuilder_ == null) { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } else { return qosPolicyBuilder_.getMessage(); } } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public Builder setQosPolicy(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy value) { if (qosPolicyBuilder_ == null) { if (value == null) { throw new NullPointerException(); } qosPolicy_ = value; } else { qosPolicyBuilder_.setMessage(value); } bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public Builder setQosPolicy( com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder builderForValue) { if (qosPolicyBuilder_ == null) { qosPolicy_ = builderForValue.build(); } else { qosPolicyBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public Builder mergeQosPolicy(com.google.cloud.baremetalsolution.v2.VRF.QosPolicy value) { if (qosPolicyBuilder_ == null) { if (((bitField0_ & 0x00000004) != 0) && qosPolicy_ != null && qosPolicy_ != com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance()) { getQosPolicyBuilder().mergeFrom(value); } else { qosPolicy_ = value; } } else { qosPolicyBuilder_.mergeFrom(value); } bitField0_ |= 0x00000004; onChanged(); return this; } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public Builder clearQosPolicy() { bitField0_ = (bitField0_ & ~0x00000004); qosPolicy_ = null; if (qosPolicyBuilder_ != null) { qosPolicyBuilder_.dispose(); qosPolicyBuilder_ = null; } onChanged(); return this; } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder getQosPolicyBuilder() { bitField0_ |= 0x00000004; onChanged(); return getQosPolicyFieldBuilder().getBuilder(); } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ public com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder getQosPolicyOrBuilder() { if (qosPolicyBuilder_ != null) { return qosPolicyBuilder_.getMessageOrBuilder(); } else { return qosPolicy_ == null ? com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.getDefaultInstance() : qosPolicy_; } } /** * * *
     * The QOS policy applied to this VRF.
     * The value is only meaningful when all the vlan attachments have the same
     * QoS. This field should not be used for new integrations, use vlan
     * attachment level qos instead. The field is left for backward-compatibility.
     * 
* * .google.cloud.baremetalsolution.v2.VRF.QosPolicy qos_policy = 6; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder> getQosPolicyFieldBuilder() { if (qosPolicyBuilder_ == null) { qosPolicyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.QosPolicy, com.google.cloud.baremetalsolution.v2.VRF.QosPolicy.Builder, com.google.cloud.baremetalsolution.v2.VRF.QosPolicyOrBuilder>( getQosPolicy(), getParentForChildren(), isClean()); qosPolicy_ = null; } return qosPolicyBuilder_; } private java.util.List vlanAttachments_ = java.util.Collections.emptyList(); private void ensureVlanAttachmentsIsMutable() { if (!((bitField0_ & 0x00000008) != 0)) { vlanAttachments_ = new java.util.ArrayList( vlanAttachments_); bitField0_ |= 0x00000008; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder> vlanAttachmentsBuilder_; /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public java.util.List getVlanAttachmentsList() { if (vlanAttachmentsBuilder_ == null) { return java.util.Collections.unmodifiableList(vlanAttachments_); } else { return vlanAttachmentsBuilder_.getMessageList(); } } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public int getVlanAttachmentsCount() { if (vlanAttachmentsBuilder_ == null) { return vlanAttachments_.size(); } else { return vlanAttachmentsBuilder_.getCount(); } } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment getVlanAttachments(int index) { if (vlanAttachmentsBuilder_ == null) { return vlanAttachments_.get(index); } else { return vlanAttachmentsBuilder_.getMessage(index); } } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder setVlanAttachments( int index, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment value) { if (vlanAttachmentsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureVlanAttachmentsIsMutable(); vlanAttachments_.set(index, value); onChanged(); } else { vlanAttachmentsBuilder_.setMessage(index, value); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder setVlanAttachments( int index, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder builderForValue) { if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); vlanAttachments_.set(index, builderForValue.build()); onChanged(); } else { vlanAttachmentsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder addVlanAttachments( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment value) { if (vlanAttachmentsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureVlanAttachmentsIsMutable(); vlanAttachments_.add(value); onChanged(); } else { vlanAttachmentsBuilder_.addMessage(value); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder addVlanAttachments( int index, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment value) { if (vlanAttachmentsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureVlanAttachmentsIsMutable(); vlanAttachments_.add(index, value); onChanged(); } else { vlanAttachmentsBuilder_.addMessage(index, value); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder addVlanAttachments( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder builderForValue) { if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); vlanAttachments_.add(builderForValue.build()); onChanged(); } else { vlanAttachmentsBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder addVlanAttachments( int index, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder builderForValue) { if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); vlanAttachments_.add(index, builderForValue.build()); onChanged(); } else { vlanAttachmentsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder addAllVlanAttachments( java.lang.Iterable values) { if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, vlanAttachments_); onChanged(); } else { vlanAttachmentsBuilder_.addAllMessages(values); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder clearVlanAttachments() { if (vlanAttachmentsBuilder_ == null) { vlanAttachments_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); } else { vlanAttachmentsBuilder_.clear(); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public Builder removeVlanAttachments(int index) { if (vlanAttachmentsBuilder_ == null) { ensureVlanAttachmentsIsMutable(); vlanAttachments_.remove(index); onChanged(); } else { vlanAttachmentsBuilder_.remove(index); } return this; } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder getVlanAttachmentsBuilder(int index) { return getVlanAttachmentsFieldBuilder().getBuilder(index); } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder getVlanAttachmentsOrBuilder(int index) { if (vlanAttachmentsBuilder_ == null) { return vlanAttachments_.get(index); } else { return vlanAttachmentsBuilder_.getMessageOrBuilder(index); } } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public java.util.List< ? extends com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder> getVlanAttachmentsOrBuilderList() { if (vlanAttachmentsBuilder_ != null) { return vlanAttachmentsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(vlanAttachments_); } } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder addVlanAttachmentsBuilder() { return getVlanAttachmentsFieldBuilder() .addBuilder( com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.getDefaultInstance()); } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder addVlanAttachmentsBuilder(int index) { return getVlanAttachmentsFieldBuilder() .addBuilder( index, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.getDefaultInstance()); } /** * * *
     * The list of VLAN attachments for the VRF.
     * 
* * repeated .google.cloud.baremetalsolution.v2.VRF.VlanAttachment vlan_attachments = 7; * */ public java.util.List getVlanAttachmentsBuilderList() { return getVlanAttachmentsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder> getVlanAttachmentsFieldBuilder() { if (vlanAttachmentsBuilder_ == null) { vlanAttachmentsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachment.Builder, com.google.cloud.baremetalsolution.v2.VRF.VlanAttachmentOrBuilder>( vlanAttachments_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); vlanAttachments_ = null; } return vlanAttachmentsBuilder_; } @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.baremetalsolution.v2.VRF) } // @@protoc_insertion_point(class_scope:google.cloud.baremetalsolution.v2.VRF) private static final com.google.cloud.baremetalsolution.v2.VRF DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.baremetalsolution.v2.VRF(); } public static com.google.cloud.baremetalsolution.v2.VRF getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public VRF parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.baremetalsolution.v2.VRF getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy