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

com.google.api.MonitoredResourceDescriptor Maven / Gradle / Ivy

There is a newer version: 0.0.6
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/api/monitored_resource.proto

package com.google.api;

/**
 * Protobuf type {@code google.api.MonitoredResourceDescriptor}
 *
 * 
 * A description of a type of monitored resource.
 * 
*/ public final class MonitoredResourceDescriptor extends com.google.protobuf.GeneratedMessage implements // @@protoc_insertion_point(message_implements:google.api.MonitoredResourceDescriptor) MonitoredResourceDescriptorOrBuilder { // Use MonitoredResourceDescriptor.newBuilder() to construct. private MonitoredResourceDescriptor(com.google.protobuf.GeneratedMessage.Builder builder) { super(builder); } private MonitoredResourceDescriptor() { type_ = ""; displayName_ = ""; description_ = ""; labels_ = java.util.Collections.emptyList(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private MonitoredResourceDescriptor( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) { this(); int mutable_bitField0_ = 0; try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!input.skipField(tag)) { done = true; } break; } case 10: { String s = input.readStringRequireUtf8(); type_ = s; break; } case 18: { String s = input.readStringRequireUtf8(); displayName_ = s; break; } case 26: { String s = input.readStringRequireUtf8(); description_ = s; break; } case 34: { if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { labels_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000008; } labels_.add(input.readMessage(com.google.api.LabelDescriptor.parser(), extensionRegistry)); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw new RuntimeException(e.setUnfinishedMessage(this)); } catch (java.io.IOException e) { throw new RuntimeException( new com.google.protobuf.InvalidProtocolBufferException( e.getMessage()).setUnfinishedMessage(this)); } finally { if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) { labels_ = java.util.Collections.unmodifiableList(labels_); } makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.api.MonitoredResourceProto.internal_static_google_api_MonitoredResourceDescriptor_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.api.MonitoredResourceProto.internal_static_google_api_MonitoredResourceDescriptor_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.api.MonitoredResourceDescriptor.class, com.google.api.MonitoredResourceDescriptor.Builder.class); } private int bitField0_; public static final int TYPE_FIELD_NUMBER = 1; private volatile java.lang.Object type_; /** * optional string type = 1; * *
   * The monitored resource type. For example, the type `"cloudsql_database"`
   * represents databases in Google Cloud SQL.
   * 
*/ public java.lang.String getType() { java.lang.Object ref = type_; 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(); type_ = s; return s; } } /** * optional string type = 1; * *
   * The monitored resource type. For example, the type `"cloudsql_database"`
   * represents databases in Google Cloud SQL.
   * 
*/ public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DISPLAY_NAME_FIELD_NUMBER = 2; private volatile java.lang.Object displayName_; /** * optional string display_name = 2; * *
   * A concise name for the monitored resource type, which is displayed in user
   * interfaces. For example, `"Cloud SQL database"`.
   * 
*/ public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; 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(); displayName_ = s; return s; } } /** * optional string display_name = 2; * *
   * A concise name for the monitored resource type, which is displayed in user
   * interfaces. For example, `"Cloud SQL database"`.
   * 
*/ public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DESCRIPTION_FIELD_NUMBER = 3; private volatile java.lang.Object description_; /** * optional string description = 3; * *
   * A detailed description of the monitored resource type, which is used in
   * documentation.
   * 
*/ public java.lang.String getDescription() { java.lang.Object ref = description_; 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(); description_ = s; return s; } } /** * optional string description = 3; * *
   * A detailed description of the monitored resource type, which is used in
   * documentation.
   * 
*/ public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); description_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LABELS_FIELD_NUMBER = 4; private java.util.List labels_; /** * repeated .google.api.LabelDescriptor labels = 4; * *
   * A set of labels that can be used to describe instances of this monitored
   * resource type. For example, Cloud SQL databases can be labeled with
   * their `"database_id"` and their `"zone"`.
   * 
*/ public java.util.List getLabelsList() { return labels_; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
   * A set of labels that can be used to describe instances of this monitored
   * resource type. For example, Cloud SQL databases can be labeled with
   * their `"database_id"` and their `"zone"`.
   * 
*/ public java.util.List getLabelsOrBuilderList() { return labels_; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
   * A set of labels that can be used to describe instances of this monitored
   * resource type. For example, Cloud SQL databases can be labeled with
   * their `"database_id"` and their `"zone"`.
   * 
*/ public int getLabelsCount() { return labels_.size(); } /** * repeated .google.api.LabelDescriptor labels = 4; * *
   * A set of labels that can be used to describe instances of this monitored
   * resource type. For example, Cloud SQL databases can be labeled with
   * their `"database_id"` and their `"zone"`.
   * 
*/ public com.google.api.LabelDescriptor getLabels(int index) { return labels_.get(index); } /** * repeated .google.api.LabelDescriptor labels = 4; * *
   * A set of labels that can be used to describe instances of this monitored
   * resource type. For example, Cloud SQL databases can be labeled with
   * their `"database_id"` and their `"zone"`.
   * 
*/ public com.google.api.LabelDescriptorOrBuilder getLabelsOrBuilder( int index) { return labels_.get(index); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getTypeBytes().isEmpty()) { com.google.protobuf.GeneratedMessage.writeString(output, 1, type_); } if (!getDisplayNameBytes().isEmpty()) { com.google.protobuf.GeneratedMessage.writeString(output, 2, displayName_); } if (!getDescriptionBytes().isEmpty()) { com.google.protobuf.GeneratedMessage.writeString(output, 3, description_); } for (int i = 0; i < labels_.size(); i++) { output.writeMessage(4, labels_.get(i)); } } public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!getTypeBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessage.computeStringSize(1, type_); } if (!getDisplayNameBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessage.computeStringSize(2, displayName_); } if (!getDescriptionBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessage.computeStringSize(3, description_); } for (int i = 0; i < labels_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, labels_.get(i)); } memoizedSize = size; return size; } private static final long serialVersionUID = 0L; public static com.google.api.MonitoredResourceDescriptor parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.api.MonitoredResourceDescriptor 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.api.MonitoredResourceDescriptor parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.api.MonitoredResourceDescriptor parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.api.MonitoredResourceDescriptor parseFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static com.google.api.MonitoredResourceDescriptor parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public static com.google.api.MonitoredResourceDescriptor parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseDelimitedFrom(input); } public static com.google.api.MonitoredResourceDescriptor parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseDelimitedFrom(input, extensionRegistry); } public static com.google.api.MonitoredResourceDescriptor parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static com.google.api.MonitoredResourceDescriptor parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.api.MonitoredResourceDescriptor prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code google.api.MonitoredResourceDescriptor} * *
   * A description of a type of monitored resource.
   * 
