Class SessionEvent.Builder (3.64.0)

public static final class SessionEvent.Builder extends GeneratedMessageV3.Builder.Builder> implements SessionEventOrBuilder

An event represents a message from either the user or agent.

Protobuf type google.cloud.aiplatform.v1beta1.SessionEvent

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public SessionEvent build()
Returns
Type Description
SessionEvent

buildPartial()

public SessionEvent buildPartial()
Returns
Type Description
SessionEvent

clear()

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

clearActions()

public SessionEvent.Builder clearActions()

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
SessionEvent.Builder

clearAuthor()

public SessionEvent.Builder clearAuthor()

Required. The name of the agent that sent the event, or user.

string author = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

clearContent()

public SessionEvent.Builder clearContent()

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
SessionEvent.Builder

clearErrorCode()

public SessionEvent.Builder clearErrorCode()

Optional. Error code if the response is an error. Code varies by model.

string error_code = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

clearErrorMessage()

public SessionEvent.Builder clearErrorMessage()

Optional. Error message if the response is an error.

string error_message = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

clearEventMetadata()

public SessionEvent.Builder clearEventMetadata()

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
SessionEvent.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearInvocationId()

public SessionEvent.Builder clearInvocationId()

Required. The invocation id of the event, multiple events can have the same invocation id.

string invocation_id = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

clearName()

public SessionEvent.Builder clearName()

Required. Identifier. The resource name of the event. Format:projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}/events/{event}.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearTimestamp()

public SessionEvent.Builder clearTimestamp()

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
SessionEvent.Builder

clone()

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

getActions()

public EventActions getActions()

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventActions

The actions.

getActionsBuilder()

public EventActions.Builder getActionsBuilder()

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventActions.Builder

getActionsOrBuilder()

public EventActionsOrBuilder getActionsOrBuilder()

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventActionsOrBuilder

getAuthor()

public String getAuthor()

Required. The name of the agent that sent the event, or user.

string author = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The author.

getAuthorBytes()

public ByteString getAuthorBytes()

Required. The name of the agent that sent the event, or user.

string author = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for author.

getContent()

public Content getContent()

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Content

The content.

getContentBuilder()

public Content.Builder getContentBuilder()

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Content.Builder

getContentOrBuilder()

public ContentOrBuilder getContentOrBuilder()

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ContentOrBuilder

getDefaultInstanceForType()

public SessionEvent getDefaultInstanceForType()
Returns
Type Description
SessionEvent

getDescriptorForType()

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

getErrorCode()

public String getErrorCode()

Optional. Error code if the response is an error. Code varies by model.

string error_code = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The errorCode.

getErrorCodeBytes()

public ByteString getErrorCodeBytes()

Optional. Error code if the response is an error. Code varies by model.

string error_code = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for errorCode.

getErrorMessage()

public String getErrorMessage()

Optional. Error message if the response is an error.

string error_message = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The errorMessage.

getErrorMessageBytes()

public ByteString getErrorMessageBytes()

Optional. Error message if the response is an error.

string error_message = 10 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for errorMessage.

getEventMetadata()

public EventMetadata getEventMetadata()

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventMetadata

The eventMetadata.

getEventMetadataBuilder()

public EventMetadata.Builder getEventMetadataBuilder()

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventMetadata.Builder

getEventMetadataOrBuilder()

public EventMetadataOrBuilder getEventMetadataOrBuilder()

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
EventMetadataOrBuilder

getInvocationId()

public String getInvocationId()

Required. The invocation id of the event, multiple events can have the same invocation id.

string invocation_id = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The invocationId.

getInvocationIdBytes()

public ByteString getInvocationIdBytes()

Required. The invocation id of the event, multiple events can have the same invocation id.

string invocation_id = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for invocationId.

getName()

public String getName()

Required. Identifier. The resource name of the event. Format:projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}/events/{event}.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Required. Identifier. The resource name of the event. Format:projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}/events/{event}.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER];

Returns
Type Description
ByteString

The bytes for name.

getTimestamp()

public Timestamp getTimestamp()

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Timestamp

The timestamp.

getTimestampBuilder()

public Timestamp.Builder getTimestampBuilder()

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Builder

getTimestampOrBuilder()

public TimestampOrBuilder getTimestampOrBuilder()

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
TimestampOrBuilder

hasActions()

public boolean hasActions()

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the actions field is set.

hasContent()

public boolean hasContent()

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the content field is set.

hasEventMetadata()

public boolean hasEventMetadata()

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the eventMetadata field is set.

hasTimestamp()

public boolean hasTimestamp()

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
boolean

