Package org.apache.any23.encoding

## Interface EncodingDetector

- All Known Implementing Classes:
    `TikaEncodingDetector`

      public interface EncodingDetector

  Defines a detector for charset encoding.
  Author:
    Michele Mostarda ( michele.mostarda@gmail.com )

- - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `String` | `guessEncoding​(InputStream input)` | Guesses the data encoding.
    `default String` | `guessEncoding​(InputStream input, String contentType)` | Guesses the data encoding.

- - ### Method Detail

    - #### guessEncoding

          String guessEncoding​(InputStream input)
                        throws IOException

      Guesses the data encoding.
      Parameters:
        `input` - the input stream containing the data.
      Returns:
        a string compliant to IANA Charset Specification.
      Throws:
        `IOException` - if there is an error whilst guessing the encoding.

    - #### guessEncoding

          default String guessEncoding​(InputStream input,
                                       String contentType)
                                throws IOException

      Guesses the data encoding.
      Parameters:
        `input` - the input stream containing the data.
        `contentType` - the declared content type of the data.
      Returns:
        a string compliant to IANA Charset Specification.
      Throws:
        `IOException` - if there is an error whilst guessing the encoding.