سؤال

I'm working on a browser based applet game, and I intend to store the top ten scores in a text file in the directory with the JAR file. How would I read and write to a text file if it's outside the JAR file?

هل كانت مفيدة؟

المحلول

As far as I know the only way to do this is via the JNLP persistence service

نصائح أخرى

A signed applet (jar, JNLP) has the same disk IO permissions as the user running the applet.

Otherwise, javax.jnlp.PersistenceService is your best bet.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top