public class IDNA extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
ACE_PREFIX |
| Constructor and Description |
|---|
IDNA() |
| Modifier and Type | Method and Description |
|---|---|
static String |
toASCII(String input)
Converts a Unicode string to ASCII using the procedure in RFC3490
section 4.1.
|
static String |
toASCII(String input,
boolean allowUnassigned,
boolean useSTD3ASCIIRules)
Converts a Unicode string to ASCII using the procedure in RFC3490
section 4.1.
|
static String |
toUnicode(String input)
Converts an ASCII-encoded string to Unicode.
|
static String |
toUnicode(String input,
boolean allowUnassigned,
boolean useSTD3ASCIIRules)
Converts an ASCII-encoded string to Unicode.
|
public static final String ACE_PREFIX
public static String toASCII(String input) throws IDNAException
input - Unicode string.IDNAExceptionpublic static String toASCII(String input, boolean allowUnassigned, boolean useSTD3ASCIIRules) throws IDNAException
input - Unicode string.allowUnassigned - Unassigned characters, allowed or not?useSTD3ASCIIRules - STD3 ASCII rules, enforced or not?IDNAExceptionpublic static String toUnicode(String input)
input - ASCII input string.public static String toUnicode(String input, boolean allowUnassigned, boolean useSTD3ASCIIRules)
input - ASCII input string.allowUnassigned - Allow unassigned Unicode characters.useSTD3ASCIIRules - Check that the output conforms to STD3.Copyright © 2022 "Tigase, Inc.". All rights reserved.