UserStyleSetting.Option.Id
public final class UserStyleSetting.Option.Id
Machine readable identifier for Options. The length of this identifier may not exceed MAX_LENGTH.
Summary
Constants |
|
|---|---|
static final int |
MAX_LENGTH = 1024This field is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
Public constructors |
|---|
|
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
|
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
Public methods |
|
|---|---|
boolean |
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
final @NonNull byte[] |
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
int |
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
@NonNull String |
This method is deprecated. AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
Constants
MAX_LENGTH
public static final int MAX_LENGTH = 1024
Maximum length of the value field to ensure acceptable companion editing latency. Please note the UserStyleSchema and the UserStyleSetting are sent over bluetooth to the companion phone when editing, and that bandwidth is limited (2mbps is common). Best practice is to keep these Ids short, ideally under 10 bytes.
Note the UserStyle has a maximum size (UserStyle.MAXIMUM_SIZE_BYTES) and that Option Ids are a significant contributor to the overall size of a UserStyle.
Public constructors
Id
publicId(@NonNull String value)
Constructs an Id with a String encoded to a ByteArray by String.encodeToByteArray.
Public methods
getValue
public final @NonNull byte[]getValue()
The ByteArray value of this Id.