Class SessionInfo.Builder (0.14.5)

public static final class SessionInfo.Builder extends GeneratedMessageV3.Builder<SessionInfo.Builder> implements SessionInfoOrBuilder

Represents session information communicated to and from the webhook.

Protobuf type google.cloud.dialogflow.cx.v3.SessionInfo

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public SessionInfo build()
Returns
TypeDescription
SessionInfo

buildPartial()

public SessionInfo buildPartial()
Returns
TypeDescription
SessionInfo

clear()

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

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearParameters()

public SessionInfo.Builder clearParameters()
Returns
TypeDescription
SessionInfo.Builder

clearSession()

public SessionInfo.Builder clearSession()

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID> or projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID> if environment is specified.

string session = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
SessionInfo.Builder

This builder for chaining.

clone()

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

containsParameters(String key)

public boolean containsParameters(String key)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getDefaultInstanceForType()

public SessionInfo getDefaultInstanceForType()
Returns
TypeDescription
SessionInfo

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getMutableParameters()

public Map<String,Value> getMutableParameters()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,Value>

getParameters()

public Map<String,Value> getParameters()

Use #getParametersMap() instead.

Returns
TypeDescription
Map<String,Value>

getParametersCount()

public int getParametersCount()

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Returns
TypeDescription
int

getParametersMap()

public Map<String,Value> getParametersMap()

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Returns
TypeDescription
Map<String,Value>

getParametersOrDefault(String key, Value defaultValue)

public Value getParametersOrDefault(String key, Value defaultValue)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameters
NameDescription
keyString
defaultValueValue
Returns
TypeDescription
Value

getParametersOrThrow(String key)

public Value getParametersOrThrow(String key)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
Value

getSession()

public String getSession()

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID> or projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID> if environment is specified.

string session = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The session.

getSessionBytes()

public ByteString getSessionBytes()

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID> or projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID> if environment is specified.

string session = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for session.

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

mergeFrom(SessionInfo other)

public SessionInfo.Builder mergeFrom(SessionInfo other)
Parameter
NameDescription
otherSessionInfo
Returns
TypeDescription
SessionInfo.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

putAllParameters(Map<String,Value> values)

public SessionInfo.Builder putAllParameters(Map<String,Value> values)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameter
NameDescription
valuesMap<String,Value>
Returns
TypeDescription
SessionInfo.Builder

putParameters(String key, Value value)

public SessionInfo.Builder putParameters(String key, Value value)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameters
NameDescription
keyString
valueValue
Returns
TypeDescription
SessionInfo.Builder

removeParameters(String key)

public SessionInfo.Builder removeParameters(String key)

Optional for WebhookRequest. Optional for WebhookResponse. All parameters collected from forms and intents during the session. Parameters can be created, updated, or removed by the webhook. To remove a parameter from the session, the webhook should explicitly set the parameter value to null in WebhookResponse. The map is keyed by parameters' display names.

map<string, .google.protobuf.Value> parameters = 2;

Parameter
NameDescription
keyString
Returns
TypeDescription
SessionInfo.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setSession(String value)

public SessionInfo.Builder setSession(String value)

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID> or projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID> if environment is specified.

string session = 1 [(.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueString

The session to set.

Returns
TypeDescription
SessionInfo.Builder

This builder for chaining.

setSessionBytes(ByteString value)

public SessionInfo.Builder setSessionBytes(ByteString value)

Always present for WebhookRequest. Ignored for WebhookResponse. The unique identifier of the session. This field can be used by the webhook to identify a session. Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/sessions/<Session ID> or projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID>/sessions/<Session ID> if environment is specified.

string session = 1 [(.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueByteString

The bytes for session to set.

Returns
TypeDescription
SessionInfo.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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