|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.OutputStream
info1.TextOutputStream
Constructor Summary | |
TextOutputStream(java.lang.String s)
Constructs a text output stream that sends its output to a file |
Method Summary | |
void |
close()
Closes the stream |
boolean |
fail()
Tests if the output stream is no longer valid |
void |
print(char c)
Prints a character to a stream |
void |
print(double x)
Prints a double precision floating point number to a stream |
void |
print(long l)
Prints a long integer to a stream |
void |
print(java.lang.Object o)
Prints an object to a stream. |
void |
print(java.lang.String s)
Prints a string to a stream |
void |
printf(java.lang.String fmt,
char x)
Prints a character to a stream, with formatting instructions |
void |
printf(java.lang.String fmt,
double x)
Prints a double precision floating point number to a stream, with formatting instructions |
void |
printf(java.lang.String fmt,
long x)
Prints a long integer to a stream, with formatting instructions |
void |
printf(java.lang.String fmt,
java.lang.String x)
Prints a string to a stream, with formatting instructions |
void |
println()
Prints a newline |
void |
println(char c)
Prints a character to a stream, followed by a newline |
void |
println(double x)
Prints a double precision floating point number to a stream, followed by a newline |
void |
println(long l)
Prints a long integer to a stream, followed by a newline |
void |
println(java.lang.Object o)
Prints an object to a stream, followed by a newline. |
void |
println(java.lang.String s)
Prints a string to a stream, followed by a newline |
void |
write(int b)
Writes one byte to the stream |
Methods inherited from class java.io.OutputStream |
flush, write, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TextOutputStream(java.lang.String s)
s
- the file nameMethod Detail |
public boolean fail()
public void close()
public void write(int b)
b
- the byte to writepublic void print(java.lang.String s)
s
- the string to printpublic void print(char c)
c
- the character to printpublic void print(java.lang.Object o)
o
- the object to printpublic void print(long l)
l
- the number to printpublic void print(double x)
public void println(java.lang.String s)
s
- the string to printpublic void println(char c)
c
- the character to printpublic void println(java.lang.Object o)
o
- the object to printpublic void println(long l)
l
- the number to printpublic void println(double x)
public void println()
public void printf(java.lang.String fmt, double x)
fmt
- the formatting instruction string.
The string has a prefix, a format code and a suffix. The prefix and suffix
become part of the formatted output. The format code directs the
formatting of the parameter to be formatted. The code has the
following structure
public void printf(java.lang.String fmt, long x)
fmt
- the formatting instruction string.
The string has a prefix, a format code and a suffix. The prefix and suffix
become part of the formatted output. The format code directs the
formatting of the parameter to be formatted. The code has the
following structure
x
- the number to printpublic void printf(java.lang.String fmt, char x)
fmt
- the formatting instruction string.
The string has a prefix, a format code and a suffix. The prefix and suffix
become part of the formatted output. The format code directs the
formatting of the parameter to be formatted. The code has the
following structure
x
- the character to printpublic void printf(java.lang.String fmt, java.lang.String x)
fmt
- the formatting instruction string.
The string has a prefix, a format code and a suffix. The prefix and suffix
become part of the formatted output. The format code directs the
formatting of the parameter to be formatted. The code has the
following structure
x
- the character to print
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |