Class StandardResourceMetadata.Builder

    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • internalGetMutableMapField

        protected com.google.protobuf.MapField internalGetMutableMapField​(int number)
        Overrides:
        internalGetMutableMapField in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • getDefaultInstanceForType

        public StandardResourceMetadata getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public StandardResourceMetadata build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public StandardResourceMetadata buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • setRepeatedField

        public StandardResourceMetadata.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                 int index,
                                                                 Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • addRepeatedField

        public StandardResourceMetadata.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                 Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • mergeFrom

        public StandardResourceMetadata.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<StandardResourceMetadata.Builder>
        Throws:
        IOException
      • getName

        public String getName()
         The full resource name. For example:
         `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
         See [Resource
         Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
         for more information.
         
        string name = 1;
        Specified by:
        getName in interface StandardResourceMetadataOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         The full resource name. For example:
         `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
         See [Resource
         Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
         for more information.
         
        string name = 1;
        Specified by:
        getNameBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for name.
      • setName

        public StandardResourceMetadata.Builder setName​(String value)
         The full resource name. For example:
         `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
         See [Resource
         Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
         for more information.
         
        string name = 1;
        Parameters:
        value - The name to set.
        Returns:
        This builder for chaining.
      • clearName

        public StandardResourceMetadata.Builder clearName()
         The full resource name. For example:
         `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
         See [Resource
         Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
         for more information.
         
        string name = 1;
        Returns:
        This builder for chaining.
      • setNameBytes

        public StandardResourceMetadata.Builder setNameBytes​(com.google.protobuf.ByteString value)
         The full resource name. For example:
         `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
         See [Resource
         Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
         for more information.
         
        string name = 1;
        Parameters:
        value - The bytes for name to set.
        Returns:
        This builder for chaining.
      • getAssetTypeBytes

        public com.google.protobuf.ByteString getAssetTypeBytes()
         The type of this resource.
         For example: "compute.googleapis.com/Disk".
         
        string asset_type = 2;
        Specified by:
        getAssetTypeBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for assetType.
      • setAssetType

        public StandardResourceMetadata.Builder setAssetType​(String value)
         The type of this resource.
         For example: "compute.googleapis.com/Disk".
         
        string asset_type = 2;
        Parameters:
        value - The assetType to set.
        Returns:
        This builder for chaining.
      • clearAssetType

        public StandardResourceMetadata.Builder clearAssetType()
         The type of this resource.
         For example: "compute.googleapis.com/Disk".
         
        string asset_type = 2;
        Returns:
        This builder for chaining.
      • setAssetTypeBytes

        public StandardResourceMetadata.Builder setAssetTypeBytes​(com.google.protobuf.ByteString value)
         The type of this resource.
         For example: "compute.googleapis.com/Disk".
         
        string asset_type = 2;
        Parameters:
        value - The bytes for assetType to set.
        Returns:
        This builder for chaining.
      • getProjectBytes

        public com.google.protobuf.ByteString getProjectBytes()
         The project that this resource belongs to, in the form of
         `projects/{project_number}`.
         
        string project = 3;
        Specified by:
        getProjectBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for project.
      • setProject

        public StandardResourceMetadata.Builder setProject​(String value)
         The project that this resource belongs to, in the form of
         `projects/{project_number}`.
         
        string project = 3;
        Parameters:
        value - The project to set.
        Returns:
        This builder for chaining.
      • clearProject

        public StandardResourceMetadata.Builder clearProject()
         The project that this resource belongs to, in the form of
         `projects/{project_number}`.
         
        string project = 3;
        Returns:
        This builder for chaining.
      • setProjectBytes

        public StandardResourceMetadata.Builder setProjectBytes​(com.google.protobuf.ByteString value)
         The project that this resource belongs to, in the form of
         `projects/{project_number}`.
         
        string project = 3;
        Parameters:
        value - The bytes for project to set.
        Returns:
        This builder for chaining.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         The display name of this resource.
         
        string display_name = 4;
        Specified by:
        getDisplayNameBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for displayName.
      • setDisplayName

        public StandardResourceMetadata.Builder setDisplayName​(String value)
         The display name of this resource.
         
        string display_name = 4;
        Parameters:
        value - The displayName to set.
        Returns:
        This builder for chaining.
      • clearDisplayName

        public StandardResourceMetadata.Builder clearDisplayName()
         The display name of this resource.
         
        string display_name = 4;
        Returns:
        This builder for chaining.
      • setDisplayNameBytes

        public StandardResourceMetadata.Builder setDisplayNameBytes​(com.google.protobuf.ByteString value)
         The display name of this resource.
         
        string display_name = 4;
        Parameters:
        value - The bytes for displayName to set.
        Returns:
        This builder for chaining.
      • getDescription

        public String getDescription()
         One or more paragraphs of text description of this resource. Maximum length
         could be up to 1M bytes.
         
        string description = 5;
        Specified by:
        getDescription in interface StandardResourceMetadataOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         One or more paragraphs of text description of this resource. Maximum length
         could be up to 1M bytes.
         
        string description = 5;
        Specified by:
        getDescriptionBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for description.
      • setDescription

        public StandardResourceMetadata.Builder setDescription​(String value)
         One or more paragraphs of text description of this resource. Maximum length
         could be up to 1M bytes.
         
        string description = 5;
        Parameters:
        value - The description to set.
        Returns:
        This builder for chaining.
      • clearDescription

        public StandardResourceMetadata.Builder clearDescription()
         One or more paragraphs of text description of this resource. Maximum length
         could be up to 1M bytes.
         
        string description = 5;
        Returns:
        This builder for chaining.
      • setDescriptionBytes

        public StandardResourceMetadata.Builder setDescriptionBytes​(com.google.protobuf.ByteString value)
         One or more paragraphs of text description of this resource. Maximum length
         could be up to 1M bytes.
         
        string description = 5;
        Parameters:
        value - The bytes for description to set.
        Returns:
        This builder for chaining.
      • getAdditionalAttributesList

        public com.google.protobuf.ProtocolStringList getAdditionalAttributesList()
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Specified by:
        getAdditionalAttributesList in interface StandardResourceMetadataOrBuilder
        Returns:
        A list containing the additionalAttributes.
      • getAdditionalAttributesCount

        public int getAdditionalAttributesCount()
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Specified by:
        getAdditionalAttributesCount in interface StandardResourceMetadataOrBuilder
        Returns:
        The count of additionalAttributes.
      • getAdditionalAttributes

        public String getAdditionalAttributes​(int index)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Specified by:
        getAdditionalAttributes in interface StandardResourceMetadataOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The additionalAttributes at the given index.
      • getAdditionalAttributesBytes

        public com.google.protobuf.ByteString getAdditionalAttributesBytes​(int index)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Specified by:
        getAdditionalAttributesBytes in interface StandardResourceMetadataOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the additionalAttributes at the given index.
      • setAdditionalAttributes

        public StandardResourceMetadata.Builder setAdditionalAttributes​(int index,
                                                                        String value)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Parameters:
        index - The index to set the value at.
        value - The additionalAttributes to set.
        Returns:
        This builder for chaining.
      • addAdditionalAttributes

        public StandardResourceMetadata.Builder addAdditionalAttributes​(String value)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Parameters:
        value - The additionalAttributes to add.
        Returns:
        This builder for chaining.
      • addAllAdditionalAttributes

        public StandardResourceMetadata.Builder addAllAdditionalAttributes​(Iterable<String> values)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Parameters:
        values - The additionalAttributes to add.
        Returns:
        This builder for chaining.
      • clearAdditionalAttributes

        public StandardResourceMetadata.Builder clearAdditionalAttributes()
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Returns:
        This builder for chaining.
      • addAdditionalAttributesBytes

        public StandardResourceMetadata.Builder addAdditionalAttributesBytes​(com.google.protobuf.ByteString value)
         Additional searchable attributes of this resource.
         Informational only. The exact set of attributes is subject to change.
         For example: project id, DNS name etc.
         
        repeated string additional_attributes = 10;
        Parameters:
        value - The bytes of the additionalAttributes to add.
        Returns:
        This builder for chaining.
      • getLocationBytes

        public com.google.protobuf.ByteString getLocationBytes()
         Location can be "global", regional like "us-east1", or zonal like
         "us-west1-b".
         
        string location = 11;
        Specified by:
        getLocationBytes in interface StandardResourceMetadataOrBuilder
        Returns:
        The bytes for location.
      • setLocation

        public StandardResourceMetadata.Builder setLocation​(String value)
         Location can be "global", regional like "us-east1", or zonal like
         "us-west1-b".
         
        string location = 11;
        Parameters:
        value - The location to set.
        Returns:
        This builder for chaining.
      • clearLocation

        public StandardResourceMetadata.Builder clearLocation()
         Location can be "global", regional like "us-east1", or zonal like
         "us-west1-b".
         
        string location = 11;
        Returns:
        This builder for chaining.
      • setLocationBytes

        public StandardResourceMetadata.Builder setLocationBytes​(com.google.protobuf.ByteString value)
         Location can be "global", regional like "us-east1", or zonal like
         "us-west1-b".
         
        string location = 11;
        Parameters:
        value - The bytes for location to set.
        Returns:
        This builder for chaining.
      • getLabelsCount

        public int getLabelsCount()
        Description copied from interface: StandardResourceMetadataOrBuilder
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
        Specified by:
        getLabelsCount in interface StandardResourceMetadataOrBuilder
      • containsLabels

        public boolean containsLabels​(String key)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
        Specified by:
        containsLabels in interface StandardResourceMetadataOrBuilder
      • getLabelsMap

        public Map<String,​String> getLabelsMap()
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
        Specified by:
        getLabelsMap in interface StandardResourceMetadataOrBuilder
      • getLabelsOrDefault

        public String getLabelsOrDefault​(String key,
                                         String defaultValue)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
        Specified by:
        getLabelsOrDefault in interface StandardResourceMetadataOrBuilder
      • getLabelsOrThrow

        public String getLabelsOrThrow​(String key)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
        Specified by:
        getLabelsOrThrow in interface StandardResourceMetadataOrBuilder
      • removeLabels

        public StandardResourceMetadata.Builder removeLabels​(String key)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
      • getMutableLabels

        @Deprecated
        public Map<String,​String> getMutableLabels()
        Deprecated.
        Use alternate mutation accessors instead.
      • putLabels

        public StandardResourceMetadata.Builder putLabels​(String key,
                                                          String value)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
      • putAllLabels

        public StandardResourceMetadata.Builder putAllLabels​(Map<String,​String> values)
         Labels associated with this resource. See [Labelling and grouping Google
         Cloud
         resources](https://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        map<string, string> labels = 12;
      • getNetworkTagsList

        public com.google.protobuf.ProtocolStringList getNetworkTagsList()
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Specified by:
        getNetworkTagsList in interface StandardResourceMetadataOrBuilder
        Returns:
        A list containing the networkTags.
      • getNetworkTagsCount

        public int getNetworkTagsCount()
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Specified by:
        getNetworkTagsCount in interface StandardResourceMetadataOrBuilder
        Returns:
        The count of networkTags.
      • getNetworkTags

        public String getNetworkTags​(int index)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Specified by:
        getNetworkTags in interface StandardResourceMetadataOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The networkTags at the given index.
      • getNetworkTagsBytes

        public com.google.protobuf.ByteString getNetworkTagsBytes​(int index)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Specified by:
        getNetworkTagsBytes in interface StandardResourceMetadataOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the networkTags at the given index.
      • setNetworkTags

        public StandardResourceMetadata.Builder setNetworkTags​(int index,
                                                               String value)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Parameters:
        index - The index to set the value at.
        value - The networkTags to set.
        Returns:
        This builder for chaining.
      • addNetworkTags

        public StandardResourceMetadata.Builder addNetworkTags​(String value)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Parameters:
        value - The networkTags to add.
        Returns:
        This builder for chaining.
      • addAllNetworkTags

        public StandardResourceMetadata.Builder addAllNetworkTags​(Iterable<String> values)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Parameters:
        values - The networkTags to add.
        Returns:
        This builder for chaining.
      • clearNetworkTags

        public StandardResourceMetadata.Builder clearNetworkTags()
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Returns:
        This builder for chaining.
      • addNetworkTagsBytes

        public StandardResourceMetadata.Builder addNetworkTagsBytes​(com.google.protobuf.ByteString value)
         Network tags associated with this resource. Like labels, network tags are a
         type of annotations used to group Google Cloud resources. See [Labelling
         Google Cloud
         resources](lhttps://cloud.google.com/blog/products/gcp/labelling-and-grouping-your-google-cloud-platform-resources)
         for more information.
         
        repeated string network_tags = 13;
        Parameters:
        value - The bytes of the networkTags to add.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final StandardResourceMetadata.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>
      • mergeUnknownFields

        public final StandardResourceMetadata.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<StandardResourceMetadata.Builder>