Cache模块用于管理应用缓存,通过plus.cache获取缓存管理对象。
permissions
"Cache": {
"description": "管理应用缓存"
}
清除应用缓存完成回调
void onCompleted() {
// Clear cache completed code.
}
清除应用缓存回调函数,调用plus.cache.clear清除缓存操作时作为参数传入,在清除缓存操作完成时触发回调。
计算应用使用缓存容量回调
void onCompleted( size ) {
// Calculate cache complete code.
}
计算应用当前使用缓存容量回调函数,调用plus.cache.calculate计算缓存容量操作时作为参数传入,在计算缓存容量大小完成时触发回调。