*/ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder implements // @@protoc_insertion_point(builder_implements:google.api.MonitoredResourceDescriptor) com.google.api.MonitoredResourceDescriptorOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.api.MonitoredResourceProto.internal_static_google_api_MonitoredResourceDescriptor_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.api.MonitoredResourceProto.internal_static_google_api_MonitoredResourceDescriptor_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.api.MonitoredResourceDescriptor.class, com.google.api.MonitoredResourceDescriptor.Builder.class); } // Construct using com.google.api.MonitoredResourceDescriptor.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { getLabelsFieldBuilder(); } } public Builder clear() { super.clear(); type_ = ""; displayName_ = ""; description_ = ""; if (labelsBuilder_ == null) { labels_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000008); } else { labelsBuilder_.clear(); } return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.api.MonitoredResourceProto.internal_static_google_api_MonitoredResourceDescriptor_descriptor; } public com.google.api.MonitoredResourceDescriptor getDefaultInstanceForType() { return com.google.api.MonitoredResourceDescriptor.getDefaultInstance(); } public com.google.api.MonitoredResourceDescriptor build() { com.google.api.MonitoredResourceDescriptor result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public com.google.api.MonitoredResourceDescriptor buildPartial() { com.google.api.MonitoredResourceDescriptor result = new com.google.api.MonitoredResourceDescriptor(this); int from_bitField0_ = bitField0_; int to_bitField0_ = 0; result.type_ = type_; result.displayName_ = displayName_; result.description_ = description_; if (labelsBuilder_ == null) { if (((bitField0_ & 0x00000008) == 0x00000008)) { labels_ = java.util.Collections.unmodifiableList(labels_); bitField0_ = (bitField0_ & ~0x00000008); } result.labels_ = labels_; } else { result.labels_ = labelsBuilder_.build(); } result.bitField0_ = to_bitField0_; onBuilt(); return result; } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.api.MonitoredResourceDescriptor) { return mergeFrom((com.google.api.MonitoredResourceDescriptor)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.api.MonitoredResourceDescriptor other) { if (other == com.google.api.MonitoredResourceDescriptor.getDefaultInstance()) return this; if (!other.getType().isEmpty()) { type_ = other.type_; onChanged(); } if (!other.getDisplayName().isEmpty()) { displayName_ = other.displayName_; onChanged(); } if (!other.getDescription().isEmpty()) { description_ = other.description_; onChanged(); } if (labelsBuilder_ == null) { if (!other.labels_.isEmpty()) { if (labels_.isEmpty()) { labels_ = other.labels_; bitField0_ = (bitField0_ & ~0x00000008); } else { ensureLabelsIsMutable(); labels_.addAll(other.labels_); } onChanged(); } } else { if (!other.labels_.isEmpty()) { if (labelsBuilder_.isEmpty()) { labelsBuilder_.dispose(); labelsBuilder_ = null; labels_ = other.labels_; bitField0_ = (bitField0_ & ~0x00000008); labelsBuilder_ = com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? getLabelsFieldBuilder() : null; } else { labelsBuilder_.addAllMessages(other.labels_); } } } onChanged(); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.api.MonitoredResourceDescriptor parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.api.MonitoredResourceDescriptor) e.getUnfinishedMessage(); throw e; } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; private java.lang.Object type_ = ""; /** * optional string type = 1; * *
     * The monitored resource type. For example, the type `"cloudsql_database"`
     * represents databases in Google Cloud SQL.
     * 
