org.archive.wayback.replay.charset
Class StandardCharsetDetector

java.lang.Object
  extended by org.archive.wayback.replay.charset.CharsetDetector
      extended by org.archive.wayback.replay.charset.StandardCharsetDetector

public class StandardCharsetDetector
extends CharsetDetector


Field Summary
 
Fields inherited from class org.archive.wayback.replay.charset.CharsetDetector
CHARSET_TOKEN, DEFAULT_CHARSET, HTTP_CONTENT_TYPE_HEADER, MAX_CHARSET_READAHEAD
 
Constructor Summary
StandardCharsetDetector()
           
 
Method Summary
 String getCharset(Resource resource, WaybackRequest request)
           
 
Methods inherited from class org.archive.wayback.replay.charset.CharsetDetector
contentTypeToCharset, getCharsetFromBytes, getCharsetFromHeaders, getCharsetFromMeta, isCharsetSupported, mapCharset
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StandardCharsetDetector

public StandardCharsetDetector()
Method Detail

getCharset

public String getCharset(Resource resource,
                         WaybackRequest request)
                  throws IOException
Specified by:
getCharset in class CharsetDetector
Parameters:
resource - (presumably text) Resource to determine the charset
request - WaybackRequest which may contain additional hints to processing
Returns:
String charset name for the Resource
Throws:
IOException - if there are problems reading the Resource


Copyright © 2005-2011 Internet Archive. All Rights Reserved.