users@glassfish.java.net

Re: Glassfish and UTF-8

From: NBW <emailnbw_at_gmail.com>
Date: Thu, 3 Sep 2009 13:52:07 -0400

Technically speaking his LANG environment setting is referring to a LOCALE
which is more then just character encoding so setting file.encoding will get
your file I/O to be treated as UTF-8 or whatever other encoding you set this
to (unless the underlying java code uses certain constructors which override
this property which is possibility) which may or may not be sufficient to
your needs. If you need full LOCALE functionality you should take at your
Windows Locale related settings which I believe are in the Control Panel ->
Reginal and Language Options which I believe is picked up by the VM. These
links may be of some value -

http://java.sun.com/j2se/1.5.0/docs/guide/intl/locale.doc.html#jfc

This article in particular shows some properties that can be passed to
affect the VMs locale settings -

http://java.sun.com/developer/technicalArticles/J2SE/locale/


On Thu, Sep 3, 2009 at 12:06 PM, <glassfish_at_javadesktop.org> wrote:

> You need to work out how to set the JVM's language under Windows. One
> property is file.encoding but this [should] only affect file I/O, but google
> threw up this snippet:
> "By setting the (Windows) environment variable JAVA_TOOL_OPTIONS to
> -Dfile.encoding=UTF8, the (Java) System property will be set automatically
> every time a JVM is started. You will know that the parameter has been
> picked up because a message will be posted to System.err."
>
> So try that and see how you go.
> [Message sent by forum member 'matterbury' (matterbury_at_abinitio.com)]
>
> http://forums.java.net/jive/thread.jspa?messageID=362835
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
>