private static @Nullable String getEncodingName(Iterable<String> options) {
    for (Iterator<String> it = options.iterator(); it.hasNext(); ) {
      final String option = it.next();
      if ("-encoding".equals(option)) {
        return it.hasNext()? it.next() : null;
      }
    }
    return null;
  }
private static @Nullable String getEncodingName(Iterable<String> options)