}
private int calculateSupportedOptions(int result, InputStream contents, IContentDescription description) throws IOException {
int returnResult = result;
if (isRelevent(description)) {
IResourceCharsetDetector detector = getDetector();
contents.reset();
detector.set(contents);
returnResult = handleCalculations(result, description, detector);
}
return returnResult;
}