TaskAttribute
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
将任务属性描述为键值对。“key:value”字符串长度不能超过 256 个字符。
JSON 表示法 |
{
"key": string,
// Union field task_attribute_value can be only one of the following:
"stringValue": string,
"boolValue": boolean,
"numberValue": number
// End of list of possible types for union field task_attribute_value .
} |
字段 |
key |
string
属性的键。键不得包含冒号字符 (:)。
|
联合字段 task_attribute_value 。该属性的值可以是字符串、bool 或双精度类型。如果未设置,TaskAttribute string_value 将存储为空字符串 ""。task_attribute_value 只能是下列其中一项: |
stringValue |
string
字符串类型的属性值。
|
boolValue |
boolean
布尔值类型的属性值。
|
numberValue |
number
双精度型属性值。
|
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-08-31。
[null,null,["最后更新时间 (UTC):2025-08-31。"],[[["\u003cp\u003eTask attributes are represented as key-value pairs in JSON format, with a maximum length of 256 characters for the "key:value" string.\u003c/p\u003e\n"],["\u003cp\u003eAttribute keys cannot contain colons and values can be strings, booleans, or numbers.\u003c/p\u003e\n"],["\u003cp\u003eIf no specific value type is set, the attribute will be stored as an empty string.\u003c/p\u003e\n"]]],["A task attribute is represented as a key-value pair with a maximum string length of 256 characters. The `key` is a string that cannot include colons. The `task_attribute_value` can be a string, boolean, or number. If no value is provided, the string value defaults to an empty string. Only one value type can be set for the `task_attribute_value`.\n"],null,["# TaskAttribute\n\n- [JSON representation](#SCHEMA_REPRESENTATION)\n\nDescribes a task attribute as a key-value pair. The \"key:value\" string length cannot exceed 256 characters.\n\n| JSON representation |\n|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"key\": string, // Union field `task_attribute_value` can be only one of the following: \"stringValue\": string, \"boolValue\": boolean, \"numberValue\": number // End of list of possible types for union field `task_attribute_value`. } ``` |\n\n| Fields ||\n|---------------|-----------------------------------------------------------------------------|\n| `key` | `string` The attribute's key. Keys may not contain the colon character (:). |\n| Union field `task_attribute_value`. The attribute's value, can be in string, bool, or double type. If none are set the TaskAttribute string_value will be stored as the empty string \"\". `task_attribute_value` can be only one of the following: ||\n| `stringValue` | `string` String typed attribute value. |\n| `boolValue` | `boolean` Boolean typed attribute value. |\n| `numberValue` | `number` Double typed attribute value. |"]]