Set<String> (@NotNull VirtualFile virtualFile) { byte[] bytes; try { bytes = virtualFile.contentsToByteArray(); } catch (IOException e) { return Collections.emptySet(); } DetectResult info = detectInternalCharsetAndSetBOM(virtualFile, bytes, bytes.length, false, virtualFile.getFileType()); byte[] bom = info.BOM; ConvertResult result = convertBytes(bytes, Math.min(bom == null ? 0 : bom.length, bytes.length), bytes.length, info.hardCodedCharset); return result.allLineSeparators(); }