Package com.google.apps.card.v1
Class TextInput
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.ExtendableMessage<com.google.protobuf.GeneratedMessageV3>
com.google.protobuf.GeneratedMessageV3
com.google.apps.card.v1.TextInput
- All Implemented Interfaces:
TextInputOrBuilder
,com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>
,com.google.protobuf.Message
,com.google.protobuf.MessageLite
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Serializable
public final class TextInput
extends com.google.protobuf.GeneratedMessageV3
implements TextInputOrBuilder
A field in which users can enter text. Supports suggestions and on-change actions. For an example in Google Chat apps, see [Add a field in which a user can enter text](https://developers.google.com/workspace/chat/design-interactive-card-dialog#add_a_field_in_which_a_user_can_enter_text). Chat apps receive and can process the value of entered text during form input events. For details about working with form inputs, see [Receive form data](https://developers.google.com/workspace/chat/read-form-data). When you need to collect undefined or abstract data from users, use a text input. To collect defined or enumerated data from users, use the [SelectionInput][google.apps.card.v1.SelectionInput] widget. [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):Protobuf type
google.apps.card.v1.TextInput
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
A field in which users can enter text.static enum
How a text input field appears in the user interface.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
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 Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage.ExtendableMessage
com.google.protobuf.GeneratedMessage.ExtendableMessage.ExtensionSerializer, com.google.protobuf.GeneratedMessage.ExtendableMessage.ExtensionWriter
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message,
T> Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
Fields inherited from class com.google.protobuf.GeneratedMessage
alwaysUseFieldBuilders, unknownFields
Fields inherited from class com.google.protobuf.AbstractMessage
memoizedSize
Fields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Optional.Optional.static TextInput
static final com.google.protobuf.Descriptors.Descriptor
Text that appears below the text input field meant to assist users by prompting them to enter a certain value.com.google.protobuf.ByteString
Text that appears below the text input field meant to assist users by prompting them to enter a certain value.Suggested values that users can enter.Suggested values that users can enter.getLabel()
The text that appears above the text input field in the user interface.com.google.protobuf.ByteString
The text that appears above the text input field in the user interface.getName()
The name by which the text input is identified in a form input event.com.google.protobuf.ByteString
The name by which the text input is identified in a form input event.What to do when a change occurs in the text input field.What to do when a change occurs in the text input field.com.google.protobuf.Parser
<TextInput> Text that appears in the text input field when the field is empty.com.google.protobuf.ByteString
Text that appears in the text input field when the field is empty.int
getType()
How a text input field appears in the user interface.int
How a text input field appears in the user interface.getValue()
The value entered by a user, returned as part of a form input event.com.google.protobuf.ByteString
The value entered by a user, returned as part of a form input event.boolean
Optional.int
hashCode()
boolean
Suggested values that users can enter.boolean
What to do when a change occurs in the text input field.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
final boolean
static TextInput.Builder
static TextInput.Builder
newBuilder
(TextInput prototype) protected TextInput.Builder
newBuilderForType
(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) protected Object
newInstance
(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) static TextInput
parseDelimitedFrom
(InputStream input) static TextInput
parseDelimitedFrom
(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static TextInput
parseFrom
(byte[] data) static TextInput
parseFrom
(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static TextInput
parseFrom
(com.google.protobuf.ByteString data) static TextInput
parseFrom
(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static TextInput
parseFrom
(com.google.protobuf.CodedInputStream input) static TextInput
parseFrom
(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static TextInput
parseFrom
(InputStream input) static TextInput
parseFrom
(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static TextInput
parseFrom
(ByteBuffer data) static TextInput
parseFrom
(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser
<TextInput> parser()
void
writeTo
(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessageV3
mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType
Methods inherited from class com.google.protobuf.GeneratedMessage.ExtendableMessage
extensionsAreInitialized, extensionsSerializedSize, extensionsSerializedSizeAsMessageSet, getAllFields, getAllFieldsRaw, getExtension, getExtension, getExtensionCount, getExtensionFields, getField, getRepeatedField, getRepeatedFieldCount, hasExtension, hasField, newExtensionSerializer, newExtensionWriter, newMessageSetExtensionSerializer, newMessageSetExtensionWriter
Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getDescriptorForType, getOneofFieldDescriptor, getUnknownFields, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toString
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeTo
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER- See Also:
-
LABEL_FIELD_NUMBER
public static final int LABEL_FIELD_NUMBER- See Also:
-
HINT_TEXT_FIELD_NUMBER
public static final int HINT_TEXT_FIELD_NUMBER- See Also:
-
VALUE_FIELD_NUMBER
public static final int VALUE_FIELD_NUMBER- See Also:
-
TYPE_FIELD_NUMBER
public static final int TYPE_FIELD_NUMBER- See Also:
-
ON_CHANGE_ACTION_FIELD_NUMBER
public static final int ON_CHANGE_ACTION_FIELD_NUMBER- See Also:
-
INITIAL_SUGGESTIONS_FIELD_NUMBER
public static final int INITIAL_SUGGESTIONS_FIELD_NUMBER- See Also:
-
AUTO_COMPLETE_ACTION_FIELD_NUMBER
public static final int AUTO_COMPLETE_ACTION_FIELD_NUMBER- See Also:
-
PLACEHOLDER_TEXT_FIELD_NUMBER
public static final int PLACEHOLDER_TEXT_FIELD_NUMBER- See Also:
-
-
Method Details
-
newInstance
- Overrides:
newInstance
in classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Overrides:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3
-
getName
The name by which the text input is identified in a form input event. For details about working with form inputs, see [Receive form data](https://developers.google.com/workspace/chat/read-form-data).
string name = 1;
- Specified by:
getName
in interfaceTextInputOrBuilder
- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()The name by which the text input is identified in a form input event. For details about working with form inputs, see [Receive form data](https://developers.google.com/workspace/chat/read-form-data).
string name = 1;
- Specified by:
getNameBytes
in interfaceTextInputOrBuilder
- Returns:
- The bytes for name.
-
getLabel
The text that appears above the text input field in the user interface. Specify text that helps the user enter the information your app needs. For example, if you are asking someone's name, but specifically need their surname, write `surname` instead of `name`. Required if `hintText` is unspecified. Otherwise, optional.
string label = 2;
- Specified by:
getLabel
in interfaceTextInputOrBuilder
- Returns:
- The label.
-
getLabelBytes
public com.google.protobuf.ByteString getLabelBytes()The text that appears above the text input field in the user interface. Specify text that helps the user enter the information your app needs. For example, if you are asking someone's name, but specifically need their surname, write `surname` instead of `name`. Required if `hintText` is unspecified. Otherwise, optional.
string label = 2;
- Specified by:
getLabelBytes
in interfaceTextInputOrBuilder
- Returns:
- The bytes for label.
-
getHintText
Text that appears below the text input field meant to assist users by prompting them to enter a certain value. This text is always visible. Required if `label` is unspecified. Otherwise, optional.
string hint_text = 3;
- Specified by:
getHintText
in interfaceTextInputOrBuilder
- Returns:
- The hintText.
-
getHintTextBytes
public com.google.protobuf.ByteString getHintTextBytes()Text that appears below the text input field meant to assist users by prompting them to enter a certain value. This text is always visible. Required if `label` is unspecified. Otherwise, optional.
string hint_text = 3;
- Specified by:
getHintTextBytes
in interfaceTextInputOrBuilder
- Returns:
- The bytes for hintText.
-
getValue
The value entered by a user, returned as part of a form input event. For details about working with form inputs, see [Receive form data](https://developers.google.com/workspace/chat/read-form-data).
string value = 4;
- Specified by:
getValue
in interfaceTextInputOrBuilder
- Returns:
- The value.
-
getValueBytes
public com.google.protobuf.ByteString getValueBytes()The value entered by a user, returned as part of a form input event. For details about working with form inputs, see [Receive form data](https://developers.google.com/workspace/chat/read-form-data).
string value = 4;
- Specified by:
getValueBytes
in interfaceTextInputOrBuilder
- Returns:
- The bytes for value.
-
getTypeValue
public int getTypeValue()How a text input field appears in the user interface. For example, whether the field is single or multi-line.
.google.apps.card.v1.TextInput.Type type = 5;
- Specified by:
getTypeValue
in interfaceTextInputOrBuilder
- Returns:
- The enum numeric value on the wire for type.
-
getType
How a text input field appears in the user interface. For example, whether the field is single or multi-line.
.google.apps.card.v1.TextInput.Type type = 5;
- Specified by:
getType
in interfaceTextInputOrBuilder
- Returns:
- The type.
-
hasOnChangeAction
public boolean hasOnChangeAction()What to do when a change occurs in the text input field. For example, a user adding to the field or deleting text. Examples of actions to take include running a custom function or opening a [dialog](https://developers.google.com/workspace/chat/dialogs) in Google Chat.
.google.apps.card.v1.Action on_change_action = 6;
- Specified by:
hasOnChangeAction
in interfaceTextInputOrBuilder
- Returns:
- Whether the onChangeAction field is set.
-
getOnChangeAction
What to do when a change occurs in the text input field. For example, a user adding to the field or deleting text. Examples of actions to take include running a custom function or opening a [dialog](https://developers.google.com/workspace/chat/dialogs) in Google Chat.
.google.apps.card.v1.Action on_change_action = 6;
- Specified by:
getOnChangeAction
in interfaceTextInputOrBuilder
- Returns:
- The onChangeAction.
-
getOnChangeActionOrBuilder
What to do when a change occurs in the text input field. For example, a user adding to the field or deleting text. Examples of actions to take include running a custom function or opening a [dialog](https://developers.google.com/workspace/chat/dialogs) in Google Chat.
.google.apps.card.v1.Action on_change_action = 6;
- Specified by:
getOnChangeActionOrBuilder
in interfaceTextInputOrBuilder
-
hasInitialSuggestions
public boolean hasInitialSuggestions()Suggested values that users can enter. These values appear when users click inside the text input field. As users type, the suggested values dynamically filter to match what the users have typed. For example, a text input field for programming language might suggest Java, JavaScript, Python, and C++. When users start typing `Jav`, the list of suggestions filters to show just `Java` and `JavaScript`. Suggested values help guide users to enter values that your app can make sense of. When referring to JavaScript, some users might enter `javascript` and others `java script`. Suggesting `JavaScript` can standardize how users interact with your app. When specified, `TextInput.type` is always `SINGLE_LINE`, even if it's set to `MULTIPLE_LINE`. [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):
.google.apps.card.v1.Suggestions initial_suggestions = 7;
- Specified by:
hasInitialSuggestions
in interfaceTextInputOrBuilder
- Returns:
- Whether the initialSuggestions field is set.
-
getInitialSuggestions
Suggested values that users can enter. These values appear when users click inside the text input field. As users type, the suggested values dynamically filter to match what the users have typed. For example, a text input field for programming language might suggest Java, JavaScript, Python, and C++. When users start typing `Jav`, the list of suggestions filters to show just `Java` and `JavaScript`. Suggested values help guide users to enter values that your app can make sense of. When referring to JavaScript, some users might enter `javascript` and others `java script`. Suggesting `JavaScript` can standardize how users interact with your app. When specified, `TextInput.type` is always `SINGLE_LINE`, even if it's set to `MULTIPLE_LINE`. [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):
.google.apps.card.v1.Suggestions initial_suggestions = 7;
- Specified by:
getInitialSuggestions
in interfaceTextInputOrBuilder
- Returns:
- The initialSuggestions.
-
getInitialSuggestionsOrBuilder
Suggested values that users can enter. These values appear when users click inside the text input field. As users type, the suggested values dynamically filter to match what the users have typed. For example, a text input field for programming language might suggest Java, JavaScript, Python, and C++. When users start typing `Jav`, the list of suggestions filters to show just `Java` and `JavaScript`. Suggested values help guide users to enter values that your app can make sense of. When referring to JavaScript, some users might enter `javascript` and others `java script`. Suggesting `JavaScript` can standardize how users interact with your app. When specified, `TextInput.type` is always `SINGLE_LINE`, even if it's set to `MULTIPLE_LINE`. [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):
.google.apps.card.v1.Suggestions initial_suggestions = 7;
- Specified by:
getInitialSuggestionsOrBuilder
in interfaceTextInputOrBuilder
-
hasAutoCompleteAction
public boolean hasAutoCompleteAction()Optional. Specify what action to take when the text input field provides suggestions to users who interact with it. If unspecified, the suggestions are set by `initialSuggestions` and are processed by the client. If specified, the app takes the action specified here, such as running a custom function. [Google Workspace Add-ons](https://developers.google.com/workspace/add-ons):
.google.apps.card.v1.Action auto_complete_action = 8;
- Specified by:
hasAutoCompleteAction
in interfaceTextInputOrBuilder
- Returns:
- Whether the autoCompleteAction field is set.
-
getAutoCompleteAction
Optional. Specify what action to take when the text input field provides suggestions to users who interact with it. If unspecified, the suggestions are set by `initialSuggestions` and are processed by the client. If specified, the app takes the action specified here, such as running a custom function. [Google Workspace Add-ons](https://developers.google.com/workspace/add-ons):
.google.apps.card.v1.Action auto_complete_action = 8;
- Specified by:
getAutoCompleteAction
in interfaceTextInputOrBuilder
- Returns:
- The autoCompleteAction.
-
getAutoCompleteActionOrBuilder
Optional. Specify what action to take when the text input field provides suggestions to users who interact with it. If unspecified, the suggestions are set by `initialSuggestions` and are processed by the client. If specified, the app takes the action specified here, such as running a custom function. [Google Workspace Add-ons](https://developers.google.com/workspace/add-ons):
.google.apps.card.v1.Action auto_complete_action = 8;
- Specified by:
getAutoCompleteActionOrBuilder
in interfaceTextInputOrBuilder
-
getPlaceholderText
Text that appears in the text input field when the field is empty. Use this text to prompt users to enter a value. For example, `Enter a number from 0 to 100`. [Google Chat apps](https://developers.google.com/workspace/chat):
string placeholder_text = 12;
- Specified by:
getPlaceholderText
in interfaceTextInputOrBuilder
- Returns:
- The placeholderText.
-
getPlaceholderTextBytes
public com.google.protobuf.ByteString getPlaceholderTextBytes()Text that appears in the text input field when the field is empty. Use this text to prompt users to enter a value. For example, `Enter a number from 0 to 100`. [Google Chat apps](https://developers.google.com/workspace/chat):
string placeholder_text = 12;
- Specified by:
getPlaceholderTextBytes
in interfaceTextInputOrBuilder
- Returns:
- The bytes for placeholderText.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage.ExtendableMessage<com.google.protobuf.GeneratedMessageV3>
-
writeTo
- Specified by:
writeTo
in interfacecom.google.protobuf.MessageLite
- Overrides:
writeTo
in classcom.google.protobuf.GeneratedMessage
- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSize
in interfacecom.google.protobuf.MessageLite
- Overrides:
getSerializedSize
in classcom.google.protobuf.GeneratedMessage
-
equals
- Specified by:
equals
in interfacecom.google.protobuf.Message
- Overrides:
equals
in classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCode
in interfacecom.google.protobuf.Message
- Overrides:
hashCode
in classcom.google.protobuf.AbstractMessage
-
parseFrom
public static TextInput parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static TextInput parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static TextInput parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static TextInput parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static TextInput parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static TextInput parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static TextInput parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static TextInput parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static TextInput parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.Message
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilder
in interfacecom.google.protobuf.Message
- Specified by:
toBuilder
in interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected TextInput.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) - Specified by:
newBuilderForType
in classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForType
in interfacecom.google.protobuf.Message
- Specified by:
getParserForType
in interfacecom.google.protobuf.MessageLite
- Overrides:
getParserForType
in classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-