Enum ContentType
Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
TreśćTyp
Wartość wyliczenia określająca typ treści wygenerowanych przez UpdateDraftActionResponse
.
Aby wywołać enum, wywołaj jego klasę nadrzędną, nazwę i właściwość. Na przykład:
CardService.ContentType.TEXT
.
Właściwości
Właściwość | Typ | Opis |
TEXT | Enum | Wskazuje, że wygenerowane treści są tekstem zwykłym. Domyślny: |
MUTABLE_HTML | Enum | Wskazuje, że wygenerowana treść jest sformatowana jako kod HTML. Po wygenerowaniu treści można je edytować. |
IMMUTABLE_HTML | Enum | Wskazuje, że wygenerowane treści są sformatowane jako HTML, ale nie można ich edytować po wygenerowaniu. |
O ile nie stwierdzono inaczej, treść tej strony jest objęta licencją Creative Commons – uznanie autorstwa 4.0, a fragmenty kodu są dostępne na licencji Apache 2.0. Szczegółowe informacje na ten temat zawierają zasady dotyczące witryny Google Developers. Java jest zastrzeżonym znakiem towarowym firmy Oracle i jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-07-26 UTC.
[null,null,["Ostatnia aktualizacja: 2025-07-26 UTC."],[[["\u003cp\u003e\u003ccode\u003eContentType\u003c/code\u003e is an enum used to define the type of content generated by \u003ccode\u003eUpdateDraftActionResponse\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eContent types include \u003ccode\u003eTEXT\u003c/code\u003e (default plain text), \u003ccode\u003eMUTABLE_HTML\u003c/code\u003e (editable HTML), and \u003ccode\u003eIMMUTABLE_HTML\u003c/code\u003e (non-editable HTML).\u003c/p\u003e\n"],["\u003cp\u003eTo specify a content type, use the syntax: \u003ccode\u003eCardService.ContentType.PROPERTY\u003c/code\u003e, replacing \u003ccode\u003ePROPERTY\u003c/code\u003e with the desired type.\u003c/p\u003e\n"]]],["The `ContentType` enum specifies the type of content generated by an `UpdateDraftActionResponse`. It has three properties: `TEXT`, `MUTABLE_HTML`, and `IMMUTABLE_HTML`. `TEXT` indicates plain text, which is the default. `MUTABLE_HTML` represents editable HTML content, while `IMMUTABLE_HTML` represents HTML content that cannot be edited after generation. These properties are accessed via `CardService.ContentType` followed by the chosen type, such as `TEXT`.\n"],null,["# Enum ContentType\n\nContentType\n\nAn enum value that specifies the content type of the content generated by a [UpdateDraftActionResponse](/apps-script/reference/card-service/update-draft-action-response).\n\nTo call an enum, you call its parent class, name, and property. For example, `\nCardService.ContentType.TEXT`. \n\n### Properties\n\n| Property | Type | Description |\n|------------------|--------|---------------------------------------------------------------------------------------------------------------------|\n| `TEXT` | `Enum` | Indicates that the generated content is plain text. Default. |\n| `MUTABLE_HTML` | `Enum` | Indicates that the generated content is formatted as HTML. The content can be edited after it is generated. |\n| `IMMUTABLE_HTML` | `Enum` | Indicates that the generated content is formatted as HTML, but this content cannot be edited after it is generated. |"]]