StoreBytesData
Stay organized with collections
Save and categorize content based on your preferences.
Data passed by apps to Block Store.
Inherited Constant Summary
From interface android.os.Parcelable
| int |
CONTENTS_FILE_DESCRIPTOR |
|
| int |
PARCELABLE_STABILITY_LOCAL |
|
| int |
PARCELABLE_STABILITY_VINTF |
|
| int |
PARCELABLE_WRITE_RETURN_VALUE |
|
Public Method Summary
| byte[] |
getBytes()
Raw bytes passed from apps to Block Store.
|
|
String
|
getKey()
The key with which the bytes are associated.
|
| boolean |
shouldBackupToCloud()
Whether the bytes to be stored should be backed up to the cloud in the next
sync.
|
| void |
|
Inherited Method Summary
From class java.lang.Object
|
Object
|
clone()
|
| boolean |
|
| void |
finalize()
|
|
final Class<?>
|
getClass()
|
| int |
hashCode()
|
| final void |
notify()
|
| final void |
notifyAll()
|
|
String
|
toString()
|
| final void |
wait(long arg0, int arg1)
|
| final void |
wait(long arg0)
|
| final void |
wait()
|
From interface android.os.Parcelable
| abstract int |
describeContents()
|
| abstract void |
writeToParcel( Parcel arg0,
int arg1)
|
Public Methods
public byte[] getBytes ()
Raw bytes passed from apps to Block Store.
public String getKey ()
The key with which the bytes are associated.
If the key was never explicitly set when building the StoreBytesData,
then the default key
BlockstoreClient.DEFAULT_BYTES_DATA_KEY is associated with the
bytes and therefore will be returned.
public boolean shouldBackupToCloud ()
Whether the bytes to be stored should be backed up to the cloud in the next
sync.
public void writeToParcel (Parcel dest, int
flags)
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-31 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-10-31 UTC."],[[["\u003cp\u003e\u003ccode\u003eStoreBytesData\u003c/code\u003e allows apps to pass data to Block Store, implementing \u003ccode\u003eParcelable\u003c/code\u003e for data transfer.\u003c/p\u003e\n"],["\u003cp\u003eIt includes methods to get the raw bytes, associated key, and cloud backup preference.\u003c/p\u003e\n"],["\u003cp\u003eA builder class, \u003ccode\u003eStoreBytesData.Builder\u003c/code\u003e, is available for creating \u003ccode\u003eStoreBytesData\u003c/code\u003e objects.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eCREATOR\u003c/code\u003e field facilitates object creation from parcels.\u003c/p\u003e\n"],["\u003cp\u003eIf no key is explicitly set, the default key \u003ccode\u003eBlockstoreClient.DEFAULT_BYTES_DATA_KEY\u003c/code\u003e is used.\u003c/p\u003e\n"]]],["`StoreBytesData` manages data passed to Block Store, implementing `Parcelable` for data transfer. Key actions involve retrieving raw bytes via `getBytes()`, accessing associated keys with `getKey()`, and determining cloud backup status through `shouldBackupToCloud()`. Data can be written to a `Parcel` using `writeToParcel()`. It also has a `CREATOR` and provides a nested builder class called `StoreBytesData.Builder` to aid in constructing instances of the class.\n"],null,[]]