class="java">File file = new File("E:" + File.separator + "index"); FileInputStream fis = new FileInputStream(file); BufferedReader reader = new BufferedReader(new InputStreamReader(fis)); //用这种读取文本文件时,读取每行的第一个字符读取不到 while(reader.readLine() != null){ sb.append(bf.readLine()); } //用这种方式就可以,不知道是是为什么? 如果有知道的请指教下!!!多谢! //for (String line = null; (line = reader.readLine()) != null;) //{ ??????//content.append(line).append("\n"); //??}
?