java的几个问题

[复制链接]
查看11 | 回复1 | 2011-5-4 09:57:29 | 显示全部楼层 |阅读模式
1what is file?
2what are different types of file?
3what is java.io?
4what is the difference between file and database?
5.how to read from a file?what are different steps to read a file?
6.what are the classes used to read a file?
7.how to write tofile?what are different steps to write in file?
8.what are the exceptions that will occur while doing file handling?
急求

回复

使用道具 举报

千问 | 2011-5-4 09:57:29 | 显示全部楼层
1,文件2,文件类型。如TXT等3,java.io为java基础类库中很重要的包,流的相关类和流的处理都在这个包里面4,文件和数据库,其实数据库可以理解成文件系统中的一部分,因为数据库也是通过文件形式保存的,只不过它是有一套保存数据的规则和管理功能。5,File file = new File("文件路径"); StringBuffer contents = new StringBuffer(); BufferedReader reader = null;
reader = new BufferedReader(new FileReader(file)); String text = null;
w
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行