deegree-core-3.0-pre-nightly (2010/03/05 00:01) - official

org.deegree.commons.utils
Class EncodingGuesser

java.lang.Object
  extended by org.deegree.commons.utils.EncodingGuesser

public class EncodingGuesser
extends Object

EncodingGuesser

Version:
$Revision: 18171 $, $Date: 2009-06-17 16:00:07 +0200 (Mi, 17 Jun 2009) $
Author:
Andreas Schmitz, last edited by: $Author: mschneider $

Constructor Summary
EncodingGuesser()
           
 
Method Summary
static Charset guess(byte[] bs)
           
static Charset guess(InputStream in)
           
static Charset guess(Map<Integer,Integer> map)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EncodingGuesser

public EncodingGuesser()
Method Detail

guess

public static Charset guess(Map<Integer,Integer> map)
                     throws UnsupportedEncodingException
Parameters:
map -
Returns:
the guessed charset, or null
Throws:
UnsupportedEncodingException - if you don't have i18n.jar from Sun's JDK, I guess

guess

public static Charset guess(InputStream in)
                     throws IOException
Parameters:
in -
Returns:
the guessed encoding, or null, if none was determined
Throws:
IOException
UnsupportedEncodingException - if you don't have i18n.jar from Sun's JDK, I guess

guess

public static Charset guess(byte[] bs)
                     throws UnsupportedEncodingException
Parameters:
bs -
Returns:
the guessed encoding, or null
Throws:
UnsupportedEncodingException - if you don't have i18n.jar from Sun's JDK, I guess

deegree-core-3.0-pre-nightly (2010/03/05 00:01) - official

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org

]]>