Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.statcvs.renderer
Class XMLRenderer

    java.lang.Object
      net.sf.statcvs.renderer.XMLRenderer

All Implemented Interfaces:
  TableCellRenderer

public class XMLRenderer
extends Object
implements TableCellRenderer

Helper class for rendering different types of table cells and table heads to XML

Version:
  $Id: XMLRenderer.java,v 1.3 2008/04/02 11:22:15 benoitx Exp $
Author:
  Nilendra Weerasinghe

Constructor Summary
`XMLRenderer()`

Method Summary
`String` | `getColumnHead()` Return the results of the last `renderCell` call
`String` | `getEvenRowFormat()`
`String` | `getOddRowFormat()`
`MarkupSyntax` | `getOutput()`
`String` | `getRowHead()` Return the results of the last `renderCell` call as a row head
`String` | `getTableCell()` Return the results of the last `renderCell` call as an ordinary table cell
`void` | `renderAuthorCell(Author author)` Render a cell containing an author to XML
`void` | `renderAuthorIdCell(Author author)` Render a cell containing an author Id
`void` | `renderCell(String content)` Render a generic table cell to XML
`void` | `renderDirectoryCell(Directory directory)` Render a cell containing a directory to XML
`void` | `renderEmptyCell()` Render an empty cell to XML
`void` | `renderFileCell(VersionedFile file, boolean withIcon, WebRepositoryIntegration webRepository)` Render a cell containing a file to XML
`void` | `renderIntegerCell(int value)` Render an integer cell to XML
`void` | `renderIntegerCell(int value, int total)` Render an integer cell to XML, showing both the integer value and a percentage of a total
`void` | `renderLinkCell(String url, String label)` Render a cell containing a repository tag.
`void` | `renderPercentageCell(double ratio)` Render a percentage cell to XML
`void` | `setOutput(MarkupSyntax output)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### XMLRenderer

    public XMLRenderer()

Method Detail

### renderCell

    public void renderCell(String content)

  Render a generic table cell to XML

  Specified by:
    `renderCell` in interface `TableCellRenderer`
  Parameters:
    `content` - the cell's content

### renderEmptyCell

    public void renderEmptyCell()

  Render an empty cell to XML

  Specified by:
    `renderEmptyCell` in interface `TableCellRenderer`

### renderIntegerCell

    public void renderIntegerCell(int value)

  Render an integer cell to XML

  Specified by:
    `renderIntegerCell` in interface `TableCellRenderer`
  Parameters:
    `value` - the cell's content

### renderIntegerCell

    public void renderIntegerCell(int value,
                                  int total)

  Render an integer cell to XML, showing both the integer value and a percentage of a total

  Specified by:
    `renderIntegerCell` in interface `TableCellRenderer`
  Parameters:
    `value` - the cell's content
    `total` - the total, worth 100%

### renderPercentageCell

    public void renderPercentageCell(double ratio)

  Render a percentage cell to XML

  Specified by:
    `renderPercentageCell` in interface `TableCellRenderer`
  Parameters:
    `ratio` - the cell's content

### renderAuthorCell

    public void renderAuthorCell(Author author)

  Render a cell containing an author to XML

  Specified by:
    `renderAuthorCell` in interface `TableCellRenderer`
  Parameters:
    `author` - the author

### renderDirectoryCell

    public void renderDirectoryCell(Directory directory)

  Render a cell containing a directory to XML

  Specified by:
    `renderDirectoryCell` in interface `TableCellRenderer`
  Parameters:
    `directory` - the directory

### renderFileCell

    public void renderFileCell(VersionedFile file,
                               boolean withIcon,
                               WebRepositoryIntegration webRepository)

  Render a cell containing a file to XML

  Specified by:
    `renderFileCell` in interface `TableCellRenderer`
  Parameters:
    `file` - the file
    `withIcon` - display an icon in front of the filename?
    `webRepository` - for creating links; might be `null`

### renderLinkCell

    public void renderLinkCell(String url,
                               String label)

  Render a cell containing a repository tag.

  Specified by:
    `renderLinkCell` in interface `TableCellRenderer`

### getColumnHead

    public String getColumnHead()

  Return the results of the last `renderCell` call

  Returns:
    XML

### getRowHead

    public String getRowHead()

  Return the results of the last `renderCell` call as a row head

  Returns:
    XML

### getTableCell

    public String getTableCell()

  Return the results of the last `renderCell` call as an ordinary table cell

  Returns:
    XML

### getOutput

    public MarkupSyntax getOutput()

  Returns:
    the output

### setOutput

    public void setOutput(MarkupSyntax output)

  Parameters:
    `output` - the output to set

### getOddRowFormat

    public String getOddRowFormat()

### getEvenRowFormat

    public String getEvenRowFormat()

### renderAuthorIdCell

    public void renderAuthorIdCell(Author author)

  Description copied from interface: `TableCellRenderer`
  Render a cell containing an author Id

  Specified by:
    `renderAuthorIdCell` in interface `TableCellRenderer`
  Parameters:
    `author` - the author

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD