org.opends.server.util.table
Class TabSeparatedTablePrinter

java.lang.Object
  extended by org.opends.server.util.table.TablePrinter
      extended by org.opends.server.util.table.TabSeparatedTablePrinter

public final class TabSeparatedTablePrinter
extends TablePrinter

An interface for creating a tab-separated formatted table.

This table printer will replace any tab, line-feeds, or carriage return control characters encountered in a cell with a single space.


Constructor Summary
TabSeparatedTablePrinter(java.io.OutputStream stream)
          Creates a new tab separated table printer for the specified output stream.
TabSeparatedTablePrinter(java.io.Writer writer)
          Creates a new tab separated table printer for the specified writer.
 
Method Summary
protected  TableSerializer getSerializer()
          Creates a new table serializer based on the configuration of this table printer.
 void setDisplayHeadings(boolean displayHeadings)
          Specify whether or not table headings should be displayed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TabSeparatedTablePrinter

public TabSeparatedTablePrinter(java.io.OutputStream stream)
Creates a new tab separated table printer for the specified output stream. Headings will not be displayed by default.

Parameters:
stream - The stream to output tables to.

TabSeparatedTablePrinter

public TabSeparatedTablePrinter(java.io.Writer writer)
Creates a new tab separated table printer for the specified writer. Headings will not be displayed by default.

Parameters:
writer - The writer to output tables to.
Method Detail

setDisplayHeadings

public void setDisplayHeadings(boolean displayHeadings)
Specify whether or not table headings should be displayed.

Parameters:
displayHeadings - true if table headings should be displayed.

getSerializer

protected TableSerializer getSerializer()
Creates a new table serializer based on the configuration of this table printer.

Specified by:
getSerializer in class TablePrinter
Returns:
Returns a new table serializer based on the configuration of this table printer.