at.dms.compiler
Class TabbedPrintWriter

java.lang.Object
  |
  +--at.dms.compiler.TabbedPrintWriter

public class TabbedPrintWriter
extends java.lang.Object

This class implements a tabbed print writer.


Field Summary
protected  int column
          Current column number.
protected  int line
          Current line numer.
protected  int pos
          Indenting position.
 
Constructor Summary
TabbedPrintWriter(java.io.Writer writer)
          Constructs a tabbed printer writer.
 
Method Summary
 void add(int pos)
          Increment tab.
 void close()
          Close the stream at the end.
 int getColumn()
           
 int getLine()
           
 int getPos()
           
 void print(java.lang.String s)
          Print a string.
 void println()
          Print a new line.
 void setPos(int pos)
          Set pos.
 void sub(int pos)
          Decrement tab.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pos

protected int pos
Indenting position.

line

protected int line
Current line numer.

column

protected int column
Current column number.
Constructor Detail

TabbedPrintWriter

public TabbedPrintWriter(java.io.Writer writer)
Constructs a tabbed printer writer.
Parameters:
fileName - The file into the code is generated.
Method Detail

close

public void close()
Close the stream at the end.

getLine

public int getLine()

getColumn

public int getColumn()

getPos

public int getPos()

setPos

public void setPos(int pos)
Set pos.

add

public void add(int pos)
Increment tab.

sub

public void sub(int pos)
Decrement tab.

println

public void println()
Print a new line.

print

public void print(java.lang.String s)
Print a string.