Closeable, Serializable, AutoCloseablepublic class IFSTextFileInputStream extends IFSFileInputStream implements Serializable
IFSFileReader.
The following example illustrates the use of IFSTextFileInputStream:
// Work with /File on the system eniac.
AS400 as400 = new AS400("eniac");
IFSTextFileInputStream file = new IFSTextFileInputStream(as400, "/File");
// Read the first four characters of the file.
String s = file.read(4);
// Display the characters read.
System.out.println(s);
// Close the file.
file.close();
fd_, SHARE_ALL, SHARE_NONE, SHARE_READERS, SHARE_WRITERS| Constructor | Description |
|---|---|
IFSTextFileInputStream() |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(AS400 system,
IFSFile file,
int shareOption) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(AS400 system,
IFSJavaFile file,
int shareOption) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(AS400 system,
String name) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(AS400 system,
String name,
int shareOption) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(IFSFile file) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(IFSFileDescriptor fd) |
Constructs an IFSTextFileInputStream object.
|
IFSTextFileInputStream(IFSJavaFile file) |
Constructs an IFSTextFileInputStream object.
|
| Modifier and Type | Method | Description |
|---|---|---|
String |
read(int length) |
Reads up to length characters from this text file input stream.
|
addFileListener, addPropertyChangeListener, addVetoableChangeListener, available, close, finalize, getFD, getPath, getShareOption, getSystem, lock, lock, open, read, read, read, removeFileListener, removePropertyChangeListener, removeVetoableChangeListener, reset, rewind, setFD, setPath, setShareOption, setSystem, skip, unlockmark, markSupported, nullInputStream, readAllBytes, readNBytes, readNBytes, transferTopublic IFSTextFileInputStream()
public IFSTextFileInputStream(AS400 system, String name) throws AS400SecurityException, IOException
system - The AS400 that contains the file.name - The integrated file system name.AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(AS400 system, String name, int shareOption) throws AS400SecurityException, IOException
system - The AS400 that contains the file.name - The integrated file system name.shareOption - Indicates how users can access the file. AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(IFSFile file) throws AS400SecurityException, IOException
file - The file to be opened for reading.AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(AS400 system, IFSFile file, int shareOption) throws AS400SecurityException, IOException
system - The AS400 that contains the file.file - The file to be opened for reading.shareOption - Indicates how users can access the file. AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(IFSJavaFile file) throws AS400SecurityException, IOException
file - The file to be opened for reading.AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(AS400 system, IFSJavaFile file, int shareOption) throws AS400SecurityException, IOException
system - The AS400 that contains the file.file - The file to be opened for reading.shareOption - Indicates how users can access the file. AS400SecurityException - If a security or authority error occurs.IOException - If an error occurs while communicating with the system.public IFSTextFileInputStream(IFSFileDescriptor fd)
fd - The file descriptor to be opened for reading.public String read(int length) throws IOException
length - The number of characters to read from the stream.IOException - If an error occurs while communicating with the system.Copyright © 2024. All rights reserved.