public final class Example extends com.google.protobuf.GeneratedMessageV3 implements ExampleOrBuilder
Example represents a sample execution of the playbook in the conversation. An example consists of a list of ordered actions performed by end user or Dialogflow agent according the playbook instructions to fulfill the task.Protobuf type
google.cloud.dialogflow.cx.v3beta1.Example| Modifier and Type | Class and Description |
|---|---|
static class |
Example.Builder
Example represents a sample execution of the playbook in the conversation.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
ACTIONS_FIELD_NUMBER |
static int |
CONVERSATION_STATE_FIELD_NUMBER |
static int |
CREATE_TIME_FIELD_NUMBER |
static int |
DESCRIPTION_FIELD_NUMBER |
static int |
DISPLAY_NAME_FIELD_NUMBER |
static int |
LANGUAGE_CODE_FIELD_NUMBER |
static int |
NAME_FIELD_NUMBER |
static int |
PLAYBOOK_INPUT_FIELD_NUMBER |
static int |
PLAYBOOK_OUTPUT_FIELD_NUMBER |
static int |
TOKEN_COUNT_FIELD_NUMBER |
static int |
UPDATE_TIME_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
Action |
getActions(int index)
Required.
|
int |
getActionsCount()
Required.
|
List<Action> |
getActionsList()
Required.
|
ActionOrBuilder |
getActionsOrBuilder(int index)
Required.
|
List<? extends ActionOrBuilder> |
getActionsOrBuilderList()
Required.
|
OutputState |
getConversationState()
Required.
|
int |
getConversationStateValue()
Required.
|
com.google.protobuf.Timestamp |
getCreateTime()
Output only.
|
com.google.protobuf.TimestampOrBuilder |
getCreateTimeOrBuilder()
Output only.
|
static Example |
getDefaultInstance() |
Example |
getDefaultInstanceForType() |
String |
getDescription()
Optional.
|
com.google.protobuf.ByteString |
getDescriptionBytes()
Optional.
|
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
String |
getDisplayName()
Required.
|
com.google.protobuf.ByteString |
getDisplayNameBytes()
Required.
|
String |
getLanguageCode()
Optional.
|
com.google.protobuf.ByteString |
getLanguageCodeBytes()
Optional.
|
String |
getName()
The unique identifier of the playbook example.
|
com.google.protobuf.ByteString |
getNameBytes()
The unique identifier of the playbook example.
|
com.google.protobuf.Parser<Example> |
getParserForType() |
PlaybookInput |
getPlaybookInput()
Optional.
|
PlaybookInputOrBuilder |
getPlaybookInputOrBuilder()
Optional.
|
PlaybookOutput |
getPlaybookOutput()
Optional.
|
PlaybookOutputOrBuilder |
getPlaybookOutputOrBuilder()
Optional.
|
int |
getSerializedSize() |
long |
getTokenCount()
Output only.
|
com.google.protobuf.Timestamp |
getUpdateTime()
Output only.
|
com.google.protobuf.TimestampOrBuilder |
getUpdateTimeOrBuilder()
Output only.
|
boolean |
hasCreateTime()
Output only.
|
int |
hashCode() |
boolean |
hasPlaybookInput()
Optional.
|
boolean |
hasPlaybookOutput()
Optional.
|
boolean |
hasUpdateTime()
Output only.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static Example.Builder |
newBuilder() |
static Example.Builder |
newBuilder(Example prototype) |
Example.Builder |
newBuilderForType() |
protected Example.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static Example |
parseDelimitedFrom(InputStream input) |
static Example |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Example |
parseFrom(byte[] data) |
static Example |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Example |
parseFrom(ByteBuffer data) |
static Example |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Example |
parseFrom(com.google.protobuf.ByteString data) |
static Example |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Example |
parseFrom(com.google.protobuf.CodedInputStream input) |
static Example |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Example |
parseFrom(InputStream input) |
static Example |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<Example> |
parser() |
Example.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int NAME_FIELD_NUMBER
public static final int PLAYBOOK_INPUT_FIELD_NUMBER
public static final int PLAYBOOK_OUTPUT_FIELD_NUMBER
public static final int ACTIONS_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
public static final int DESCRIPTION_FIELD_NUMBER
public static final int TOKEN_COUNT_FIELD_NUMBER
public static final int CREATE_TIME_FIELD_NUMBER
public static final int UPDATE_TIME_FIELD_NUMBER
public static final int CONVERSATION_STATE_FIELD_NUMBER
public static final int LANGUAGE_CODE_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public String getName()
The unique identifier of the playbook example. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/playbooks/<PlaybookID>/examples/<ExampleID>`.
string name = 1;getName in interface ExampleOrBuilderpublic com.google.protobuf.ByteString getNameBytes()
The unique identifier of the playbook example. Format: `projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/playbooks/<PlaybookID>/examples/<ExampleID>`.
string name = 1;getNameBytes in interface ExampleOrBuilderpublic boolean hasPlaybookInput()
Optional. The input to the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookInput playbook_input = 3 [(.google.api.field_behavior) = OPTIONAL];
hasPlaybookInput in interface ExampleOrBuilderpublic PlaybookInput getPlaybookInput()
Optional. The input to the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookInput playbook_input = 3 [(.google.api.field_behavior) = OPTIONAL];
getPlaybookInput in interface ExampleOrBuilderpublic PlaybookInputOrBuilder getPlaybookInputOrBuilder()
Optional. The input to the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookInput playbook_input = 3 [(.google.api.field_behavior) = OPTIONAL];
getPlaybookInputOrBuilder in interface ExampleOrBuilderpublic boolean hasPlaybookOutput()
Optional. The output of the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookOutput playbook_output = 4 [(.google.api.field_behavior) = OPTIONAL];
hasPlaybookOutput in interface ExampleOrBuilderpublic PlaybookOutput getPlaybookOutput()
Optional. The output of the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookOutput playbook_output = 4 [(.google.api.field_behavior) = OPTIONAL];
getPlaybookOutput in interface ExampleOrBuilderpublic PlaybookOutputOrBuilder getPlaybookOutputOrBuilder()
Optional. The output of the playbook in the example.
.google.cloud.dialogflow.cx.v3beta1.PlaybookOutput playbook_output = 4 [(.google.api.field_behavior) = OPTIONAL];
getPlaybookOutputOrBuilder in interface ExampleOrBuilderpublic List<Action> getActionsList()
Required. The ordered list of actions performed by the end user and the Dialogflow agent.
repeated .google.cloud.dialogflow.cx.v3beta1.Action actions = 2 [(.google.api.field_behavior) = REQUIRED];
getActionsList in interface ExampleOrBuilderpublic List<? extends ActionOrBuilder> getActionsOrBuilderList()
Required. The ordered list of actions performed by the end user and the Dialogflow agent.
repeated .google.cloud.dialogflow.cx.v3beta1.Action actions = 2 [(.google.api.field_behavior) = REQUIRED];
getActionsOrBuilderList in interface ExampleOrBuilderpublic int getActionsCount()
Required. The ordered list of actions performed by the end user and the Dialogflow agent.
repeated .google.cloud.dialogflow.cx.v3beta1.Action actions = 2 [(.google.api.field_behavior) = REQUIRED];
getActionsCount in interface ExampleOrBuilderpublic Action getActions(int index)
Required. The ordered list of actions performed by the end user and the Dialogflow agent.
repeated .google.cloud.dialogflow.cx.v3beta1.Action actions = 2 [(.google.api.field_behavior) = REQUIRED];
getActions in interface ExampleOrBuilderpublic ActionOrBuilder getActionsOrBuilder(int index)
Required. The ordered list of actions performed by the end user and the Dialogflow agent.
repeated .google.cloud.dialogflow.cx.v3beta1.Action actions = 2 [(.google.api.field_behavior) = REQUIRED];
getActionsOrBuilder in interface ExampleOrBuilderpublic String getDisplayName()
Required. The display name of the example.
string display_name = 6 [(.google.api.field_behavior) = REQUIRED];getDisplayName in interface ExampleOrBuilderpublic com.google.protobuf.ByteString getDisplayNameBytes()
Required. The display name of the example.
string display_name = 6 [(.google.api.field_behavior) = REQUIRED];getDisplayNameBytes in interface ExampleOrBuilderpublic String getDescription()
Optional. The high level concise description of the example. The max number of characters is 200.
string description = 8 [(.google.api.field_behavior) = OPTIONAL];getDescription in interface ExampleOrBuilderpublic com.google.protobuf.ByteString getDescriptionBytes()
Optional. The high level concise description of the example. The max number of characters is 200.
string description = 8 [(.google.api.field_behavior) = OPTIONAL];getDescriptionBytes in interface ExampleOrBuilderpublic long getTokenCount()
Output only. Estimated number of tokes current example takes when sent to the LLM.
int64 token_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];getTokenCount in interface ExampleOrBuilderpublic boolean hasCreateTime()
Output only. The timestamp of initial example creation.
.google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasCreateTime in interface ExampleOrBuilderpublic com.google.protobuf.Timestamp getCreateTime()
Output only. The timestamp of initial example creation.
.google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCreateTime in interface ExampleOrBuilderpublic com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The timestamp of initial example creation.
.google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCreateTimeOrBuilder in interface ExampleOrBuilderpublic boolean hasUpdateTime()
Output only. Last time the example was updated.
.google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasUpdateTime in interface ExampleOrBuilderpublic com.google.protobuf.Timestamp getUpdateTime()
Output only. Last time the example was updated.
.google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
getUpdateTime in interface ExampleOrBuilderpublic com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. Last time the example was updated.
.google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
getUpdateTimeOrBuilder in interface ExampleOrBuilderpublic int getConversationStateValue()
Required. Example's output state.
.google.cloud.dialogflow.cx.v3beta1.OutputState conversation_state = 12 [(.google.api.field_behavior) = REQUIRED];
getConversationStateValue in interface ExampleOrBuilderpublic OutputState getConversationState()
Required. Example's output state.
.google.cloud.dialogflow.cx.v3beta1.OutputState conversation_state = 12 [(.google.api.field_behavior) = REQUIRED];
getConversationState in interface ExampleOrBuilderpublic String getLanguageCode()
Optional. The language code of the example. If not specified, the agent's default language is used. Note: languages must be enabled in the agent before they can be used. Note: example's language code is not currently used in dialogflow agents.
string language_code = 13 [(.google.api.field_behavior) = OPTIONAL];getLanguageCode in interface ExampleOrBuilderpublic com.google.protobuf.ByteString getLanguageCodeBytes()
Optional. The language code of the example. If not specified, the agent's default language is used. Note: languages must be enabled in the agent before they can be used. Note: example's language code is not currently used in dialogflow agents.
string language_code = 13 [(.google.api.field_behavior) = OPTIONAL];getLanguageCodeBytes in interface ExampleOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static Example parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Example parseFrom(InputStream input) throws IOException
IOExceptionpublic static Example parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Example parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static Example parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Example parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static Example parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic Example.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static Example.Builder newBuilder()
public static Example.Builder newBuilder(Example prototype)
public Example.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected Example.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static Example getDefaultInstance()
public static com.google.protobuf.Parser<Example> parser()
public com.google.protobuf.Parser<Example> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public Example getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2025 Google LLC. All rights reserved.