java.io.FileReader翻译

王朝java/jsp·作者佚名  2006-01-10
窄屏简体版  字體: |||超大  

[/url] [url=file:///F:/资料/文字资料/j2sdk-1_4_2-doc/docs/api/overview-summary.html]Overview

Package

Class

Use

Tree

Deprecated

Index

Help

JavaTM 2 Platform

Std. Ed. v1.4.2

PREV CLASS NEXT CLASS

FRAMES NO FRAMES All Classes

SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

java.io

Class FileReaderjava.lang.Object

java.io.Reader

java.io.InputStreamReader

java.io.FileReader

public class FileReader extends InputStreamReaderConvenience class for reading character files. The constructors of this class assume that the default character encoding and the default byte-buffer size are appropriate. To specify these values yourself, construct an InputStreamReader on a FileInputStream. 读取字符文件的工具类。该类的构造函数假定默认的字符编码和默认的字节缓冲大小是合适的。如果自己要指定这些值,应该基于FileInputStream构造一个InputStreamReader。

FileReader is meant for reading streams of characters. For reading streams of raw bytes, consider using a FileInputStream. FileReader是读取字符流的工具。如果读取字节流,应该考虑采用FileInputStream。

Since: JDK1.1 See Also: InputStreamReader, FileInputStreamField Summary

Fields inherited from class java.io.Reader

lock

Constructor Summary

FileReader(File file)

Creates a new FileReader, given the File to read from. 创建一个FileReader,给定要读取的File。

FileReader(FileDescriptor fd)

Creates a new FileReader, given the FileDescriptor to read from. 创建一个FileReader,给定要读取的FileDescriptor。

FileReader(String fileName)

Creates a new FileReader, given the name of the file to read from. 创建一个FileReader,给定要读取的文件名称。

Methods inherited from class java.io.InputStreamReader

close, getEncoding, read, ,]read, ready

Methods inherited from class java.io.Reader

mark, markSupported, )]read, reset, skip

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

FileReaderpublic FileReader(String fileName)

throws FileNotFoundException

Creates a new FileReader, given the name of the file to read from. 创建一个FileReader,给定要读取的文件名称。

Parameters: fileName - the name of the file to read from 要读取的文件名称 Throws: FileNotFoundException - if the named file does not exist, is a directory rather than a regular file, or for some other reason cannot be opened for reading. 如果该名称的文件不存在,或者是目录而不是常规文件,或者其他原因不能打开,则抛出。FileReaderpublic FileReader(File file)

throws FileNotFoundException

Creates a new FileReader, given the File to read from. 创建一个FileReader,给定要读取的File。

Parameters: file - the File to read from 要读取的File Throws: FileNotFoundException - if the file does not exist, is a directory rather than a regular file, or for some other reason cannot be opened for reading. 如果该文件不存在,或者是目录而不是常规文件,或者其他原因不能打开,则抛出。FileReaderpublic FileReader(FileDescriptor fd)

Creates a new FileReader, given the FileDescriptor to read from. 创建一个FileReader,给定要读取的FileDescriptor。

Parameters: fd - the FileDescriptor to read from 要读取的FileDescriptor[/url][url=file:///F:/资料/文字资料/j2sdk-1_4_2-doc/docs/api/overview-summary.html]Overview

Package

Class

Use

Tree

Deprecated

Index

Help

JavaTM 2 Platform

Std. Ed. v1.4.2

PREV CLASS NEXT CLASS

FRAMES NO FRAMES All Classes

SUMMARY: NESTED | FIELD | CONSTR | METHOD

DETAIL: FIELD | CONSTR | METHOD

Submit a bug or feature

For further API reference and developer documentation, see Java 2 SDK SE Developer Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples. Copyright 2003 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
 
 
© 2005- 王朝網路 版權所有 導航