如果使用 JWS 启动 java 应用程序,将应用程序数据和临时文件放在 Windows、Linux 和 MAC 的何处 [英] Where to put application data and temp files on Windows, Linux and MAC if java-application is being lauched using JWS

查看:43
本文介绍了如果使用 JWS 启动 java 应用程序,将应用程序数据和临时文件放在 Windows、Linux 和 MAC 的何处的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们可以允许用户使用已经使用 JWS 运行/启动的 Java-Application 设置和保存应用程序数据和临时数据吗?是否有意义 ?

Can we allow user to set and save application data and temp data using Java-Application that has beenrun/launch using JWS ? Does it make sense ?

我们想知道如果用户直接运行 JNLP 那么用户可以在本地保存首选项设置,这样当他/她再次运行 JNLP 时,他/她可以再次找到他/她上次保存的设置.

We would like to know if user run JNLP directly then can user save preferences settings on local so when he/she run again JNLP he/she could find his/her last saved settings again.

在哪里放置应用程序数据,即配置文件、属性文件.如果使用 JWS 启动 java 应用程序,用户下载路径等.以及在 Windows、Linux 和 MAC 上将临时文件(即日志等)放在哪里?

Where to put application data i.e configuration files, properties file. user download path etc.. and where to put temp files i.e.. logs etc.. on Windows, Linux and MAC if java-application is being launched using JWS ?

推荐答案

我经常使用 java.util.prefs.Preferences,但是 javax.jnlp.PersistenceService 可用于 Java Web Start 应用程序.两者都代表跨平台的抽象.

I often use java.util.prefs.Preferences, but javax.jnlp.PersistenceService is available to Java Web Start applications. Both represent abstractions that are cross-platform.

这篇关于如果使用 JWS 启动 java 应用程序,将应用程序数据和临时文件放在 Windows、Linux 和 MAC 的何处的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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