public abstract class AbstractWidget extends java.lang.Object implements JcmsConstants
Modifier and Type | Field and Description |
---|---|
protected Channel |
channel |
protected JcmsJspContext |
context |
protected java.lang.String |
css |
protected java.lang.String |
customAttributes |
protected java.lang.String |
defaultValue |
protected java.lang.String |
description |
protected int |
descriptionUI |
protected boolean |
disabled |
protected int |
editorUI |
protected java.lang.String |
firstInputID |
protected boolean |
forceUpDown |
protected java.lang.String |
formName |
protected boolean |
hidden |
protected java.lang.String |
hiddenActions |
protected boolean |
inline |
protected boolean |
isTabbed |
protected int |
itemCount
How many items this "list" widget is composed of
|
protected boolean |
keyword |
protected java.lang.String |
label |
protected java.util.List<java.lang.String> |
languageList |
protected static org.apache.log4j.Logger |
logger |
protected boolean |
multilingual |
protected java.lang.String |
placeholder |
protected boolean |
printLabel |
protected boolean |
printSeparator |
protected boolean |
printWidget |
protected boolean |
required |
static java.lang.String |
REVISION |
protected boolean |
showAddButton |
protected boolean |
showAddIcons |
protected boolean |
showCalendarIcons |
protected boolean |
showCategoryButton |
protected boolean |
showColorChooser |
protected boolean |
showCreateIcons |
protected boolean |
showDBRecChooser |
protected boolean |
showDocChooser |
protected boolean |
showDownIcons |
protected boolean |
showEditIcons |
protected boolean |
showGrpChooser |
protected boolean |
showImageChooser |
protected boolean |
showLeftIcons |
protected boolean |
showLinkID |
protected boolean |
showMediaChooser |
protected boolean |
showMrbChooser |
protected boolean |
showQueryChooser |
protected boolean |
showRemoveIcons |
protected boolean |
showRightIcons |
protected boolean |
showSelectIcons |
protected boolean |
showTrashIcons |
protected boolean |
showUpIcons |
protected boolean |
showWebdavChooser |
protected java.lang.String |
tabGroup |
protected int |
tabIndex |
static int |
UI_DESCRIPTION_NONE |
static int |
UI_DESCRIPTION_TEXT |
static int |
UI_DESCRIPTION_TOOLTIP |
static int |
UI_EDITOR_ACLCHOOSER |
static int |
UI_EDITOR_CATEGORIESCHOOSER |
static int |
UI_EDITOR_CATEGORYCHOOSER |
static int |
UI_EDITOR_CATEGORYTREE |
static int |
UI_EDITOR_COLORCHOOSER |
static int |
UI_EDITOR_DATECHOOSER |
static int |
UI_EDITOR_DBRECORDCHOOSER |
static int |
UI_EDITOR_DURATIONCHOOSER |
static int |
UI_EDITOR_EMAIL |
static int |
UI_EDITOR_ENUMERATE_BOOLEAN |
static int |
UI_EDITOR_ENUMERATE_CATEGORIES |
static int |
UI_EDITOR_ENUMERATE_CHECK |
static int |
UI_EDITOR_ENUMERATE_COMBO |
static int |
UI_EDITOR_ENUMERATE_GROUP |
static int |
UI_EDITOR_ENUMERATE_LIST |
static int |
UI_EDITOR_ENUMERATE_MEMBER |
static int |
UI_EDITOR_ENUMERATE_RADIO |
static int |
UI_EDITOR_FILEPATH |
static int |
UI_EDITOR_GROUPCHOOSER |
static int |
UI_EDITOR_GROUPSCHOOSER |
static int |
UI_EDITOR_IMAGEMAPAREA |
static int |
UI_EDITOR_IMAGEPATH |
static int |
UI_EDITOR_MEDIAPATH |
static int |
UI_EDITOR_MEMBERCHOOSER |
static int |
UI_EDITOR_MEMBERSCHOOSER |
static int |
UI_EDITOR_PASSWORD |
static int |
UI_EDITOR_PUBLICATIONCHOOSER |
static int |
UI_EDITOR_PUBLICATIONSCHOOSER |
static int |
UI_EDITOR_QUERYCHOOSER |
static int |
UI_EDITOR_RICHTEXT |
static int |
UI_EDITOR_SIMPLEIMAGEPATH |
static int |
UI_EDITOR_SIMPLEMEDIAPATH |
static int |
UI_EDITOR_SQLQUERY |
static int |
UI_EDITOR_TEXTAREA |
static int |
UI_EDITOR_TEXTFIELD |
static int |
UI_EDITOR_TEXTFIELD_DOUBLE |
static int |
UI_EDITOR_TEXTFIELD_INTEGER |
static int |
UI_EDITOR_URL |
static int |
UI_EDITOR_WARNAREA |
static int |
UI_EDITOR_WIKIAREA |
static int |
UI_EDITOR_WORKSPACECHOOSER |
protected java.lang.String |
userLang |
protected java.util.Map |
valueMap |
protected java.lang.String[] |
values |
protected int |
widgetAddCount |
protected java.lang.String |
widgetId |
protected java.lang.String |
widgetName |
protected java.lang.String |
wrapper |
ADATE_SEARCH, ADMIN_NOTES_PROP, ADVANCED_TAB, ARCHIVES_DIR, ASCII_WIDTH, CATEGORY_TAB, CDATE_SEARCH, COMMON_ALARM, CONTENT_TAB, COOKIE_MAX_AGE, CTRL_TOPIC_INTERNAL, CTRL_TOPIC_REF, CTRL_TOPIC_VALUE, CTRL_TOPIC_WRITE, CUSTOM_PROP, DOCCHOOSER_HEIGHT, DOCCHOOSER_WIDTH, DOCS_DIR, EDATE_SEARCH, EMAIL_REGEXP, ERROR_MSG, FORBIDDEN_FILE_ACCESS, FORBIDDEN_REDIRECT, FORCE_REDIRECT, ICON_ARCHIVE, ICON_LOCK, ICON_LOCK_STRONG, ICON_WARN, ICON_WH_BOOK_CLOSED, ICON_WH_BOOK_OPEN, INFORMATION_MSG, JALIOS_JUNIT_PROP, JCMS_CADDY, JCMS_MSG_LIST, JSYNC_DOWNLOAD_DIR, JSYNC_SYNC_ALARM, LOG_FILE, LOG_TOPIC_SECURITY, LOGGER_PROP, LOGGER_XMLPROP, MBR_PHOTO_DIR, MDATE_SEARCH, MONITOR_XML, OP_CREATE, OP_CREATE_STR, OP_DEEP_COPY, OP_DEEP_COPY_STR, OP_DEEP_DELETE, OP_DEEP_DELETE_STR, OP_DELETE, OP_DELETE_STR, OP_MERGE, OP_MERGE_STR, OP_UPDATE, OP_UPDATE_STR, PDATE_SEARCH, PHOTO_DIR, PHOTO_ICON, PHOTO_ICON_HEIGHT, PHOTO_ICON_WIDTH, PHOTO_LARGE, PHOTO_LARGE_HEIGHT, PHOTO_LARGE_WIDTH, PHOTO_NORMAL, PHOTO_NORMAL_HEIGHT, PHOTO_NORMAL_WIDTH, PHOTO_SMALL, PHOTO_SMALL_HEIGHT, PHOTO_SMALL_WIDTH, PHOTO_TINY, PHOTO_TINY_HEIGHT, PHOTO_TINY_WIDTH, PREVIOUS_TAB, PRINT_VIEW, PRIVATE_FILE_ACCESS, PUBLIC_FILE_ACCESS, READ_RIGHT_TAB, SDATE_SEARCH, SEARCHENGINE_ALARM, SESSION_AUTHORIZED_FILENAMES_SET, STATS_REPORT_DIR, STATUS_PROP, STORE_XML, TEMPLATE_TAB, THUMBNAIL_LARGE_HEIGHT, THUMBNAIL_LARGE_WIDTH, THUMBNAIL_SMALL_HEIGHT, THUMBNAIL_SMALL_WIDTH, TYPES_ICON_ALT_PROP, TYPES_ICON_SUFFIX_PROP, TYPES_ICON_TITLE_PROP, TYPES_PREFIX_PROP, TYPES_THUMB_SUFFIX_PROP, UDATE_SEARCH, UPDATE_RIGHT_TAB, UPLOAD_DIR, URL_REGEXP, WARNING_MSG, WEBAPP_PROP, WFEXPRESS_ALARM, WFREMINDER_ALARM, WORKFLOW_TAB, WORKFLOW_XML
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 and Description |
---|
AbstractWidget() |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String[] |
convertObject(java.lang.Object obj)
Try to convert an Object of Object[] to String[]
|
protected int |
getAddComponentCount()
Return the number of additional form elements
|
protected java.util.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() |
java.lang.String |
getCss() |
java.lang.String |
getCustomAttributes() |
java.lang.String |
getDefaultValue() |
java.lang.String |
getDescription() |
static java.lang.String |
getDescriptionName(int editor) |
int |
getDescriptionUI() |
static int |
getEditor(java.lang.String name) |
static java.lang.String |
getEditorName(int editor) |
int |
getEditorUI() |
java.lang.String |
getFormName() |
java.lang.String |
getHiddenActions() |
protected java.lang.String |
getInputId(boolean first) |
protected java.lang.String |
getInputTitle(int count,
java.lang.String lang)
Returns what has to be added as attribute in an input tag.
|
boolean |
getKeyword() |
java.lang.String |
getLabel() |
protected java.lang.String |
getListWidgetEditor(int startingIndex) |
protected java.lang.String |
getListWidgetEditor(int startingIndex,
java.lang.String flag)
Print a list of widget
|
protected java.lang.String |
getListWidgetEditorByLI(int startingIndex,
java.lang.String flag)
Print a list of widget using an LI presentation
|
java.lang.String |
getMessage(java.lang.String msg)
Return a convenient i18n message.
|
java.lang.String |
getPlaceholder() |
boolean |
getShowAddButton() |
java.lang.String |
getTabGroup() |
int |
getTabIndex() |
int |
getTotalComponentCount()
Return the total of form element generated
|
java.lang.String |
getValue() |
java.lang.String |
getValue(int count,
java.lang.String def)
Return the value regarding the values[] or Map
|
java.lang.String[] |
getValues() |
java.lang.String |
getWidget()
Print the Widget
|
int |
getWidgetAddCount() |
protected java.lang.String |
getWidgetDescriptionText(boolean force) |
protected java.lang.String |
getWidgetDescriptionTooltip()
Print the Description of the Widget
|
protected java.lang.String |
getWidgetEditor(int count)
Print the Editor of the Widget
|
protected java.lang.String |
getWidgetEditor(int count,
java.lang.String lang) |
protected abstract java.lang.String |
getWidgetEditor(int count,
java.lang.String lang,
java.lang.String inputId) |
protected java.lang.String |
getWidgetHidden()
Print all the values to hidden
|
protected java.lang.String |
getWidgetLang() |
java.lang.String |
getWidgetName() |
protected void |
getWidgetTab(java.lang.StringBuffer sb) |
protected void |
getWidgetTabAdd(java.lang.StringBuffer sb) |
protected java.lang.String |
getWidgetTitle()
Print the Title of the Widget
|
java.lang.String |
getWrapper() |
void |
initWidget()
Set local Attribute from attribute Map
|
boolean |
isDisabled() |
boolean |
isEditorCtxMenu(int editor)
Returns true if editor needs a ctxmenu
|
boolean |
isHidden() |
boolean |
isInline() |
boolean |
isKeywordDisplay() |
boolean |
isMultilingual() |
boolean |
isMultivalued()
Returns true if the widget is multivalued
|
boolean |
isPrintSeparator() |
boolean |
isPrintWidget() |
boolean |
isRequired() |
boolean |
isShowAddButton() |
boolean |
isTabbedEditor(int editor) |
protected void |
printTabbedFieldAndItemIcons(java.lang.StringBuffer buffer,
int i,
int startingIndex,
int wdgIndex,
java.lang.String lang) |
void |
setContext(JcmsJspContext context) |
void |
setCss(java.lang.String css) |
void |
setCustomAttributes(java.lang.String customAttributes) |
void |
setDefaultValue(java.lang.String defaultValue) |
void |
setDescription(java.lang.String description) |
void |
setDescriptionUI(int descriptionUI) |
void |
setDisabled(boolean disabled) |
void |
setEditorUI(int editorUI) |
void |
setFormName(java.lang.String formName) |
void |
setHidden(boolean hidden) |
void |
setHiddenActions(java.lang.String hiddenActions)
Set the string which define which actions are hidden from this widget, where
each letter is associated with one action:
A - Add
B - DBRecord chooser
C - Create
D - Down / Right
E - Edit
F - Color chooser
G - Group Chooser
H - Member Chooser
I - Image Chooser (upload)
J -
K - Calendar
L - Id (data link)
M - Media chooser
N -
O -
Q - Query chooser
R - Remove
S - Select (Pub Chooser)
T - Trash
U - Up / Left
V -
W - Webdav Chooser
X - Doc Chooser
Y - CategoryChooser
Z - WorkspaceChooser
|
void |
setInline(boolean inline) |
void |
setIsTabbed(boolean isTabbed) |
void |
setKeyword(boolean keyword) |
void |
setLabel(java.lang.String label) |
void |
setLanguageList(java.util.List<java.lang.String> languageList) |
void |
setMultilingual(boolean multilingual) |
void |
setPlaceholder(java.lang.String placeholder) |
void |
setPrintLabel(boolean printLabel) |
void |
setPrintSeparator(boolean printSeparator) |
void |
setPrintWidget(boolean printWidget) |
void |
setRequired(boolean required) |
void |
setShowAddButton(boolean showAddButton) |
void |
setTabGroup(java.lang.String tabGroup) |
void |
setTabIndex(int tabIndex) |
void |
setValue(java.lang.String value) |
void |
setValues(java.lang.Object values) |
void |
setWidgetAddCount(int widgetAddCount) |
void |
setWidgetInitCount(int widgetInitCount) |
void |
setWidgetName(java.lang.String widgetName) |
void |
setWrapper(java.lang.String wrapper) |
public static final java.lang.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_MEMBERSCHOOSER
public static final int UI_EDITOR_GROUPCHOOSER
public static final int UI_EDITOR_GROUPSCHOOSER
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
public static final int UI_EDITOR_ACLCHOOSER
protected static final org.apache.log4j.Logger logger
protected java.lang.String tabGroup
protected boolean isTabbed
protected java.lang.String label
protected java.lang.String description
protected java.lang.String placeholder
protected java.lang.String widgetName
protected java.lang.String widgetId
protected java.lang.String[] values
protected java.util.Map valueMap
protected java.lang.String defaultValue
protected java.lang.String firstInputID
protected boolean multilingual
protected boolean required
protected boolean keyword
protected java.lang.String wrapper
protected java.lang.String customAttributes
protected int editorUI
protected int descriptionUI
protected boolean inline
protected int itemCount
protected int widgetAddCount
protected java.lang.String css
protected boolean showAddButton
protected java.lang.String formName
protected boolean printSeparator
protected boolean printLabel
protected boolean printWidget
protected boolean hidden
protected boolean disabled
protected java.util.List<java.lang.String> languageList
protected Channel channel
protected int tabIndex
protected boolean forceUpDown
protected JcmsJspContext context
protected java.lang.String userLang
protected java.lang.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 showMediaChooser
protected boolean showColorChooser
protected boolean showDBRecChooser
protected boolean showQueryChooser
protected boolean showMrbChooser
protected boolean showGrpChooser
protected boolean showCategoryButton
public static int getEditor(java.lang.String name)
public static java.lang.String getEditorName(int editor)
public boolean isEditorCtxMenu(int editor)
editor
- public boolean isTabbedEditor(int editor)
public static java.lang.String getDescriptionName(int editor)
protected java.lang.String getWidgetEditor(int count)
public void initWidget()
protected abstract java.lang.String getWidgetEditor(int count, java.lang.String lang, java.lang.String inputId)
protected final java.lang.String getWidgetEditor(int count, java.lang.String lang)
protected java.lang.String getInputId(boolean first)
protected int getComponentCount()
protected int getAddComponentCount()
public int getTotalComponentCount()
protected java.lang.String getListWidgetEditor(int startingIndex, java.lang.String flag)
startingIndex
- the index of the field (case of multilingual)protected java.lang.String getListWidgetEditorByLI(int startingIndex, java.lang.String flag)
startingIndex
- the index of the field (case of multilingual)protected void printTabbedFieldAndItemIcons(java.lang.StringBuffer buffer, int i, int startingIndex, int wdgIndex, java.lang.String lang)
protected java.lang.String getListWidgetEditor(int startingIndex)
protected java.lang.String getWidgetHidden()
protected void getWidgetTab(java.lang.StringBuffer sb)
protected void getWidgetTabAdd(java.lang.StringBuffer sb)
public java.lang.String getMessage(java.lang.String msg)
msg
- the messagepublic java.lang.String getWidget()
public boolean isMultivalued()
protected java.lang.String getWidgetLang()
protected java.lang.String getWidgetDescriptionTooltip()
protected java.lang.String getWidgetDescriptionText(boolean force)
protected java.lang.String getWidgetTitle()
protected java.lang.String getInputTitle(int count, java.lang.String lang)
count
- i-th occurrence of the inputlang
- language code of the lang for the inputpublic boolean isShowAddButton()
public boolean getShowAddButton()
public void setShowAddButton(boolean showAddButton)
public java.lang.String getCss()
public void setCss(java.lang.String css)
public boolean getKeyword()
public void setKeyword(boolean keyword)
public boolean isKeywordDisplay()
public java.lang.String getLabel()
public void setLabel(java.lang.String label)
public void setPlaceholder(java.lang.String placeholder)
public java.lang.String getPlaceholder()
public java.lang.String getDescription()
public void setDescription(java.lang.String description)
public java.lang.String getWidgetName()
public void setWidgetName(java.lang.String widgetName)
public java.lang.String getFormName()
public void setFormName(java.lang.String formName)
public java.lang.String getDefaultValue()
public void setDefaultValue(java.lang.String defaultValue)
public java.lang.String getValue()
public void setValue(java.lang.String value)
public java.lang.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 void setPrintLabel(boolean printLabel)
public boolean isPrintWidget()
public void setPrintWidget(boolean printWidget)
public boolean isMultilingual()
public void setMultilingual(boolean multilingual)
public void setLanguageList(java.util.List<java.lang.String> languageList)
public java.lang.String getWrapper()
public void setWrapper(java.lang.String wrapper)
public void setCustomAttributes(java.lang.String customAttributes)
public java.lang.String getCustomAttributes()
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 int getTabIndex()
public void setTabIndex(int tabIndex)
public JcmsJspContext getContext()
public void setContext(JcmsJspContext context)
public java.lang.String getHiddenActions()
public void setHiddenActions(java.lang.String hiddenActions)
hiddenActions
- a sequence of character representing actions icons to hide.public void setValues(java.lang.Object values)
protected java.util.Collection getAllValues()
public java.lang.String getValue(int count, java.lang.String def)
count
- the object positiondef
- the default valuepublic java.lang.String getTabGroup()
public void setTabGroup(java.lang.String tabGroup)
public void setIsTabbed(boolean isTabbed)
protected java.lang.String[] convertObject(java.lang.Object obj)
obj
- the Object to convertCopyright © 2001-2010 Jalios SA. All Rights Reserved.