*/ public java.lang.String getType() { java.lang.Object ref = type_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } else { return (java.lang.String) ref; } } /** * optional string type = 1; * *
     * The monitored resource type. For example, the type `"cloudsql_database"`
     * represents databases in Google Cloud SQL.
     * 
*/ public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * optional string type = 1; * *
     * The monitored resource type. For example, the type `"cloudsql_database"`
     * represents databases in Google Cloud SQL.
     * 
*/ public Builder setType( java.lang.String value) { if (value == null) { throw new NullPointerException(); } type_ = value; onChanged(); return this; } /** * optional string type = 1; * *
     * The monitored resource type. For example, the type `"cloudsql_database"`
     * represents databases in Google Cloud SQL.
     * 
*/ public Builder clearType() { type_ = getDefaultInstance().getType(); onChanged(); return this; } /** * optional string type = 1; * *
     * The monitored resource type. For example, the type `"cloudsql_database"`
     * represents databases in Google Cloud SQL.
     * 
*/ public Builder setTypeBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); type_ = value; onChanged(); return this; } private java.lang.Object displayName_ = ""; /** * optional string display_name = 2; * *
     * A concise name for the monitored resource type, which is displayed in user
     * interfaces. For example, `"Cloud SQL database"`.
     * 
*/ public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } else { return (java.lang.String) ref; } } /** * optional string display_name = 2; * *
     * A concise name for the monitored resource type, which is displayed in user
     * interfaces. For example, `"Cloud SQL database"`.
     * 
*/ public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); displayName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * optional string display_name = 2; * *
     * A concise name for the monitored resource type, which is displayed in user
     * interfaces. For example, `"Cloud SQL database"`.
     * 
*/ public Builder setDisplayName( java.lang.String value) { if (value == null) { throw new NullPointerException(); } displayName_ = value; onChanged(); return this; } /** * optional string display_name = 2; * *
     * A concise name for the monitored resource type, which is displayed in user
     * interfaces. For example, `"Cloud SQL database"`.
     * 
*/ public Builder clearDisplayName() { displayName_ = getDefaultInstance().getDisplayName(); onChanged(); return this; } /** * optional string display_name = 2; * *
     * A concise name for the monitored resource type, which is displayed in user
     * interfaces. For example, `"Cloud SQL database"`.
     * 
*/ public Builder setDisplayNameBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); displayName_ = value; onChanged(); return this; } private java.lang.Object description_ = ""; /** * optional string description = 3; * *
     * A detailed description of the monitored resource type, which is used in
     * documentation.
     * 
*/ public java.lang.String getDescription() { java.lang.Object ref = description_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); description_ = s; return s; } else { return (java.lang.String) ref; } } /** * optional string description = 3; * *
     * A detailed description of the monitored resource type, which is used in
     * documentation.
     * 
*/ public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); description_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * optional string description = 3; * *
     * A detailed description of the monitored resource type, which is used in
     * documentation.
     * 
