Class MessageAnnotation.Builder (4.3.1)

public static final class MessageAnnotation.Builder extends GeneratedMessageV3.Builder<MessageAnnotation.Builder> implements MessageAnnotationOrBuilder

Represents the result of annotation for the message.

Protobuf type google.cloud.dialogflow.v2.MessageAnnotation

Methods

addAllParts(Iterable<? extends AnnotatedMessagePart> values)

public MessageAnnotation.Builder addAllParts(Iterable<? extends AnnotatedMessagePart> values)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.dialogflow.v2.AnnotatedMessagePart>
Returns

addParts(AnnotatedMessagePart value)

public MessageAnnotation.Builder addParts(AnnotatedMessagePart value)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
valueAnnotatedMessagePart
Returns

addParts(AnnotatedMessagePart.Builder builderForValue)

public MessageAnnotation.Builder addParts(AnnotatedMessagePart.Builder builderForValue)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
builderForValueAnnotatedMessagePart.Builder
Returns

addParts(int index, AnnotatedMessagePart value)

public MessageAnnotation.Builder addParts(int index, AnnotatedMessagePart value)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameters
NameDescription
indexint
valueAnnotatedMessagePart
Returns

addParts(int index, AnnotatedMessagePart.Builder builderForValue)

public MessageAnnotation.Builder addParts(int index, AnnotatedMessagePart.Builder builderForValue)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameters
NameDescription
indexint
builderForValueAnnotatedMessagePart.Builder
Returns

addPartsBuilder()

public AnnotatedMessagePart.Builder addPartsBuilder()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns

addPartsBuilder(int index)

public AnnotatedMessagePart.Builder addPartsBuilder(int index)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
indexint
Returns

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public MessageAnnotation build()
Returns
TypeDescription
MessageAnnotation

buildPartial()

public MessageAnnotation buildPartial()
Returns
TypeDescription
MessageAnnotation

clear()

public MessageAnnotation.Builder clear()
Returns Overrides

clearContainEntities()

public MessageAnnotation.Builder clearContainEntities()

Indicates whether the text message contains entities.

bool contain_entities = 2;

Returns
TypeDescription
MessageAnnotation.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearParts()

public MessageAnnotation.Builder clearParts()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns

clone()

public MessageAnnotation.Builder clone()
Returns Overrides

getContainEntities()

public boolean getContainEntities()

Indicates whether the text message contains entities.

bool contain_entities = 2;

Returns
TypeDescription
boolean

The containEntities.

getDefaultInstanceForType()

public MessageAnnotation getDefaultInstanceForType()
Returns
TypeDescription
MessageAnnotation

getDescriptor()

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

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getParts(int index)

public AnnotatedMessagePart getParts(int index)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
AnnotatedMessagePart

getPartsBuilder(int index)

public AnnotatedMessagePart.Builder getPartsBuilder(int index)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
indexint
Returns

getPartsBuilderList()

public List<AnnotatedMessagePart.Builder> getPartsBuilderList()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns
TypeDescription
List<Builder>

getPartsCount()

public int getPartsCount()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns
TypeDescription
int

getPartsList()

public List<AnnotatedMessagePart> getPartsList()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns
TypeDescription
List<AnnotatedMessagePart>

getPartsOrBuilder(int index)

public AnnotatedMessagePartOrBuilder getPartsOrBuilder(int index)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
indexint
Returns

getPartsOrBuilderList()

public List<? extends AnnotatedMessagePartOrBuilder> getPartsOrBuilderList()

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Returns
TypeDescription
List<? extends com.google.cloud.dialogflow.v2.AnnotatedMessagePartOrBuilder>

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(MessageAnnotation other)

public MessageAnnotation.Builder mergeFrom(MessageAnnotation other)
Parameter
NameDescription
otherMessageAnnotation
Returns

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeParts(int index)

public MessageAnnotation.Builder removeParts(int index)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameter
NameDescription
indexint
Returns

setContainEntities(boolean value)

public MessageAnnotation.Builder setContainEntities(boolean value)

Indicates whether the text message contains entities.

bool contain_entities = 2;

Parameter
NameDescription
valueboolean

The containEntities to set.

Returns
TypeDescription
MessageAnnotation.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setParts(int index, AnnotatedMessagePart value)

public MessageAnnotation.Builder setParts(int index, AnnotatedMessagePart value)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameters
NameDescription
indexint
valueAnnotatedMessagePart
Returns

setParts(int index, AnnotatedMessagePart.Builder builderForValue)

public MessageAnnotation.Builder setParts(int index, AnnotatedMessagePart.Builder builderForValue)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

repeated .google.cloud.dialogflow.v2.AnnotatedMessagePart parts = 1;

Parameters
NameDescription
indexint
builderForValueAnnotatedMessagePart.Builder
Returns

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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