java.net.IDN jar for JDK 1.5?

Discussion in 'Java' started by Jan Burse, Jul 26, 2011.

  1. Jan Burse

    Jan Burse Guest

    Dear All,

    Just noticed that JDK 1.6 has the new class java.net.IDN,
    which provides Namerep and Punycode.

    Any .jar file around that can be used to add this
    functionality (this class) to JDK 1.5?

    Best Regards
    Jan Burse, Jul 26, 2011
    #1
    1. Advertising

  2. Jan Burse

    lewbloch Guest

    On Jul 26, 3:24 am, Jan Burse <> wrote:
    > Dear All,
    >
    > Just noticed that JDK 1.6 has the new class java.net.IDN,
    > which provides Namerep and Punycode.
    >
    > Any .jar file around that can be used to add this
    > functionality (this class) to JDK 1.5?


    I don't find one with a quick trip to Google, although it looks like
    there might be a com.sun.* package out there somewhere that has it.

    You are aware that Java 5 has been retired for nearly two years now,
    right?

    "J2SE 5.0 End of Service Life Notice

    "J2SE 5.0 reached its End of Service Life (EOSL) on November 3, 2009,
    which is the date of the final publicly available update of version
    5.0 (J2SE 5.0 Update 22) ..."
    <http://www.oracle.com/technetwork/java/javase/downloads/index-jdk5-
    jsp-142662.html>

    That means that it's missing several bug and security updates that
    have made it into Java 6.

    --
    Lew
    lewbloch, Jul 26, 2011
    #2
    1. Advertising

  3. Jan Burse

    Jan Burse Guest

    lewbloch schrieb:
    > On Jul 26, 3:24 am, Jan Burse<> wrote:
    >> Dear All,
    >>
    >> Just noticed that JDK 1.6 has the new class java.net.IDN,
    >> which provides Namerep and Punycode.
    >>
    >> Any .jar file around that can be used to add this
    >> functionality (this class) to JDK 1.5?

    >
    > I don't find one with a quick trip to Google, although it looks like
    > there might be a com.sun.* package out there somewhere that has it.
    >
    > You are aware that Java 5 has been retired for nearly two years now,
    > right?
    >
    > "J2SE 5.0 End of Service Life Notice
    >
    > "J2SE 5.0 reached its End of Service Life (EOSL) on November 3, 2009,
    > which is the date of the final publicly available update of version
    > 5.0 (J2SE 5.0 Update 22) ..."
    > <http://www.oracle.com/technetwork/java/javase/downloads/index-jdk5-
    > jsp-142662.html>
    >
    > That means that it's missing several bug and security updates that
    > have made it into Java 6.
    >
    > --
    > Lew


    I guess you are preaching to the converted?
    Its not me who is using JDK 1.5, but some
    supplier of mine. And I need to create layer,
    that works accross JDK 1.5 and JDK 1.6.

    Bye
    Jan Burse, Jul 26, 2011
    #3
  4. Jan Burse

    Arne Vajhøj Guest

    On 7/26/2011 6:24 AM, Jan Burse wrote:
    > Just noticed that JDK 1.6 has the new class java.net.IDN,
    > which provides Namerep and Punycode.
    >
    > Any .jar file around that can be used to add this
    > functionality (this class) to JDK 1.5?


    GNU libidn has a Java implementation.

    Arne
    Arne Vajhøj, Jul 26, 2011
    #4
  5. Jan Burse

    Jan Burse Guest

    Arne Vajhøj schrieb:
    > On 7/26/2011 6:24 AM, Jan Burse wrote:
    >> Just noticed that JDK 1.6 has the new class java.net.IDN,
    >> which provides Namerep and Punycode.
    >>
    >> Any .jar file around that can be used to add this
    >> functionality (this class) to JDK 1.5?

    >
    > GNU libidn has a Java implementation.
    >
    > Arne
    >
    >

    http://www.gnu.org/software/libidn/
    They write: A native Java and C# port is included.

    Does it mean the Java lib just calls C? Or is
    it a pure Java implementation? I am thinking
    about bundling the jar with an applet, so when
    it uses some native component then it would be
    problematic.

    There is indeed some sun lib which has for
    example Punycode:

    package sun.net.idn;
    public final class Punycode;

    But using such libraries does not work,
    because for example an Oracle applet does bar
    the package sun.* from use in an applet. One will
    get an exception. Which makes sense, since different
    applet provides might have different internal
    libraries.

    I guess sun.net.idn is old, judging from the change log:
    http://www.docjar.com/html/api/sun/net/idn/Punycode.java.html

    Maybe there is a com.ibm.icu jar?

    Bye
    Jan Burse, Jul 27, 2011
    #5
  6. Jan Burse

    Arne Vajhøj Guest

    On 7/27/2011 3:37 AM, Jan Burse wrote:
    > Arne Vajhøj schrieb:
    >> On 7/26/2011 6:24 AM, Jan Burse wrote:
    >>> Just noticed that JDK 1.6 has the new class java.net.IDN,
    >>> which provides Namerep and Punycode.
    >>>
    >>> Any .jar file around that can be used to add this
    >>> functionality (this class) to JDK 1.5?

    >>
    >> GNU libidn has a Java implementation.


    > http://www.gnu.org/software/libidn/
    > They write: A native Java and C# port is included.
    >
    > Does it mean the Java lib just calls C? Or is
    > it a pure Java implementation? I am thinking
    > about bundling the jar with an applet, so when
    > it uses some native component then it would be
    > problematic.


    I assume that native Java means pure Java.

    > There is indeed some sun lib which has for
    > example Punycode:
    >
    > package sun.net.idn;
    > public final class Punycode;
    >
    > But using such libraries does not work,
    > because for example an Oracle applet does bar
    > the package sun.* from use in an applet. One will
    > get an exception. Which makes sense, since different
    > applet provides might have different internal
    > libraries.
    >
    > I guess sun.net.idn is old, judging from the change log:
    > http://www.docjar.com/html/api/sun/net/idn/Punycode.java.html
    >
    > Maybe there is a com.ibm.icu jar?


    I still think libidn is your best option.

    Arne
    Arne Vajhøj, Jul 28, 2011
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Arnold Peters
    Replies:
    0
    Views:
    551
    Arnold Peters
    Jan 5, 2005
  2. cyberco
    Replies:
    4
    Views:
    3,720
    Roedy Green
    Feb 14, 2006
  3. Dundonald
    Replies:
    8
    Views:
    1,344
    Mike Schilling
    Oct 5, 2007
  4. Hadmut Danisch

    IDN Internation Domain Names?

    Hadmut Danisch, Jul 23, 2005, in forum: Ruby
    Replies:
    3
    Views:
    90
    Dominik Bathon
    Jul 25, 2005
  5. Tuxedo
    Replies:
    1
    Views:
    290
    Tuxedo
    Nov 12, 2012
Loading...

Share This Page