Java java.io PrintStream fields, constructors, methods, implement or subclass

Example usage for Java java.io PrintStream fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for java.io PrintStream.

The text is from its open source code.

Subclass

java.io.PrintStream has subclasses.
Click this link to see all its subclasses.

Constructor

PrintStream(OutputStream out)
Creates a new print stream.
PrintStream(String fileName)
Creates a new print stream, without automatic line flushing, with the specified file name.
PrintStream(File file)
Creates a new print stream, without automatic line flushing, with the specified file.
PrintStream(boolean autoFlush, OutputStream out)
PrintStream(OutputStream out, boolean autoFlush)
Creates a new print stream.
PrintStream(String fileName, String csn)
Creates a new print stream, without automatic line flushing, with the specified file name and charset.
PrintStream(String fileName, Charset charset)
Creates a new print stream, without automatic line flushing, with the specified file name and charset.
PrintStream(File file, String csn)
Creates a new print stream, without automatic line flushing, with the specified file and charset.
PrintStream(File file, Charset charset)
Creates a new print stream, without automatic line flushing, with the specified file and charset.
PrintStream(boolean autoFlush, Charset charset, OutputStream out)
PrintStream(OutputStream out, boolean autoFlush, String encoding)
Creates a new print stream.
PrintStream(OutputStream out, boolean autoFlush, Charset charset)
Creates a new print stream, with the specified OutputStream, automatic line flushing and charset.

Method

PrintStreamappend(CharSequence csq)
Appends the specified character sequence to this output stream.
PrintStreamappend(char c)
Appends the specified character to this output stream.
PrintStreamappend(CharSequence csq, int start, int end)
Appends a subsequence of the specified character sequence to this output stream.
booleancheckError()
Flushes the stream and checks its error state.
voidclose()
Closes the stream.
voidflush()
Flushes the stream.
PrintStreamformat(String format, Object... args)
Writes a formatted string to this output stream using the specified format string and arguments.
PrintStreamformat(Locale l, String format, Object... args)
Writes a formatted string to this output stream using the specified format string and arguments.
ClassgetClass()
Returns the runtime class of this Object .
voidprint(boolean b)
Prints a boolean value.
voidprint(char c)
Prints a character.
voidprint(int i)
Prints an integer.
voidprint(long l)
Prints a long integer.
voidprint(float f)
Prints a floating-point number.
voidprint(double d)
Prints a double-precision floating-point number.
voidprint(char s[])
Prints an array of characters.
voidprint(String s)
Prints a string.
voidprint(Object obj)
Prints an object.
PrintStreamprintf(String format, Object... args)
A convenience method to write a formatted string to this output stream using the specified format string and arguments.
PrintStreamprintf(Locale l, String format, Object... args)
A convenience method to write a formatted string to this output stream using the specified format string and arguments.
voidprintln(boolean x)
Prints a boolean and then terminate the line.
voidprintln(char x)
Prints a character and then terminate the line.
voidprintln(int x)
Prints an integer and then terminate the line.
voidprintln(long x)
Prints a long and then terminate the line.
voidprintln(float x)
Prints a float and then terminate the line.
voidprintln(double x)
Prints a double and then terminate the line.
voidprintln(char[] x)
Prints an array of characters and then terminate the line.
voidprintln(String x)
Prints a String and then terminate the line.
voidprintln(Object x)
Prints an Object and then terminate the line.
voidprintln()
Terminates the current line by writing the line separator string.
StringtoString()
Returns a string representation of the object.
voidwrite(byte buf[], int off, int len)
Writes len bytes from the specified byte array starting at offset off to this stream.
voidwrite(int b)
Writes the specified byte to this stream.
voidwrite(char[] buf)
voidwrite(String s)