Class PrintWriter

Template output stream writer.

Printwriter is available in the template scripting context and is used to write data into the template output stream. You cannot instantiate this class directly. Instead, the system assigns the object to variable named ‘out’ in the script context to be used by the template scripts.

Note: when this class is used with sensitive data, be careful in persisting sensitive information to disk.

Constructor Summary 

This class does not have a constructor, so you cannot create it directly.

Method Summary 

MethodDescription
print(String)Prints the given string into the output stream.
println()Prints a line break into the output stream.
println(String)Print the given string followed by a line break into the output stream.

Methods inherited from class Writer 

close, flush, write, write

Methods inherited from class Object 

assign, create, create, defineProperties, defineProperty, entries, freeze, fromEntries, getOwnPropertyDescriptor, getOwnPropertyNames, getOwnPropertySymbols, getPrototypeOf, hasOwnProperty, is, isExtensible, isFrozen, isPrototypeOf, isSealed, keys, preventExtensions, propertyIsEnumerable, seal, setPrototypeOf, toLocaleString, toString, valueOf, values

Method Details 

print(String) 

print(str: String): void

Prints the given string into the output stream.

Parameters:

  • str - the String object

println() 

println(): void

Prints a line break into the output stream.


println(String) 

println(str: String): void

Print the given string followed by a line break into the output stream.

Parameters:

  • str - the String object

DID THIS ARTICLE SOLVE YOUR ISSUE?
Let us know so we can improve!