Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2008

Tip: Looking for answers? Try searching our database.

Charset.availableCharsets()

Thread view: 
column - 24 Mar 2008 12:46 GMT
Hello,

Charset.availableCharsets() returns a lot of charsets (additionally it
returns windows-1257=windows-1257).

But why it doesn't contains Charset.defaultCharset(), that is
windows-1257-110-84? I think default charset name should be from the
Charset.availableCharsets()  array.

Thank You
Sabine Dinis Blochberger - 24 Mar 2008 13:06 GMT
> Hello,
>
[quoted text clipped - 4 lines]
> windows-1257-110-84? I think default charset name should be from the
> Charset.availableCharsets()  array.

<http://java.sun.com/javase/6/docs/api/java/nio/charset/Charset.html#availableCharsets()>
states:

"...
This method may return different results at different times if new
charset providers are dynamically made available to the current Java
virtual machine.
.."

Signature

Sabine Dinis Blochberger

Op3racional
www.op3racional.eu

Roedy Green - 24 Mar 2008 13:06 GMT
On Mon, 24 Mar 2008 04:46:24 -0700 (PDT), column
<column.column@gmail.com> wrote, quoted or indirectly quoted someone
who said :

>But why it doesn't contains Charset.defaultCharset(), that is
>windows-1257-110-84? I think default charset name should be from the
>Charset.availableCharsets()  array.

Here's my guess.
It is not available on any machine but yours.  It is not one of Sun's
charsets. It is supported only by your OS, and is the current default
you have configured.

Note  that windows-1257 Balic rim  IS supported.
Signature


Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com

Steven Simpson - 24 Mar 2008 13:25 GMT
> But why [Charset.availableCharsets()] doesn't contains Charset.defaultCharset(), that is
> windows-1257-110-84? I think default charset name should be from the
> Charset.availableCharsets()  array.
>  

How are you testing this?

Charset.availableCharsets().containsValue(Charset.defaultCharset())
Charset.availableCharsets().containsKey(Charset.defaultCharset().toString())
Charset.availableCharsets().containsKey(Charset.defaultCharset().name())

Signature

ss at comp dot lancs dot ac dot uk                                     |



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.