Class GroundingFact.Builder (0.42.0)

public static final class GroundingFact.Builder extends GeneratedMessageV3.Builder<GroundingFact.Builder> implements GroundingFactOrBuilder

Grounding Fact.

Protobuf type google.cloud.discoveryengine.v1beta.GroundingFact

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public GroundingFact.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
GroundingFact.Builder
Overrides

build()

public GroundingFact build()
Returns
Type Description
GroundingFact

buildPartial()

public GroundingFact buildPartial()
Returns
Type Description
GroundingFact

clear()

public GroundingFact.Builder clear()
Returns
Type Description
GroundingFact.Builder
Overrides

clearAttributes()

public GroundingFact.Builder clearAttributes()
Returns
Type Description
GroundingFact.Builder

clearFactText()

public GroundingFact.Builder clearFactText()

Text content of the fact. Can be at most 10K characters long.

string fact_text = 1;

Returns
Type Description
GroundingFact.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public GroundingFact.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
GroundingFact.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public GroundingFact.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
GroundingFact.Builder
Overrides

clone()

public GroundingFact.Builder clone()
Returns
Type Description
GroundingFact.Builder
Overrides

containsAttributes(String key)

public boolean containsAttributes(String key)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameter
Name Description
key String
Returns
Type Description
boolean

getAttributes() (deprecated)

public Map<String,String> getAttributes()

Use #getAttributesMap() instead.

Returns
Type Description
Map<String,String>

getAttributesCount()

public int getAttributesCount()

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Returns
Type Description
int

getAttributesMap()

public Map<String,String> getAttributesMap()

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Returns
Type Description
Map<String,String>

getAttributesOrDefault(String key, String defaultValue)

public String getAttributesOrDefault(String key, String defaultValue)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getAttributesOrThrow(String key)

public String getAttributesOrThrow(String key)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameter
Name Description
key String
Returns
Type Description
String

getDefaultInstanceForType()

public GroundingFact getDefaultInstanceForType()
Returns
Type Description
GroundingFact

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getFactText()

public String getFactText()

Text content of the fact. Can be at most 10K characters long.

string fact_text = 1;

Returns
Type Description
String

The factText.

getFactTextBytes()

public ByteString getFactTextBytes()

Text content of the fact. Can be at most 10K characters long.

string fact_text = 1;

Returns
Type Description
ByteString

The bytes for factText.

getMutableAttributes() (deprecated)

public Map<String,String> getMutableAttributes()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(GroundingFact other)

public GroundingFact.Builder mergeFrom(GroundingFact other)
Parameter
Name Description
other GroundingFact
Returns
Type Description
GroundingFact.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public GroundingFact.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
GroundingFact.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public GroundingFact.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
GroundingFact.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final GroundingFact.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
GroundingFact.Builder
Overrides

putAllAttributes(Map<String,String> values)

public GroundingFact.Builder putAllAttributes(Map<String,String> values)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameter
Name Description
values Map<String,String>
Returns
Type Description
GroundingFact.Builder

putAttributes(String key, String value)

public GroundingFact.Builder putAttributes(String key, String value)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameters
Name Description
key String
value String
Returns
Type Description
GroundingFact.Builder

removeAttributes(String key)

public GroundingFact.Builder removeAttributes(String key)

Attributes associated with the fact. Common attributes include source (indicating where the fact was sourced from), author (indicating the author of the fact), and so on.

map<string, string> attributes = 2;

Parameter
Name Description
key String
Returns
Type Description
GroundingFact.Builder

setFactText(String value)

public GroundingFact.Builder setFactText(String value)

Text content of the fact. Can be at most 10K characters long.

string fact_text = 1;

Parameter
Name Description
value String

The factText to set.

Returns
Type Description
GroundingFact.Builder

This builder for chaining.

setFactTextBytes(ByteString value)

public GroundingFact.Builder setFactTextBytes(ByteString value)

Text content of the fact. Can be at most 10K characters long.

string fact_text = 1;

Parameter
Name Description
value ByteString

The bytes for factText to set.

Returns
Type Description
GroundingFact.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public GroundingFact.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
GroundingFact.Builder
Overrides

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

public GroundingFact.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
GroundingFact.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final GroundingFact.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
GroundingFact.Builder
Overrides