-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Character set detection using Mozilla's Universal Character Set Detector
--   
--   Mozilla have developed a robust and efficient character set detection
--   algorithm for use in their web browsers. The algorithm is able to
--   detect all of the most frequently encountered character encodings
--   totally automatically.
--   
--   This library wraps up their library and exposes a very simple Haskell
--   interface to it. The library is portable, and is confirmed to work on
--   both Unix and Windows.
--   
--   This library is a <i>maintained</i> fork of charsetdetect:
--   
--   <ul>
--   <li>It compiles with recent version of bytestring.</li>
--   <li>It works correctly in presence of Template Haskell on GHC
--   7.6.</li>
--   <li>It builds on 64-bit Windows.</li>
--   </ul>
@package charsetdetect-ae
@version 1.1.0.3


-- | Detect the likely character encoding for a stream of bytes using
--   Mozilla's Universal Character Set Detector.
module Codec.Text.Detect

-- | Detect the likely encoding used by a <a>ByteString</a>. At the time of
--   writing, the encoding returned will be drawn from this list:
--   
--   <pre>
--   Big5
--   EUC-JP
--   EUC-KR
--   gb18030
--   HZ-GB-2312
--   IBM855
--   IBM866
--   ISO-2022-CN
--   ISO-2022-JP
--   ISO-2022-KR
--   ISO-8859-2
--   ISO-8859-5
--   ISO-8859-7
--   ISO-8859-8
--   KOI8-R
--   Shift_JIS
--   TIS-620
--   UTF-8
--   UTF-16BE
--   UTF-16LE
--   UTF-32BE
--   UTF-32LE
--   windows-1250
--   windows-1251
--   windows-1252
--   windows-1253
--   windows-1255
--   x-euc-tw
--   X-ISO-10646-UCS-4-2143
--   X-ISO-10646-UCS-4-3412
--   x-mac-cyrillic
--   </pre>
detectEncodingName :: ByteString -> Maybe String

-- | Detect the encoding for a <a>ByteString</a> and attempt to create a
--   <a>TextEncoding</a> suitable for decoding it.
detectEncoding :: ByteString -> IO (Maybe TextEncoding)
