public class MiniProgramDataStorage extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
CACHE_CREATE_FAILED |
static int |
CACHE_EXPIRED |
static int |
CACHE_OUT_OF_MEMORY |
static int |
INVALID_VALUE |
static int |
KEY_EXPIRED |
static int |
KEY_NOT_FOUND |
| Constructor and Description |
|---|
MiniProgramDataStorage(String diskStorageDirectory,
String appId,
long diskStorageSizeBytes) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
void |
close() |
boolean |
delete(String key) |
String |
get(String key) |
long |
getSize() |
boolean |
put(String key,
String value) |
void |
removeErrorListener(com.zing.zalo.zbrowser.cache.MiniProgramDataStorage.ErrorListener errorListener) |
void |
setOnErrorListener(com.zing.zalo.zbrowser.cache.MiniProgramDataStorage.ErrorListener errorListener) |
public static final int CACHE_OUT_OF_MEMORY
public static final int CACHE_EXPIRED
public static final int CACHE_CREATE_FAILED
public static final int KEY_NOT_FOUND
public static final int KEY_EXPIRED
public static final int INVALID_VALUE
public boolean delete(String key)
public void clear()
public long getSize()
public void close()
public void setOnErrorListener(com.zing.zalo.zbrowser.cache.MiniProgramDataStorage.ErrorListener errorListener)
public void removeErrorListener(com.zing.zalo.zbrowser.cache.MiniProgramDataStorage.ErrorListener errorListener)