LocalizedString
Trường |
kind (deprecated) |
string
Xác định loại tài nguyên này. Giá trị: chuỗi cố định "walletobjects#localizedString" .
|
translatedValues[] |
object (TranslatedString )
Chứa bản dịch cho chuỗi.
|
defaultValue |
object (TranslatedString )
Chứa chuỗi sẽ hiển thị nếu không có bản dịch phù hợp.
|
TranslatedString
Biểu diễn dưới dạng JSON |
{
"kind": string,
"language": string,
"value": string
} |
Trường |
kind (deprecated) |
string
Xác định loại tài nguyên đây. Giá trị: chuỗi cố định "walletobjects#translatedString" .
|
language |
string
Biểu thị thẻ ngôn ngữ BCP 47. Ví dụ: "en-US", "en-GB", "de" hoặc "de-AT".
|
value |
string
Chuỗi đã dịch được mã hoá theo UTF-8.
|
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2024-11-13 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2024-11-13 UTC."],[[["`LocalizedString` objects store translations for a string, including a default value if no translation is available."],["The `translatedValues` field within `LocalizedString` holds an array of `TranslatedString` objects, each representing a translation in a specific language."],["`TranslatedString` objects contain the language code (`language`) and the actual translated string (`value`)."],["If no suitable translation is found in `translatedValues`, the `defaultValue` field's `TranslatedString` object is used for display."]]],["The document outlines JSON structures for representing localized strings. A main structure contains a deprecated `kind`, an array of `translatedValues` (objects), and a `defaultValue` (object). Each `translatedValue` and `defaultValue` includes another structure with a deprecated `kind`, a `language` tag (BCP 47 format), and a `value` representing the UTF-8 encoded translated string. These structures enable managing multiple language translations for a given string.\n"]]