Devsphere.com


com.devsphere.xml.taglib.support.builder
Class Outputter

java.lang.Object
  |
  +--com.devsphere.xml.taglib.support.builder.Outputter

public class Outputter
extends java.lang.Object

Class used for indented output.


Field Summary
static java.lang.String INDENT_STRING
           
 
Constructor Summary
Outputter(java.io.PrintWriter writer)
          Initializes this object setting the indent level to 0.
 
Method Summary
 void close()
          Closes the writer
 void decLevel()
          Decrements the indent level.
 int getLevel()
          Gets the indent level.
 void incLevel()
          Increments the indent level.
 void println()
          Prints a blank line.
 void println(java.lang.String line)
          Outputs the given string
 void setLevel(int indentLevel)
          Sets the indent level.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INDENT_STRING

public static final java.lang.String INDENT_STRING
See Also:
Constant Field Values
Constructor Detail

Outputter

public Outputter(java.io.PrintWriter writer)
Initializes this object setting the indent level to 0.

Parameters:
writer - the java.io.PrintWriter used for output
Method Detail

setLevel

public void setLevel(int indentLevel)
Sets the indent level.

Parameters:
indentLevel - the new indent level.

getLevel

public int getLevel()
Gets the indent level.

Returns:
the indent level

incLevel

public void incLevel()
Increments the indent level.


decLevel

public void decLevel()
Decrements the indent level.


println

public void println()
Prints a blank line.


println

public void println(java.lang.String line)
Outputs the given string

Parameters:
line - the string that must be printed

close

public void close()
Closes the writer


 Devsphere.com