Class MessageAnnotation.Builder (4.9.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.v2beta1.MessageAnnotation

Static Methods

getDescriptor()

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

Methods

addAllParts(Iterable<? extends AnnotatedMessagePart> values)

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

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
values Iterable<? extends com.google.cloud.dialogflow.v2beta1.AnnotatedMessagePart>
Returns
Type Description
MessageAnnotation.Builder

addParts(AnnotatedMessagePart value)

public MessageAnnotation.Builder addParts(AnnotatedMessagePart value)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
value AnnotatedMessagePart
Returns
Type Description
MessageAnnotation.Builder

addParts(AnnotatedMessagePart.Builder builderForValue)

public MessageAnnotation.Builder addParts(AnnotatedMessagePart.Builder builderForValue)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
builderForValue AnnotatedMessagePart.Builder
Returns
Type Description
MessageAnnotation.Builder

addParts(int index, AnnotatedMessagePart value)

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

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameters
Name Description
index int
value AnnotatedMessagePart
Returns
Type Description
MessageAnnotation.Builder

addParts(int index, AnnotatedMessagePart.Builder builderForValue)

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

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameters
Name Description
index int
builderForValue AnnotatedMessagePart.Builder
Returns
Type Description
MessageAnnotation.Builder

addPartsBuilder()

public AnnotatedMessagePart.Builder addPartsBuilder()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
AnnotatedMessagePart.Builder

addPartsBuilder(int index)

public AnnotatedMessagePart.Builder addPartsBuilder(int index)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
index int
Returns
Type Description
AnnotatedMessagePart.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public MessageAnnotation build()
Returns
Type Description
MessageAnnotation

buildPartial()

public MessageAnnotation buildPartial()
Returns
Type Description
MessageAnnotation

clear()

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

clearContainEntities()

public MessageAnnotation.Builder clearContainEntities()

Required. Indicates whether the text message contains entities.

bool contain_entities = 2;

Returns
Type Description
MessageAnnotation.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearParts()

public MessageAnnotation.Builder clearParts()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
MessageAnnotation.Builder

clone()

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

getContainEntities()

public boolean getContainEntities()

Required. Indicates whether the text message contains entities.

bool contain_entities = 2;

Returns
Type Description
boolean

The containEntities.

getDefaultInstanceForType()

public MessageAnnotation getDefaultInstanceForType()
Returns
Type Description
MessageAnnotation

getDescriptorForType()

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

getParts(int index)

public AnnotatedMessagePart getParts(int index)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
index int
Returns
Type Description
AnnotatedMessagePart

getPartsBuilder(int index)

public AnnotatedMessagePart.Builder getPartsBuilder(int index)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
index int
Returns
Type Description
AnnotatedMessagePart.Builder

getPartsBuilderList()

public List<AnnotatedMessagePart.Builder> getPartsBuilderList()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
List<Builder>

getPartsCount()

public int getPartsCount()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
int

getPartsList()

public List<AnnotatedMessagePart> getPartsList()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
List<AnnotatedMessagePart>

getPartsOrBuilder(int index)

public AnnotatedMessagePartOrBuilder getPartsOrBuilder(int index)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
index int
Returns
Type Description
AnnotatedMessagePartOrBuilder

getPartsOrBuilderList()

public List<? extends AnnotatedMessagePartOrBuilder> getPartsOrBuilderList()

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Returns
Type Description
List<? extends com.google.cloud.dialogflow.v2beta1.AnnotatedMessagePartOrBuilder>

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(MessageAnnotation other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeParts(int index)

public MessageAnnotation.Builder removeParts(int index)

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameter
Name Description
index int
Returns
Type Description
MessageAnnotation.Builder

setContainEntities(boolean value)

public MessageAnnotation.Builder setContainEntities(boolean value)

Required. Indicates whether the text message contains entities.

bool contain_entities = 2;

Parameter
Name Description
value boolean

The containEntities to set.

Returns
Type Description
MessageAnnotation.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setParts(int index, AnnotatedMessagePart value)

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

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameters
Name Description
index int
value AnnotatedMessagePart
Returns
Type Description
MessageAnnotation.Builder

setParts(int index, AnnotatedMessagePart.Builder builderForValue)

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

Optional. 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.v2beta1.AnnotatedMessagePart parts = 1;

Parameters
Name Description
index int
builderForValue AnnotatedMessagePart.Builder
Returns
Type Description
MessageAnnotation.Builder

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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