| java.lang.Object org.makumba.commons.formatters.FieldFormatter
All known Subclasses: org.makumba.forms.html.FieldEditor, org.makumba.commons.formatters.ptrFormatter, org.makumba.commons.formatters.intEnumFormatter, org.makumba.list.html.FieldViewer, org.makumba.commons.formatters.dateFormatter,
FieldFormatter | public class FieldFormatter (Code) | | Formats a specific field. Subclasses of this class are handling the different kind of fields.
author: Cristian Bogdan author: Stefan Baebler author: Frederik Habilis author: Rudolf Mayer |
Method Summary | |
public void | checkParam(RecordFormatter rf, int fieldIndex, String name, String val) | public void | checkParams(RecordFormatter rf, int fieldIndex, Dictionary formatParams) | public boolean | equals(String s1, String s2) | public String | format(RecordFormatter rf, int fieldIndex, Object o, Dictionary formatParams) Format the object to pure text. | public String | formatNotNull(RecordFormatter rf, int fieldIndex, Object o, Dictionary formatParams) Formats the not-null-object to pure text. | public String | formatNull(RecordFormatter rf, int fieldIndex, Dictionary formatParams) Format the null-object to pure text. | public String[] | getAcceptedParams() | public String[][] | getAcceptedValue() | public String | getDefaultValueFormat(RecordFormatter rf, int fieldIndex, Dictionary formatParams) Gets the formatted default value, used if real value is null. | public String | getEmptyValueFormat(RecordFormatter rf, int fieldIndex, Dictionary formatParams) Gets the formatted empty value, used if real value is empty. | public String | getExpr(RecordFormatter rf, int fieldIndex) | public static FieldFormatter | getInstance() | public int | getIntParam(RecordFormatter rf, int fieldIndex, Dictionary formatParams, String name) | public String | getIntParamString(RecordFormatter rf, int fieldIndex, Dictionary formatParams, String name) | public void | initExpr(RecordFormatter rf, int fieldIndex, String s) | public String | resetValueFormat(RecordFormatter rf, int fieldIndex, String s, Dictionary formatParams) Chooses between the real (formatted) value and possible replacements (default, empty). |
FieldFormatter | protected FieldFormatter()(Code) | | Don't use this, use getInstance()
|
format | public String format(RecordFormatter rf, int fieldIndex, Object o, Dictionary formatParams)(Code) | | Format the object to pure text. If text-format is blank, try the "empty" replacer value.
Parameters: rf - TODO Parameters: fieldIndex - TODO |
formatNull | public String formatNull(RecordFormatter rf, int fieldIndex, Dictionary formatParams)(Code) | | Format the null-object to pure text. Try the "default" format parameter.
Parameters: rf - TODO Parameters: fieldIndex - TODO |
getDefaultValueFormat | public String getDefaultValueFormat(RecordFormatter rf, int fieldIndex, Dictionary formatParams)(Code) | | Gets the formatted default value, used if real value is null. Returns blank if not set.
|
getEmptyValueFormat | public String getEmptyValueFormat(RecordFormatter rf, int fieldIndex, Dictionary formatParams)(Code) | | Gets the formatted empty value, used if real value is empty. Returns blank if not set.
|
|
|