在基于 GWT 的客户端中管理客户端数据库的最佳方法是什么?

发布于 2024-10-14 22:50:10 字数 269 浏览 5 评论 0原文

我正在开发 GWT 客户端。我的应用程序需要在客户端存储一些数据。我想将该数据放入浏览器缓存中。因此,这些数据将可供后续请求使用(至少对于当前浏览器会话)。

请建议我有哪些选择?我应该如何设计我的客户端代码?我将面临哪些挑战?

我了解了两种选择,一种是使用 Google 的 Gears,另一种是使用 HTML5。但并非所有浏览器都广泛支持这两种方法。我可以考虑在我的项目中添加一个新的数据层来处理数据库需求。我会将静态数据放入内存本身吗?

I am working on a GWT client. My application needs to store some data at the client. I want to put that data in the browser cache. SO, this data will be available to be used(at least for current browser session) by subsequent requests.

Please suggest me what options I have got? How should I design my client code? What challenges I will face?

I got to know about two options, one of using Google's Gears and other is using HTML5. But these both are not widely supported in all the browsers. Can I think of having a new Data Layer in my project, that will handle the database needs. And I will put my static data in the memory itself?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

千仐 2024-10-21 22:50:10

使用 HTML5 Web 存储。 Gears 不再更新,首选 HTML5 标准。

当您使用网络存储时,您将把数据存储在用户的磁盘上,这样浏览器和计算机崩溃就不会破坏您的数据。

Use HTML5 Web Storage. Gears is no longer being updated, and the HTML5 standard is preferred.

When you use Web Storage you will be storing your data on the user's disk, so that browser and computer crashes won't destroy your data.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文