IBM worklight 6.2 - 如何在应用程序中保存文件? [英] IBM worklight 6.2 - how to save files in the app?

查看:188
本文介绍了IBM worklight 6.2 - 如何在应用程序中保存文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我现在正在使用IBM worklight 6.2开发应用程序,而对于离线使用,我的应用程序需要从服务器下载所有演示数据,请问:

I am now developing Apps using IBM worklight 6.2, and for offline usage, my app need to download all the demo data from the server, may I ask:

如何在线上保存应用程序中的文件(如.png,.mp3,.ppt)并显示以供离线使用?
我可以直接使用JSONStore吗?或任何其他本地存储方法?顺便说一句
,我需要在IOS和Android中开发它。

how can I save files(like .png, .mp3, .ppt) in the app when online and show for offline usage ? can I direct use JSONStore to do so ? or any other local storage method ? by the way, I need to develop it both in IOS and Android.

推荐答案

最好的解决方案是关注JSONStore的培训模块和文档,并用它来存储您想要的任何文件。

Best solution would be to follow the training modules and documentation for JSONStore and use it to store any file you want.

在此处查看更多信息:

  • Worklight - Working Offline
  • JSONStore user documentation

否则,您可以实施Cordova文件API。但是,JSONStore更内置...

Otherwise, you can implement Cordova File API. But, JSONStore is more built-in...

  • https://github.com/apache/cordova-plugin-file-transfer/blob/master/doc/index.md
  • https://github.com/apache/cordova-plugin-file/blob/master/doc/index.md

这篇关于IBM worklight 6.2 - 如何在应用程序中保存文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