| java.lang.Object org.apache.xml.serializer.Encodings
Encodings | final public class Encodings extends Object (Code) | | Provides information about encodings. Depends on the Java runtime
to provides writers for the different encodings.
This class is only for internal use within Xalan. However, it is used directly
by org.apache.xalan.xsltc.compiler.Output.
|
Method Summary | |
public static String | convertMime2JavaEncoding(String encoding) Try the best we can to convert a Java encoding to a XML-style encoding.
This is not a public API.
Parameters: encoding - non-null reference to encoding string, java style. | static EncodingInfo | getEncodingInfo(String encoding) Returns the EncodingInfo object for the specified
encoding. | static String | getMimeEncoding(String encoding) Get the proper mime encoding. | static Writer | getWriter(OutputStream output, String encoding) Returns a writer for the specified encoding based on
an output stream. | static boolean | isHighUTF16Surrogate(char ch) Return true if the character is the high member of a surrogate pair. | static boolean | isLowUTF16Surrogate(char ch) Return true if the character is the low member of a surrogate pair. | static int | toCodePoint(char highSurrogate, char lowSurrogate) Return the unicode code point represented by the high/low surrogate pair. | static int | toCodePoint(char ch) Return the unicode code point represented by the char. |
DEFAULT_MIME_ENCODING | final static String DEFAULT_MIME_ENCODING(Code) | | The default encoding, ISO style, ISO style.
|
convertMime2JavaEncoding | public static String convertMime2JavaEncoding(String encoding)(Code) | | Try the best we can to convert a Java encoding to a XML-style encoding.
This is not a public API.
Parameters: encoding - non-null reference to encoding string, java style. ISO-style encoding string. |
getEncodingInfo | static EncodingInfo getEncodingInfo(String encoding)(Code) | | Returns the EncodingInfo object for the specified
encoding.
This is not a public API.
Parameters: encoding - The encoding The object that is used to determine if characters are in the given encoding. |
getMimeEncoding | static String getMimeEncoding(String encoding)(Code) | | Get the proper mime encoding. From the XSLT recommendation: "The encoding
attribute specifies the preferred encoding to use for outputting the result
tree. XSLT processors are required to respect values of UTF-8 and UTF-16.
For other values, if the XSLT processor does not support the specified
encoding it may signal an error; if it does not signal an error it should
use UTF-8 or UTF-16 instead. The XSLT processor must not use an encoding
whose name does not match the EncName production of the XML Recommendation
[XML]. If no encoding attribute is specified, then the XSLT processor should
use either UTF-8 or UTF-16."
This is not a public API.
Parameters: encoding - Reference to java-style encoding string, which may be null,in which case a default will be found. The ISO-style encoding string, or null if failure. |
isHighUTF16Surrogate | static boolean isHighUTF16Surrogate(char ch)(Code) | | Return true if the character is the high member of a surrogate pair.
This is not a public API.
Parameters: ch - the character to test |
isLowUTF16Surrogate | static boolean isLowUTF16Surrogate(char ch)(Code) | | Return true if the character is the low member of a surrogate pair.
This is not a public API.
Parameters: ch - the character to test |
toCodePoint | static int toCodePoint(char highSurrogate, char lowSurrogate)(Code) | | Return the unicode code point represented by the high/low surrogate pair.
This is not a public API.
Parameters: highSurrogate - the high char of the high/low pair Parameters: lowSurrogate - the low char of the high/low pair |
toCodePoint | static int toCodePoint(char ch)(Code) | | Return the unicode code point represented by the char.
A bit of a dummy method, since all it does is return the char,
but as an int value.
This is not a public API.
Parameters: ch - the char. |
|
|