Java StringWriter class is a character stream that collects output from string buffer, which can be used to construct a string. The StringWriter class inherits the Writer class.
In StringWriter class, system resources like network sockets and files are not used, therefore closing the StringWriter is not necessary.
public class StringWriter extends Writer
It is used to write the single character.
It is used to write the string.
It is used to write the portion of a string.
It is used to write the portion of an array of characters.
It is used to return the buffer current value as a string.
It is used t return the string buffer.
It is used to append the specified character to the writer.
A11 Acharya Niketan
Mayur Vihar 1
Near MayurVihar Metro Station