Whether the timestamp field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeActions(EventActions value)

public SessionEvent.Builder mergeActions(EventActions value)

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value EventActions
Returns
Type Description
SessionEvent.Builder

mergeContent(Content value)

public SessionEvent.Builder mergeContent(Content value)

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Content
Returns
Type Description
SessionEvent.Builder

mergeEventMetadata(EventMetadata value)

public SessionEvent.Builder mergeEventMetadata(EventMetadata value)

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value EventMetadata
Returns
Type Description
SessionEvent.Builder

mergeFrom(SessionEvent other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeTimestamp(Timestamp value)

public SessionEvent.Builder mergeTimestamp(Timestamp value)

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value Timestamp
Returns
Type Description
SessionEvent.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setActions(EventActions value)

public SessionEvent.Builder setActions(EventActions value)

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value EventActions
Returns
Type Description
SessionEvent.Builder

setActions(EventActions.Builder builderForValue)

public SessionEvent.Builder setActions(EventActions.Builder builderForValue)

Optional. Actions executed by the agent.

.google.cloud.aiplatform.v1beta1.EventActions actions = 6 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue EventActions.Builder
Returns
Type Description
SessionEvent.Builder

setAuthor(String value)

public SessionEvent.Builder setAuthor(String value)

Required. The name of the agent that sent the event, or user.

string author = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The author to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setAuthorBytes(ByteString value)

public SessionEvent.Builder setAuthorBytes(ByteString value)

Required. The name of the agent that sent the event, or user.

string author = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for author to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setContent(Content value)

public SessionEvent.Builder setContent(Content value)

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Content
Returns
Type Description
SessionEvent.Builder

setContent(Content.Builder builderForValue)

public SessionEvent.Builder setContent(Content.Builder builderForValue)

Optional. Content of the event provided by the author.

.google.cloud.aiplatform.v1beta1.Content content = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Content.Builder
Returns
Type Description
SessionEvent.Builder

setErrorCode(String value)

public SessionEvent.Builder setErrorCode(String value)

Optional. Error code if the response is an error. Code varies by model.

string error_code = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The errorCode to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setErrorCodeBytes(ByteString value)

public SessionEvent.Builder setErrorCodeBytes(ByteString value)

Optional. Error code if the response is an error. Code varies by model.

string error_code = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for errorCode to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setErrorMessage(String value)

public SessionEvent.Builder setErrorMessage(String value)

Optional. Error message if the response is an error.

string error_message = 10 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The errorMessage to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setErrorMessageBytes(ByteString value)

public SessionEvent.Builder setErrorMessageBytes(ByteString value)

Optional. Error message if the response is an error.

string error_message = 10 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for errorMessage to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setEventMetadata(EventMetadata value)

public SessionEvent.Builder setEventMetadata(EventMetadata value)

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value EventMetadata
Returns
Type Description
SessionEvent.Builder

setEventMetadata(EventMetadata.Builder builderForValue)

public SessionEvent.Builder setEventMetadata(EventMetadata.Builder builderForValue)

Optional. Metadata relating to this event.

.google.cloud.aiplatform.v1beta1.EventMetadata event_metadata = 11 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue EventMetadata.Builder
Returns
Type Description
SessionEvent.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setInvocationId(String value)

public SessionEvent.Builder setInvocationId(String value)

Required. The invocation id of the event, multiple events can have the same invocation id.

string invocation_id = 5 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The invocationId to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setInvocationIdBytes(ByteString value)

public SessionEvent.Builder setInvocationIdBytes(ByteString value)

Required. The invocation id of the event, multiple events can have the same invocation id.

string invocation_id = 5 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for invocationId to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setName(String value)

public SessionEvent.Builder setName(String value)

Required. Identifier. The resource name of the event. Format:projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}/events/{event}.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

setNameBytes(ByteString value)

public SessionEvent.Builder setNameBytes(ByteString value)

Required. Identifier. The resource name of the event. Format:projects/{project}/locations/{location}/reasoningEngines/{reasoning_engine}/sessions/{session}/events/{event}.

string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IDENTIFIER];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
SessionEvent.Builder

This builder for chaining.

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

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

setTimestamp(Timestamp value)

public SessionEvent.Builder setTimestamp(Timestamp value)

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value Timestamp
Returns
Type Description
SessionEvent.Builder

setTimestamp(Timestamp.Builder builderForValue)

public SessionEvent.Builder setTimestamp(Timestamp.Builder builderForValue)

Required. Timestamp when the event was created on client side.

.google.protobuf.Timestamp timestamp = 8 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
SessionEvent.Builder

setUnknownFields(UnknownFieldSet unknownFields)

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