mjc

org.multijava.dis
Class IndentingWriter

java.lang.Object
  extended byorg.multijava.dis.IndentingWriter

public class IndentingWriter
extends Object

This class allows indented output


Field Summary
private  int level
           
private  PrintWriter out
           
private static String TAB
           
 
Constructor Summary
IndentingWriter(PrintWriter out)
          Creates a new indenting writer.
 
Method Summary
 void decrementLevel()
          Decrements the indentation level.
 void incrementLevel()
          Increments the indentation level.
 void print(int value)
          Prints an integer.
 void print(String value)
          Prints a string.
 void println()
          Terminates the current line by writing the line separator string and moving to the current indentation level.
 void println(String str)
          Prints a string and then terminates the line.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TAB

private static final String TAB

out

private PrintWriter out

level

private int level
Constructor Detail

IndentingWriter

public IndentingWriter(PrintWriter out)
Creates a new indenting writer.

Parameters:
out - the print writer to writer to
Method Detail

incrementLevel

public void incrementLevel()
Increments the indentation level.


decrementLevel

public void decrementLevel()
Decrements the indentation level.


print

public void print(String value)
Prints a string.

Parameters:
value - the string to print

print

public void print(int value)
Prints an integer.

Parameters:
value - the integer to print

println

public void println()
Terminates the current line by writing the line separator string and moving to the current indentation level.


println

public void println(String str)
Prints a string and then terminates the line.

Parameters:
str - the string to print

mjc

mjc is Copyright (C) 2000-2004 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. mjc is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.