ohos.utils.Sequenceablepublic enum TileStatus extends java.lang.Enum<TileStatus> implements ohos.utils.Sequenceable
A tile has various states in its lifecycle. When the tile state changes,
TileAbility#onStatusChanged(TileStatus) is called to notify the TileAbility, so that different
operations are performed as defined.
| 枚举常量 | 说明 |
|---|---|
TILE_HIDE |
Indicates that the tile is in the hidden state when a user releases the tile.
|
TILE_PREPARE |
Indicates that the tile is in the preparing state.
|
TILE_SELECTED |
Indicates that the tile is in the selected state.
|
TILE_UPDATE |
Indicates that the tile is in the updated state.
|
| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static ohos.utils.Sequenceable.Producer<TileStatus> |
PRODUCER |
The creator of
TileStatus. |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
boolean |
marshalling(ohos.utils.Parcel parcel) |
|
boolean |
unmarshalling(ohos.utils.Parcel parcel) |
|
static TileStatus |
valueOf(java.lang.String name) |
返回带有指定名称的该类型的枚举常量。
字符串必须与用于声明该类型的枚举常量的
标识符完全匹配。(不允许有多余
的空格字符。)
|
static TileStatus[] |
values() |
按照声明该枚举类型的常量的顺序, 返回
包含这些常量的数组。该方法可用于迭代
常量, 如下所示:
for (TileStatus c : TileStatus.values()) System.out.println(c); |
public static final TileStatus TILE_PREPARE
TILE_PREPARE to the
TileAbility, so that the tile has time to prepare the data to display.public static final TileStatus TILE_SELECTED
TILE_SELECTED to the TileAbility, which returns the tile data to display.public static final TileStatus TILE_HIDE
TileAbility should clear the data to reduce system load.public static final TileStatus TILE_UPDATE
TileEntity object should be
returned. The system passes TILE_UPDATE to the TileAbility in the following cases:
TileAbility calls TileAbility#notifyDataChanged(Context, ElementName).TileEntity.Builder.setUpdateDelay(long)
and the delay elapses.public static final ohos.utils.Sequenceable.Producer<TileStatus> PRODUCER
TileStatus.public static TileStatus[] values()
for (TileStatus c : TileStatus.values()) System.out.println(c);
public static TileStatus valueOf(java.lang.String name)
name - 要返回的枚举常量的名称。java.lang.IllegalArgumentException - 如果该枚举类型没有带有指定名称的常量java.lang.NullPointerException - 如果参数为空值public boolean marshalling(ohos.utils.Parcel parcel)
marshalling 在接口中 ohos.utils.Sequenceablepublic boolean unmarshalling(ohos.utils.Parcel parcel)
unmarshalling 在接口中 ohos.utils.Sequenceable