public static final class ExampleQuery.Builder extends GeneratedMessage.Builder<ExampleQuery.Builder> implements ExampleQueryOrBuilderExample of relevant and commonly used SQL query and its corresponding natural language queries optionally present. Currently only used for BigQuery data sources.
Protobuf type google.cloud.geminidataanalytics.v1beta.ExampleQuery
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > ExampleQuery.BuilderImplements
ExampleQueryOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public ExampleQuery build()| Returns | |
|---|---|
| Type | Description |
ExampleQuery |
|
buildPartial()
public ExampleQuery buildPartial()| Returns | |
|---|---|
| Type | Description |
ExampleQuery |
|
clear()
public ExampleQuery.Builder clear()| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
|
clearNaturalLanguageQuestion()
public ExampleQuery.Builder clearNaturalLanguageQuestion()Optional. A natural language question that a user might ask. For example: "How many orders were placed last month?"
string natural_language_question = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |
clearQuery()
public ExampleQuery.Builder clearQuery()| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
|
clearSqlQuery()
public ExampleQuery.Builder clearSqlQuery()Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |
getDefaultInstanceForType()
public ExampleQuery getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
ExampleQuery |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getNaturalLanguageQuestion()
public String getNaturalLanguageQuestion()Optional. A natural language question that a user might ask. For example: "How many orders were placed last month?"
string natural_language_question = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The naturalLanguageQuestion. |
getNaturalLanguageQuestionBytes()
public ByteString getNaturalLanguageQuestionBytes()Optional. A natural language question that a user might ask. For example: "How many orders were placed last month?"
string natural_language_question = 1 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for naturalLanguageQuestion. |
getQueryCase()
public ExampleQuery.QueryCase getQueryCase()| Returns | |
|---|---|
| Type | Description |
ExampleQuery.QueryCase |
|
getSqlQuery()
public String getSqlQuery()Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The sqlQuery. |
getSqlQueryBytes()
public ByteString getSqlQueryBytes()Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for sqlQuery. |
hasSqlQuery()
public boolean hasSqlQuery()Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the sqlQuery field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(ExampleQuery other)
public ExampleQuery.Builder mergeFrom(ExampleQuery other)| Parameter | |
|---|---|
| Name | Description |
other |
ExampleQuery |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public ExampleQuery.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public ExampleQuery.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
|
setNaturalLanguageQuestion(String value)
public ExampleQuery.Builder setNaturalLanguageQuestion(String value)Optional. A natural language question that a user might ask. For example: "How many orders were placed last month?"
string natural_language_question = 1 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe naturalLanguageQuestion to set. |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |
setNaturalLanguageQuestionBytes(ByteString value)
public ExampleQuery.Builder setNaturalLanguageQuestionBytes(ByteString value)Optional. A natural language question that a user might ask. For example: "How many orders were placed last month?"
string natural_language_question = 1 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for naturalLanguageQuestion to set. |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |
setSqlQuery(String value)
public ExampleQuery.Builder setSqlQuery(String value)Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe sqlQuery to set. |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |
setSqlQueryBytes(ByteString value)
public ExampleQuery.Builder setSqlQueryBytes(ByteString value)Optional. The SQL query that should be generated to answer the natural language question. For example: "SELECT COUNT(*) FROM orders WHERE order_date BETWEEN '2024-01-01' AND '2024-01-31'"
string sql_query = 101 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for sqlQuery to set. |
| Returns | |
|---|---|
| Type | Description |
ExampleQuery.Builder |
This builder for chaining. |