|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jalios.jcms.widget.AbstractWidget
public abstract class AbstractWidget
Fields inherited from interface com.jalios.util.JaliosConstants |
---|
CRLF, MILLIS_IN_ONE_DAY, MILLIS_IN_ONE_HOUR, MILLIS_IN_ONE_MINUTE, MILLIS_IN_ONE_MONTH, MILLIS_IN_ONE_SECOND, MILLIS_IN_ONE_WEEK, MILLIS_IN_ONE_YEAR |
Constructor Summary | |
---|---|
AbstractWidget()
|
Method Summary | |
---|---|
protected static String[] |
convertObject(Object obj)
Try to convert an Object of Object[] to String[] |
protected int |
getAddComponentCount()
Return the number of additional form elements |
protected Collection |
getAllValues()
Return All the values from values[] or Map in a Collection always return a collection, never null |
protected int |
getComponentCount()
Returns the number of form elements (input, textarea, button,...). |
JcmsJspContext |
getContext()
|
String |
getCss()
|
String |
getDefaultValue()
|
String |
getDescription()
|
static String |
getDescriptionName(int editor)
|
int |
getDescriptionUI()
|
static int |
getEditor(String name)
|
static String |
getEditorName(int editor)
|
int |
getEditorUI()
|
String |
getFormName()
|
String |
getHiddenActions()
|
protected String |
getInputId()
|
protected String |
getInputTitle(int count,
String lang)
Returns what has to be added as attribute in an input tag. |
String |
getLabel()
|
protected String |
getListWidgetEditor(int startingIndex)
|
protected String |
getListWidgetEditor(int startingIndex,
String flag)
Print a list of widget |
protected String |
getListWidgetEditorByLI(int startingIndex,
String flag)
Print a list of widget using an LI presentation |
protected String |
getListWidgetEditorByTab(int startingIndex,
String lang)
Print a list of widget using an tab presentation |
String |
getMessage(String msg)
Return a convenient i18n message. |
String |
getTabGroup()
|
int |
getTabIndex()
|
int |
getTotalComponentCount()
Return the total of form element generated |
String |
getValue()
|
String |
getValue(int count,
String def)
Return the value regarding the values[] or Map |
String[] |
getValues()
|
String |
getWidget()
Print the Widget |
int |
getWidgetAddCount()
|
protected String |
getWidgetDescription()
Print the Description of the Widget |
protected String |
getWidgetEditor(int count)
Print the Editor of the Widget |
protected String |
getWidgetEditor(int count,
String lang)
|
protected abstract String |
getWidgetEditor(int count,
String lang,
String inputId)
|
protected String |
getWidgetHidden()
Print all the values to hidden |
protected String |
getWidgetIconEditor(int startingIndex,
int wdgIndex)
Return icons to display for each fields of a List |
String |
getWidgetName()
|
String[] |
getWidgetNameAddCount()
|
protected String |
getWidgetTitle()
Print the Title of the Widget |
String |
getWrapper()
|
void |
initWidget()
Set local Attribute from attribute Map |
boolean |
isDisabled()
|
boolean |
isHidden()
|
boolean |
isInline()
|
boolean |
isMultilingual()
|
boolean |
isPrintLabel()
|
boolean |
isPrintSeparator()
|
boolean |
isPrintWidget()
|
boolean |
isRequired()
|
boolean |
isSingleWidget()
This method return true if there is one semantic input. |
protected void |
printTabbedFieldAndItemIcons(StringBuffer buffer,
int i,
int startingIndex,
int wdgIndex,
String lang)
|
protected void |
printTabbedItemIcon(StringBuffer buffer,
int i,
int startingIndex,
int wdgIndex,
String lang)
|
void |
setContext(JcmsJspContext context)
|
void |
setCss(String css)
|
void |
setDefaultValue(String defaultValue)
|
void |
setDescription(String description)
|
void |
setDescriptionUI(int descriptionUI)
|
void |
setDisabled(boolean disabled)
|
void |
setEditorUI(int editorUI)
|
void |
setFormName(String formName)
|
void |
setHidden(boolean hidden)
|
void |
setHiddenActions(String hiddenActions)
Set the string which define which actions are hidden from this widget, where each letter is associated with one action: C - Create S - Select (Pub Chooser) R - Remove T - Trash U - Up D - Down U - Left D - Right E - Edit A - Add L - Id (data link) K - Calendar I - Image Chooser (upload) X - Doc Chooser W - Webdav Chooser P - File chooser M - Media chooser F - Color chooser B - DBRecord chooser Q - Query chooser H - Member Chooser G - Group Chooser |
void |
setInline(boolean inline)
|
void |
setLabel(String label)
|
void |
setLanguageList(List languageList)
|
void |
setMultilingual(boolean multilingual)
|
void |
setPrintLabel(boolean printLabel)
|
void |
setPrintSeparator(boolean printSeparator)
|
void |
setPrintWidget(boolean printWidget)
|
void |
setRequired(boolean required)
|
void |
setTabGroup(String tabGroup)
|
void |
setTabIndex(int tabIndex)
|
void |
setValue(String value)
|
void |
setValues(Object values)
|
void |
setWidgetAddCount(int widgetAddCount)
|
void |
setWidgetInitCount(int widgetInitCount)
|
void |
setWidgetName(String widgetName)
|
void |
setWidgetNameAddCount(String[] widgetNameAddCount)
|
void |
setWrapper(String wrapper)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String REVISION
public static final int UI_DESCRIPTION_NONE
public static final int UI_DESCRIPTION_TOOLTIP
public static final int UI_DESCRIPTION_TEXT
public static final int UI_EDITOR_TEXTFIELD
public static final int UI_EDITOR_TEXTFIELD_INTEGER
public static final int UI_EDITOR_TEXTFIELD_DOUBLE
public static final int UI_EDITOR_FILEPATH
public static final int UI_EDITOR_IMAGEPATH
public static final int UI_EDITOR_SIMPLEIMAGEPATH
public static final int UI_EDITOR_MEDIAPATH
public static final int UI_EDITOR_SIMPLEMEDIAPATH
public static final int UI_EDITOR_URL
public static final int UI_EDITOR_EMAIL
public static final int UI_EDITOR_PASSWORD
public static final int UI_EDITOR_COLORCHOOSER
public static final int UI_EDITOR_TEXTAREA
public static final int UI_EDITOR_WIKIAREA
public static final int UI_EDITOR_RICHTEXT
public static final int UI_EDITOR_WARNAREA
public static final int UI_EDITOR_IMAGEMAPAREA
public static final int UI_EDITOR_ENUMERATE_RADIO
public static final int UI_EDITOR_ENUMERATE_CHECK
public static final int UI_EDITOR_ENUMERATE_LIST
public static final int UI_EDITOR_ENUMERATE_COMBO
public static final int UI_EDITOR_ENUMERATE_BOOLEAN
public static final int UI_EDITOR_ENUMERATE_MEMBER
public static final int UI_EDITOR_ENUMERATE_GROUP
public static final int UI_EDITOR_ENUMERATE_CATEGORIES
public static final int UI_EDITOR_QUERYCHOOSER
public static final int UI_EDITOR_MEMBERCHOOSER
public static final int UI_EDITOR_GROUPCHOOSER
public static final int UI_EDITOR_PUBLICATIONCHOOSER
public static final int UI_EDITOR_PUBLICATIONSCHOOSER
public static final int UI_EDITOR_CATEGORYCHOOSER
public static final int UI_EDITOR_CATEGORIESCHOOSER
public static final int UI_EDITOR_WORKSPACECHOOSER
public static final int UI_EDITOR_DURATIONCHOOSER
public static final int UI_EDITOR_DATECHOOSER
public static final int UI_EDITOR_SQLQUERY
public static final int UI_EDITOR_DBRECORDCHOOSER
public static final int UI_EDITOR_CATEGORYTREE
protected String tabGroup
protected static final org.apache.log4j.Logger logger
protected String label
protected String description
protected String widgetName
protected String widgetId
protected String[] values
protected Map valueMap
protected String defaultValue
protected String firstInputID
protected boolean multilingual
protected boolean required
protected String wrapper
protected int editorUI
protected int descriptionUI
protected boolean inline
protected int itemCount
protected int widgetAddCount
protected int widgetInitCount
protected String[] widgetNameAddCount
protected String css
protected String formName
protected boolean printSeparator
protected boolean printLabel
protected boolean printWidget
protected boolean hidden
protected boolean disabled
protected List languageList
protected Channel channel
protected int tabIndex
protected JcmsJspContext context
protected String userLang
protected String hiddenActions
protected boolean showCreateIcons
protected boolean showSelectIcons
protected boolean showRemoveIcons
protected boolean showTrashIcons
protected boolean showUpIcons
protected boolean showDownIcons
protected boolean showLeftIcons
protected boolean showRightIcons
protected boolean showEditIcons
protected boolean showAddIcons
protected boolean showLinkID
protected boolean showCalendarIcons
protected boolean showImageChooser
protected boolean showDocChooser
protected boolean showWebdavChooser
protected boolean showFileChooser
protected boolean showMediaChooser
protected boolean showColorChooser
protected boolean showDBRecChooser
protected boolean showQueryChooser
protected boolean showMrbChooser
protected boolean showGrpChooser
protected boolean showCategoryButton
Constructor Detail |
---|
public AbstractWidget()
Method Detail |
---|
public static int getEditor(String name)
public static String getEditorName(int editor)
public static String getDescriptionName(int editor)
protected String getWidgetEditor(int count)
public void initWidget()
protected final String getWidgetEditor(int count, String lang)
protected abstract String getWidgetEditor(int count, String lang, String inputId)
protected String getInputId()
protected int getComponentCount()
protected int getAddComponentCount()
public int getTotalComponentCount()
protected String getListWidgetEditor(int startingIndex, String flag)
startingIndex
- the index of the field (case of multilingual)
protected String getListWidgetEditorByLI(int startingIndex, String flag)
startingIndex
- the index of the field (case of multilingual)
protected String getListWidgetEditorByTab(int startingIndex, String lang)
startingIndex
- the index of the field (case of multilingual)
protected void printTabbedFieldAndItemIcons(StringBuffer buffer, int i, int startingIndex, int wdgIndex, String lang)
protected void printTabbedItemIcon(StringBuffer buffer, int i, int startingIndex, int wdgIndex, String lang)
protected String getListWidgetEditor(int startingIndex)
protected String getWidgetIconEditor(int startingIndex, int wdgIndex)
startingIndex
- the index of the field (case of multilingual)wdgIndex
- the relative widget index
protected String getWidgetHidden()
public String getMessage(String msg)
msg
- public String getWidget()
public boolean isSingleWidget()
protected String getWidgetDescription()
protected String getWidgetTitle()
protected String getInputTitle(int count, String lang)
count
- i-th occurrence of the inputlang
- language code of the lang for the input
public String getCss()
public void setCss(String css)
public String getLabel()
public void setLabel(String label)
public String getDescription()
public void setDescription(String description)
public String getWidgetName()
public void setWidgetName(String widgetName)
public String getFormName()
public void setFormName(String formName)
public String getDefaultValue()
public void setDefaultValue(String defaultValue)
public String getValue()
public void setValue(String value)
public String[] getValues()
public boolean isPrintSeparator()
public void setPrintSeparator(boolean printSeparator)
public boolean isHidden()
public void setHidden(boolean hidden)
public boolean isDisabled()
public void setDisabled(boolean disabled)
public boolean isPrintLabel()
public void setPrintLabel(boolean printLabel)
public boolean isPrintWidget()
public void setPrintWidget(boolean printWidget)
public boolean isMultilingual()
public void setMultilingual(boolean multilingual)
public void setLanguageList(List languageList)
public String getWrapper()
public void setWrapper(String wrapper)
public boolean isRequired()
public void setRequired(boolean required)
public int getDescriptionUI()
public void setDescriptionUI(int descriptionUI)
public boolean isInline()
public void setInline(boolean inline)
public int getEditorUI()
public void setEditorUI(int editorUI)
public int getWidgetAddCount()
public void setWidgetAddCount(int widgetAddCount)
public void setWidgetInitCount(int widgetInitCount)
public String[] getWidgetNameAddCount()
public void setWidgetNameAddCount(String[] widgetNameAddCount)
public int getTabIndex()
public void setTabIndex(int tabIndex)
public JcmsJspContext getContext()
public void setContext(JcmsJspContext context)
public String getHiddenActions()
public void setHiddenActions(String hiddenActions)
hiddenActions
- a sequence of character representing actions icons to hide.public void setValues(Object values)
protected Collection getAllValues()
public String getValue(int count, String def)
count
- the object positiondef
- the default value
public String getTabGroup()
public void setTabGroup(String tabGroup)
protected static String[] convertObject(Object obj)
obj
- the Object to convert
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |