org.apache.xml.serialize

Class EncodingInfo


public class EncodingInfo
extends java.lang.Object

This class represents an encoding.

Version:
$Id: EncodingInfo.java,v 1.5 2003/11/04 19:24:54 mrglavas Exp $

Constructor Summary

EncodingInfo(String ianaName, String javaName, int lastPrintable)
Creates new EncodingInfo instance.

Method Summary

String
getIANAName()
Returns a MIME charset name of this encoding.
Writer
getWriter(OutputStream output)
Returns a writer for this encoding based on an output stream.
boolean
isPrintable(char ch)
Checks whether the specified character is printable or not in this encoding.
static void
testJavaEncodingName(String name)

Constructor Details

EncodingInfo

public EncodingInfo(String ianaName,
                    String javaName,
                    int lastPrintable)
Creates new EncodingInfo instance.

Method Details

getIANAName

public String getIANAName()
Returns a MIME charset name of this encoding.


getWriter

public Writer getWriter(OutputStream output)
            throws UnsupportedEncodingException
Returns a writer for this encoding based on an output stream.

Returns:
A suitable writer


isPrintable

public boolean isPrintable(char ch)
Checks whether the specified character is printable or not in this encoding.

Parameters:
ch - a code point (0-0x10ffff)


testJavaEncodingName

public static void testJavaEncodingName(String name)
            throws UnsupportedEncodingException


Copyright B) 1999-2004 Apache XML Project. All Rights Reserved.