Barcode
字段 |
kind (deprecated) |
string
表明这是哪类资源。值:固定字符串 "walletobjects#barcode" 。
|
type |
enum (BarcodeType )
条形码的类型。
|
renderEncoding |
enum (BarcodeRenderEncoding )
条形码的呈现编码。如果指定此字段,条形码会以给定的编码形式呈现。否则,Google 将选择最佳已知编码。
|
value |
string
条形码中编码的值。
|
alternateText |
string
可选文本,将替换条形码下显示的默认文本。此字段用于提供人类可读的条形码值,在无法扫描条形码时使用。
|
showCodeText |
object (LocalizedString )
在用户点击前条形码处于隐藏状态的情况下,系统将显示的可选文本。如果卡券启用了智能感应,就会发生这种情况。如果未指定,则由 Google 选择默认值。
|
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-11-13。
[null,null,["最后更新时间 (UTC):2024-11-13。"],[[["Barcodes in Google Wallet can be customized with type, rendering encoding, value, alternate text, and display settings for code text."],["The `kind` field is deprecated and should no longer be used."],["`showCodeText` field controls text display when the barcode is hidden, often due to Smart Tap."],["Barcode values can include an optional human-readable `alternateText` for accessibility."]]],["The core content describes the structure and fields of a barcode in a JSON format. Key information includes: `type` specifying the barcode type, `renderEncoding` defining how the barcode is rendered, and `value` containing the encoded data. `alternateText` provides a human-readable alternative, while `showCodeText` offers optional text when the barcode is hidden. The `kind` field is deprecated. The document describes each field's data type.\n"]]