Class SavedQuery.Builder (3.7.1)

public static final class SavedQuery.Builder extends GeneratedMessageV3.Builder<SavedQuery.Builder> implements SavedQueryOrBuilder

A saved query which can be shared with others or used later.

Protobuf type google.cloud.asset.v1.SavedQuery

Implements

SavedQueryOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SavedQuery.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SavedQuery.Builder
Overrides

build()

public SavedQuery build()
Returns
TypeDescription
SavedQuery

buildPartial()

public SavedQuery buildPartial()
Returns
TypeDescription
SavedQuery

clear()

public SavedQuery.Builder clear()
Returns
TypeDescription
SavedQuery.Builder
Overrides

clearContent()

public SavedQuery.Builder clearContent()

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Returns
TypeDescription
SavedQuery.Builder

clearCreateTime()

public SavedQuery.Builder clearCreateTime()

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SavedQuery.Builder

clearCreator()

public SavedQuery.Builder clearCreator()

Output only. The account's email address who has created this saved query.

string creator = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

clearDescription()

public SavedQuery.Builder clearDescription()

The description of this saved query. This value should be fewer than 255 characters.

string description = 2;

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public SavedQuery.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
SavedQuery.Builder
Overrides

clearLabels()

public SavedQuery.Builder clearLabels()
Returns
TypeDescription
SavedQuery.Builder

clearLastUpdateTime()

public SavedQuery.Builder clearLastUpdateTime()

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SavedQuery.Builder

clearLastUpdater()

public SavedQuery.Builder clearLastUpdater()

Output only. The account's email address who has updated this saved query most recently.

string last_updater = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

clearName()

public SavedQuery.Builder clearName()

The resource name of the saved query. The format must be:

  • projects/project_number/savedQueries/saved_query_id
  • folders/folder_number/savedQueries/saved_query_id
  • organizations/organization_number/savedQueries/saved_query_id

string name = 1;

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public SavedQuery.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
SavedQuery.Builder
Overrides

clone()

public SavedQuery.Builder clone()
Returns
TypeDescription
SavedQuery.Builder
Overrides

containsLabels(String key)

public boolean containsLabels(String key)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getContent()

public SavedQuery.QueryContent getContent()

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Returns
TypeDescription
SavedQuery.QueryContent

The content.

getContentBuilder()

public SavedQuery.QueryContent.Builder getContentBuilder()

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Returns
TypeDescription
SavedQuery.QueryContent.Builder

getContentOrBuilder()

public SavedQuery.QueryContentOrBuilder getContentOrBuilder()

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Returns
TypeDescription
SavedQuery.QueryContentOrBuilder

getCreateTime()

public Timestamp getCreateTime()

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getCreator()

public String getCreator()

Output only. The account's email address who has created this saved query.

string creator = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The creator.

getCreatorBytes()

public ByteString getCreatorBytes()

Output only. The account's email address who has created this saved query.

string creator = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for creator.

getDefaultInstanceForType()

public SavedQuery getDefaultInstanceForType()
Returns
TypeDescription
SavedQuery

getDescription()

public String getDescription()

The description of this saved query. This value should be fewer than 255 characters.

string description = 2;

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

The description of this saved query. This value should be fewer than 255 characters.

string description = 2;

Returns
TypeDescription
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getLabels()

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
TypeDescription
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Returns
TypeDescription
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Returns
TypeDescription
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

getLastUpdateTime()

public Timestamp getLastUpdateTime()

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The lastUpdateTime.

getLastUpdateTimeBuilder()

public Timestamp.Builder getLastUpdateTimeBuilder()

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Builder

getLastUpdateTimeOrBuilder()

public TimestampOrBuilder getLastUpdateTimeOrBuilder()

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getLastUpdater()

public String getLastUpdater()

Output only. The account's email address who has updated this saved query most recently.

string last_updater = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The lastUpdater.

getLastUpdaterBytes()

public ByteString getLastUpdaterBytes()

Output only. The account's email address who has updated this saved query most recently.

string last_updater = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for lastUpdater.

getMutableLabels()

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,String>

getName()

public String getName()

The resource name of the saved query. The format must be:

  • projects/project_number/savedQueries/saved_query_id
  • folders/folder_number/savedQueries/saved_query_id
  • organizations/organization_number/savedQueries/saved_query_id

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The resource name of the saved query. The format must be:

  • projects/project_number/savedQueries/saved_query_id
  • folders/folder_number/savedQueries/saved_query_id
  • organizations/organization_number/savedQueries/saved_query_id

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

hasContent()

public boolean hasContent()

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Returns
TypeDescription
boolean

Whether the content field is set.

hasCreateTime()

public boolean hasCreateTime()

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the createTime field is set.

hasLastUpdateTime()

public boolean hasLastUpdateTime()

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the lastUpdateTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapField(int number)

protected MapField internalGetMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

internalGetMutableMapField(int number)