*/ public Builder setDescription( java.lang.String value) { if (value == null) { throw new NullPointerException(); } description_ = value; onChanged(); return this; } /** * optional string description = 3; * *
     * A detailed description of the monitored resource type, which is used in
     * documentation.
     * 
*/ public Builder clearDescription() { description_ = getDefaultInstance().getDescription(); onChanged(); return this; } /** * optional string description = 3; * *
     * A detailed description of the monitored resource type, which is used in
     * documentation.
     * 
*/ public Builder setDescriptionBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); description_ = value; onChanged(); return this; } private java.util.List labels_ = java.util.Collections.emptyList(); private void ensureLabelsIsMutable() { if (!((bitField0_ & 0x00000008) == 0x00000008)) { labels_ = new java.util.ArrayList(labels_); bitField0_ |= 0x00000008; } } private com.google.protobuf.RepeatedFieldBuilder< com.google.api.LabelDescriptor, com.google.api.LabelDescriptor.Builder, com.google.api.LabelDescriptorOrBuilder> labelsBuilder_; /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public java.util.List getLabelsList() { if (labelsBuilder_ == null) { return java.util.Collections.unmodifiableList(labels_); } else { return labelsBuilder_.getMessageList(); } } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public int getLabelsCount() { if (labelsBuilder_ == null) { return labels_.size(); } else { return labelsBuilder_.getCount(); } } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public com.google.api.LabelDescriptor getLabels(int index) { if (labelsBuilder_ == null) { return labels_.get(index); } else { return labelsBuilder_.getMessage(index); } } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder setLabels( int index, com.google.api.LabelDescriptor value) { if (labelsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLabelsIsMutable(); labels_.set(index, value); onChanged(); } else { labelsBuilder_.setMessage(index, value); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder setLabels( int index, com.google.api.LabelDescriptor.Builder builderForValue) { if (labelsBuilder_ == null) { ensureLabelsIsMutable(); labels_.set(index, builderForValue.build()); onChanged(); } else { labelsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder addLabels(com.google.api.LabelDescriptor value) { if (labelsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLabelsIsMutable(); labels_.add(value); onChanged(); } else { labelsBuilder_.addMessage(value); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder addLabels( int index, com.google.api.LabelDescriptor value) { if (labelsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureLabelsIsMutable(); labels_.add(index, value); onChanged(); } else { labelsBuilder_.addMessage(index, value); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder addLabels( com.google.api.LabelDescriptor.Builder builderForValue) { if (labelsBuilder_ == null) { ensureLabelsIsMutable(); labels_.add(builderForValue.build()); onChanged(); } else { labelsBuilder_.addMessage(builderForValue.build()); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder addLabels( int index, com.google.api.LabelDescriptor.Builder builderForValue) { if (labelsBuilder_ == null) { ensureLabelsIsMutable(); labels_.add(index, builderForValue.build()); onChanged(); } else { labelsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder addAllLabels( java.lang.Iterable values) { if (labelsBuilder_ == null) { ensureLabelsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, labels_); onChanged(); } else { labelsBuilder_.addAllMessages(values); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder clearLabels() { if (labelsBuilder_ == null) { labels_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); } else { labelsBuilder_.clear(); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public Builder removeLabels(int index) { if (labelsBuilder_ == null) { ensureLabelsIsMutable(); labels_.remove(index); onChanged(); } else { labelsBuilder_.remove(index); } return this; } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public com.google.api.LabelDescriptor.Builder getLabelsBuilder( int index) { return getLabelsFieldBuilder().getBuilder(index); } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public com.google.api.LabelDescriptorOrBuilder getLabelsOrBuilder( int index) { if (labelsBuilder_ == null) { return labels_.get(index); } else { return labelsBuilder_.getMessageOrBuilder(index); } } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public java.util.List getLabelsOrBuilderList() { if (labelsBuilder_ != null) { return labelsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(labels_); } } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public com.google.api.LabelDescriptor.Builder addLabelsBuilder() { return getLabelsFieldBuilder().addBuilder( com.google.api.LabelDescriptor.getDefaultInstance()); } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public com.google.api.LabelDescriptor.Builder addLabelsBuilder( int index) { return getLabelsFieldBuilder().addBuilder( index, com.google.api.LabelDescriptor.getDefaultInstance()); } /** * repeated .google.api.LabelDescriptor labels = 4; * *
     * A set of labels that can be used to describe instances of this monitored
     * resource type. For example, Cloud SQL databases can be labeled with
     * their `"database_id"` and their `"zone"`.
     * 
*/ public java.util.List getLabelsBuilderList() { return getLabelsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilder< com.google.api.LabelDescriptor, com.google.api.LabelDescriptor.Builder, com.google.api.LabelDescriptorOrBuilder> getLabelsFieldBuilder() { if (labelsBuilder_ == null) { labelsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< com.google.api.LabelDescriptor, com.google.api.LabelDescriptor.Builder, com.google.api.LabelDescriptorOrBuilder>( labels_, ((bitField0_ & 0x00000008) == 0x00000008), getParentForChildren(), isClean()); labels_ = null; } return labelsBuilder_; } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return this; } // @@protoc_insertion_point(builder_scope:google.api.MonitoredResourceDescriptor) } // @@protoc_insertion_point(class_scope:google.api.MonitoredResourceDescriptor) private static final com.google.api.MonitoredResourceDescriptor DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.api.MonitoredResourceDescriptor(); } public static com.google.api.MonitoredResourceDescriptor getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { public MonitoredResourceDescriptor parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { try { return new MonitoredResourceDescriptor(input, extensionRegistry); } catch (RuntimeException e) { if (e.getCause() instanceof com.google.protobuf.InvalidProtocolBufferException) { throw (com.google.protobuf.InvalidProtocolBufferException) e.getCause(); } throw e; } } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } public com.google.api.MonitoredResourceDescriptor getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy