com.herewhite.sdk.SyncedStore class 参考
适用版本:Whiteboard Android SDK 2.16.134。
| 公开成员签名 | |
| SyncedStore (JsBridgeInterface bridge) | |
| void | connectStorage (String name, String defaultJson, Promise<String> promise) |
| String | getStorageState (String name) |
| void | getStorageState (String name, Promise<String> promise) |
| void | setStorageState (String name, String json) |
| void | disconnectStorage (String name) |
| void | deleteStorage (String name) |
| void | resetState (String name) |
| void | addOnStateChangedListener (String name, OnStateChangedListener listener) |
| void | removeOnStateChangedListener (String name, OnStateChangedListener listener) |
函数说明
SyncedStore()
| SyncedStore(JsBridgeInterface bridge) |
SyncedStore:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
connectStorage()
| void connectStorage(String name, String defaultJson, Promise<String> promise) |
connectStorage:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
getStorageState()
| String getStorageState(String name) |
getStorageState:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
getStorageState()
| void getStorageState(String name, Promise<String> promise) |
getStorageState:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
setStorageState()
| void setStorageState(String name, String json) |
setStorageState:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
disconnectStorage()
| void disconnectStorage(String name) |
Disconnect from synced storage and release listeners
参数
参数
| 参数名 | 描述 |
|---|---|
name | : storage name |
deleteStorage()
| void deleteStorage(String name) |
Delete storage index with all of its data and destroy the Storage instance.
参数
参数
| 参数名 | 描述 |
|---|---|
name | : storage name |
resetState()
addOnStateChangedListener()
| void addOnStateChangedListener(String name, OnStateChangedListener listener) |
addOnStateChangedListener:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。
removeOnStateChangedListener()
| void removeOnStateChangedListener(String name, OnStateChangedListener listener) |
removeOnStateChangedListener:com.herewhite.sdk.SyncedStore 的公开成员。参数和返回类型见下方签名。