protected MapField internalGetMutableMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeContent(SavedQuery.QueryContent value)

public SavedQuery.Builder mergeContent(SavedQuery.QueryContent value)

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Parameter
NameDescription
valueSavedQuery.QueryContent
Returns
TypeDescription
SavedQuery.Builder

mergeCreateTime(Timestamp value)

public SavedQuery.Builder mergeCreateTime(Timestamp value)

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
SavedQuery.Builder

mergeFrom(SavedQuery other)

public SavedQuery.Builder mergeFrom(SavedQuery other)
Parameter
NameDescription
otherSavedQuery
Returns
TypeDescription
SavedQuery.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SavedQuery.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SavedQuery.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public SavedQuery.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
SavedQuery.Builder
Overrides

mergeLastUpdateTime(Timestamp value)

public SavedQuery.Builder mergeLastUpdateTime(Timestamp value)

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
SavedQuery.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SavedQuery.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SavedQuery.Builder
Overrides

putAllLabels(Map<String,String> values)

public SavedQuery.Builder putAllLabels(Map<String,String> values)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameter
NameDescription
valuesMap<String,String>
Returns
TypeDescription
SavedQuery.Builder

putLabels(String key, String value)

public SavedQuery.Builder putLabels(String key, String value)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameters
NameDescription
keyString
valueString
Returns
TypeDescription
SavedQuery.Builder

removeLabels(String key)

public SavedQuery.Builder removeLabels(String key)

Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters.

map<string, string> labels = 7;

Parameter
NameDescription
keyString
Returns
TypeDescription
SavedQuery.Builder

setContent(SavedQuery.QueryContent value)

public SavedQuery.Builder setContent(SavedQuery.QueryContent value)

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Parameter
NameDescription
valueSavedQuery.QueryContent
Returns
TypeDescription
SavedQuery.Builder

setContent(SavedQuery.QueryContent.Builder builderForValue)

public SavedQuery.Builder setContent(SavedQuery.QueryContent.Builder builderForValue)

The query content.

.google.cloud.asset.v1.SavedQuery.QueryContent content = 8;

Parameter
NameDescription
builderForValueSavedQuery.QueryContent.Builder
Returns
TypeDescription
SavedQuery.Builder

setCreateTime(Timestamp value)

public SavedQuery.Builder setCreateTime(Timestamp value)

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
SavedQuery.Builder

setCreateTime(Timestamp.Builder builderForValue)

public SavedQuery.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. The create time of this saved query.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
SavedQuery.Builder

setCreator(String value)

public SavedQuery.Builder setCreator(String value)

Output only. The account's email address who has created this saved query.

string creator = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueString

The creator to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setCreatorBytes(ByteString value)

public SavedQuery.Builder setCreatorBytes(ByteString value)

Output only. The account's email address who has created this saved query.

string creator = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueByteString

The bytes for creator to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setDescription(String value)

public SavedQuery.Builder setDescription(String value)

The description of this saved query. This value should be fewer than 255 characters.

string description = 2;

Parameter
NameDescription
valueString

The description to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public SavedQuery.Builder setDescriptionBytes(ByteString value)

The description of this saved query. This value should be fewer than 255 characters.

string description = 2;

Parameter
NameDescription
valueByteString

The bytes for description to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public SavedQuery.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SavedQuery.Builder
Overrides

setLastUpdateTime(Timestamp value)

public SavedQuery.Builder setLastUpdateTime(Timestamp value)

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueTimestamp
Returns
TypeDescription
SavedQuery.Builder

setLastUpdateTime(Timestamp.Builder builderForValue)

public SavedQuery.Builder setLastUpdateTime(Timestamp.Builder builderForValue)

Output only. The last update time of this saved query.

.google.protobuf.Timestamp last_update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
SavedQuery.Builder

setLastUpdater(String value)

public SavedQuery.Builder setLastUpdater(String value)

Output only. The account's email address who has updated this saved query most recently.

string last_updater = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueString

The lastUpdater to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setLastUpdaterBytes(ByteString value)

public SavedQuery.Builder setLastUpdaterBytes(ByteString value)

Output only. The account's email address who has updated this saved query most recently.

string last_updater = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
NameDescription
valueByteString

The bytes for lastUpdater to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setName(String value)

public SavedQuery.Builder setName(String value)

The resource name of the saved query. The format must be:

  • projects/project_number/savedQueries/saved_query_id
  • folders/folder_number/savedQueries/saved_query_id
  • organizations/organization_number/savedQueries/saved_query_id

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setNameBytes(ByteString value)

public SavedQuery.Builder setNameBytes(ByteString value)

The resource name of the saved query. The format must be:

  • projects/project_number/savedQueries/saved_query_id
  • folders/folder_number/savedQueries/saved_query_id
  • organizations/organization_number/savedQueries/saved_query_id

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
SavedQuery.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public SavedQuery.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
SavedQuery.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SavedQuery.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SavedQuery.Builder
Overrides