org.apache.tika.utils
Class CharsetUtils

java.lang.Object
  extended by org.apache.tika.utils.CharsetUtils

public class CharsetUtils
extends java.lang.Object


Constructor Summary
CharsetUtils()
           
 
Method Summary
static java.lang.String clean(java.lang.String charsetName)
          Handle various common charset name errors, and return something that will be considered valid (and is normalized)
static boolean isSupported(java.lang.String charsetName)
          Safely return whether is supported, without throwing exceptions
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CharsetUtils

public CharsetUtils()
Method Detail

isSupported

public static boolean isSupported(java.lang.String charsetName)
Safely return whether is supported, without throwing exceptions

Parameters:
charsetName - Name of charset (can be null)
Returns:
true if the character set is supported

clean

public static java.lang.String clean(java.lang.String charsetName)
Handle various common charset name errors, and return something that will be considered valid (and is normalized)

Parameters:
charsetName - name of charset to process
Returns:
potentially remapped/cleaned up version of charset name


Copyright © 2007-2010 The Apache Software Foundation. All Rights Reserved.