|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.makumba.commons.formatters.FieldFormatter
org.makumba.forms.html.FieldEditor
org.makumba.forms.html.choiceEditor
public abstract class choiceEditor
Field Summary | |
---|---|
(package private) static String[] |
_params
|
(package private) static String[][] |
_paramValues
|
protected String |
nullOption
|
Fields inherited from class org.makumba.forms.html.FieldEditor |
---|
ERROR_NO_BOOLEAN, ERROR_NO_INT, ERROR_NO_REAL, extraFormattingParam, formName, params, paramValues, suffixName |
Constructor Summary | |
---|---|
choiceEditor()
|
Method Summary | |
---|---|
String |
format(RecordFormatter rf,
int fieldIndex,
Object o,
Dictionary<String,Object> formatParams)
Format the object to pure text. |
abstract String |
formatOptionTitle(RecordFormatter rf,
int fieldIndex,
Object options,
int i)
Gets the title/label of option 'i'. |
abstract String |
formatOptionValue(RecordFormatter rf,
int fieldIndex,
Object val)
Formats an option value. |
abstract String |
formatOptionValue(RecordFormatter rf,
int fieldIndex,
Object opts,
int i,
Object val)
Formats an option value, in the sequence of options. |
String[] |
getAcceptedParams()
|
String[][] |
getAcceptedValue()
|
abstract int |
getDefaultSize(RecordFormatter rf,
int fieldIndex)
Gets the default size of the select HTML box. |
abstract Object |
getOptions(RecordFormatter rf,
int fieldIndex,
Dictionary<String,Object> formatParams)
Get the available options. |
abstract int |
getOptionsLength(RecordFormatter rf,
int fieldIndex,
Object opts)
Gets the number of available options. |
abstract Object |
getOptionValue(RecordFormatter rf,
int fieldIndex,
Object options,
int i)
Gets the value of option 'i'. |
Object |
getValueOrDefault(RecordFormatter rf,
int fieldIndex,
Object o,
Dictionary<String,Object> formatParams)
Return value if not null, or finds the default option and returns it as a Vector. |
abstract boolean |
isMultiple(RecordFormatter rf,
int fieldIndex)
Returns blank string, or " multiple " if multiple selections possible. |
void |
setNullOption(Object nullOption)
Sets the value of the null option from the mak:input tag. |
boolean |
shouldRemoveNullValue(RecordFormatter rf,
int fieldIndex)
Null values are ignored |
Methods inherited from class org.makumba.forms.html.FieldEditor |
---|
checkParam, formatHidden, formatHiddenValue, formatShow, formatValue, getExtraFormatting, getInputID, getInputName, getInputName, getInstance, getSuffix, onStartup, readFrom, readFrom, setExtraFormatting, setFormName, setSuffix, toInt, toReal |
Methods inherited from class org.makumba.commons.formatters.FieldFormatter |
---|
checkParams, equals, formatNotNull, formatNull, getDefaultValueFormat, getEmptyValueFormat, getExpr, getIntParam, getIntParamString, initExpr, resetValueFormat |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
static String[] _params
static String[][] _paramValues
protected String nullOption
Constructor Detail |
---|
public choiceEditor()
Method Detail |
---|
public String[] getAcceptedParams()
getAcceptedParams
in class FieldEditor
public String[][] getAcceptedValue()
getAcceptedValue
in class FieldEditor
public abstract Object getOptions(RecordFormatter rf, int fieldIndex, Dictionary<String,Object> formatParams)
public abstract int getOptionsLength(RecordFormatter rf, int fieldIndex, Object opts)
public abstract Object getOptionValue(RecordFormatter rf, int fieldIndex, Object options, int i)
public abstract String formatOptionTitle(RecordFormatter rf, int fieldIndex, Object options, int i)
public abstract String formatOptionValue(RecordFormatter rf, int fieldIndex, Object opts, int i, Object val)
public abstract String formatOptionValue(RecordFormatter rf, int fieldIndex, Object val)
public abstract boolean isMultiple(RecordFormatter rf, int fieldIndex)
public abstract int getDefaultSize(RecordFormatter rf, int fieldIndex)
public boolean shouldRemoveNullValue(RecordFormatter rf, int fieldIndex)
public String format(RecordFormatter rf, int fieldIndex, Object o, Dictionary<String,Object> formatParams)
FieldFormatter
format
in class FieldEditor
rf
- TODOfieldIndex
- TODOpublic Object getValueOrDefault(RecordFormatter rf, int fieldIndex, Object o, Dictionary<String,Object> formatParams)
public void setNullOption(Object nullOption)
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |