code: public CharsetMatch[] detectAll() {
          ArrayList<CharsetMatch>         matches = new ArrayList<CharsetMatch>();
          
          MungeInput();  // Strip html markup, collect byte stats.
          
          //  Iterate over all possible charsets, remember all that
          //    give a match quality > 0.
          for (int i = 0; i < ALL_CS_RECOGNIZERS.size(); i++) {
              CSRecognizerInfo rcinfo = ALL_CS_RECOGNIZERS.get(i);
              boolean active = (fEnabledRecognizers != null) ? fEnabledRecognizers[i] : rcinfo.isDefaultEnabled;
              if (active) {
                  CharsetMatch m = rcinfo.recognizer.match(this);
                  if (m != null) {
                      matches.add(m);
                  }
              }
          }
          Collections.sort(matches);      // CharsetMatch compares on confidence
          Collections.reverse(matches);   //  Put best match first.
          CharsetMatch [] resultArray = new CharsetMatch[matches.size()];
          resultArray = matches.toArray(resultArray);
          return resultArray;
      }
docs: Return an array of all charsets that appear to be plausible
  matches with the input data.  The array is ordered with the
  best quality match first.
  <p>
  Raise an exception if
  <ul>
  <li>no charsets appear to match the input data.</li>
  <li>no input text has been provided</li>
  </ul>
  
  @return An array of CharsetMatch objects representing possibly matching charsets.