Interface ListGridCellFormatter

All Known Subinterfaces:
ListGridCellFormatterCustomFormat
All Known Implementing Classes:
ListGridBooleanFormatter, ListGridDateFormatter, ListGridDateTimeFormatter, ListGridNumberFormatter

public interface ListGridCellFormatter

Display value formatter interface for ListGrid.

The format(Object) method must be implemented along with the interface implementation. The method receives the value to be formatted in the parameter and must return a text value representing the formatted value. The returned text value is displayed in the grid.

The framework includes some basic formatter classes. These formatter classes may be used for building a custom formatter, but also in a grid column. The framework’s basic formatter classes are the following:

See individual formatter class descriptions for more details.

Since:
4.0
Author:
JBStrap
  • Method Summary

    Modifier and Type
    Method
    Description
    format(Object data)
    Formats a value to the displayed format.
  • Method Details

    • format

      String format(Object data)
      Formats a value to the displayed format.
      Parameters:
      data - The value to be formatted The object passed here is the value retrieved from the database and displayed in the column by the ListGrid component. The received value is passed using the same type as it was fetched from the database.
      Returns:
      Displayed value in text format The returned text value may contain HTML tags which are rendered. If the return value is null, no value is displayed in the current cell.