public class DefaultMapEditorRenderer<K,V> extends AbstractPaginableEditorRenderer<Map<K,V>>
| Modifier and Type | Class and Description |
|---|---|
protected static class |
DefaultMapEditorRenderer.InlineEditorMode |
protected class |
DefaultMapEditorRenderer.MapEditorListitemRenderer |
| Modifier and Type | Field and Description |
|---|---|
protected static String |
CLEAR_EDITOR_IMG |
protected org.zkoss.zul.Listbox |
editorView |
protected static String |
KEY_VALUE_SEPARATOR_IMG |
protected static String |
MODE_CTX_PARAM |
protected static String |
SAVE_EDITOR_IMG |
CONFIRM_DELETE_PARAM, ITEM_INDEX_TO_CUT, LAST_EDITED_INDEX, LAST_EDITED_VALUE, NULL, ON_EDIT_EVENT, ON_INIT_EVENT, ON_UPDATE_EVENT, TRUE, YE_LIST_CONTAINER, YE_LIST_CONTENT, YE_LIST_INLINE, YE_LIST_INLINE_CANCEL, YE_LIST_INLINE_EDITOR, YE_LIST_INLINE_SAVE, YE_LIST_LINE_EDITOR, YE_LIST_LISTBOX, YE_LIST_TITLEBAR, YE_LIST_TITLEBAR_LABEL, YE_LIST_TITLEBAR_SPAN, YE_LIST_TITLEBAR_VALUE, YE_LIST_TOOLBAR, YE_LIST_TOOLBAR_ADDPOPUP, YE_LIST_TOOLBAR_ADDPOPUP_CHECKBOX, YE_LIST_TOOLBAR_BUTTON_EDIT, YE_LIST_Y_BTB_PRIMARYHEADER_LABEL_TOOLTIP, ON_ADD_EVENT, ON_DELETE_EVENTINITIAL_EDIT_STRING| Constructor and Description |
|---|
DefaultMapEditorRenderer() |
| Modifier and Type | Method and Description |
|---|---|
protected org.zkoss.zul.Popup |
createAddPopup(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
EditorContext<Map<K,V>> context) |
protected org.zkoss.zul.Listfooter |
createFooter(EditorListener<Map<K,V>> listener,
EditorContext<Map<K,V>> context) |
protected org.zkoss.zul.Div |
createFooterContent(EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener,
org.zkoss.zul.Listfooter footer) |
protected org.zkoss.zul.Div |
createInlineEditor(EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener,
org.zkoss.zul.Listitem listItem,
Map.Entry<K,V> data)
Creates inline editor for list item.
|
protected org.zkoss.zul.ListitemRenderer<Map.Entry<K,V>> |
createItemRenderer(EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener)
Defines
ListitemRenderer for the items in the list. |
protected org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event> |
createSaveInlineValueListener(K key,
Editor inlineEditorKey,
Editor inlineEditorValue,
EditorListener<Map<K,V>> listener,
EditorContext<Map<K,V>> context) |
protected void |
deleteValueAtIndex(int idx,
org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener) |
protected void |
editValue(K key,
V value,
org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener) |
protected org.apache.commons.lang3.tuple.Pair<String,String> |
extractArguments(String value) |
protected org.apache.commons.lang3.tuple.Pair<String,String> |
extractDefaultEditors(EditorContext<Map<K,V>> context) |
protected String |
extractKeyEditorType(EditorContext<Map<K,V>> context) |
protected String |
extractValueEditorType(EditorContext<Map<K,V>> context) |
protected Map<K,V> |
getCurrentContent(org.zkoss.zul.Listbox listbox) |
protected int |
getEditorTypeSeparatorPosition(String value) |
protected String |
getFooterContentImage() |
protected org.zkoss.zk.ui.HtmlBasedComponent |
getInlineEditorKeyComponent(Object key) |
protected LabelService |
getLabelService() |
protected org.zkoss.zul.ListModel<Map.Entry<K,V>> |
getListModel(org.zkoss.zul.Listbox listbox) |
protected String |
getObjectLabel(Object key) |
TypeFacade |
getTypeFacade() |
protected boolean |
isCollectionOrMap(Object obj) |
protected EditorContext<Map<K,V>> |
prepareNestedContext(EditorContext<Map<K,V>> context,
String editorType,
String valueType) |
void |
render(org.zkoss.zk.ui.Component parent,
EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener)
Creates a new editor component and attaches it to the specified
Component component. |
protected void |
revert(DefaultMapEditorRenderer.InlineEditorMode mode,
EditorListener<Map<K,V>> listener,
EditorContext<Map<K,V>> context) |
protected void |
revertFooter(EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener) |
protected void |
revertValue(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener) |
void |
setLabelService(LabelService labelService) |
void |
setTypeFacade(TypeFacade typeFacade) |
protected void |
swapValues(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
org.zkoss.zul.Listitem swappableListitemYang,
org.zkoss.zul.Listitem swappableListitemYing) |
protected void |
updateCurrentValue(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
Map<K,V> newValue) |
configurePaging, createAddButton, createDeleteButton, createEditor, getPageSize, selectionNotEmptyextractEmbeddedEditor, extractEmbeddedType, findAncestorEditor, findEmbeddedEditors, getInitialEditString, getL10nDecoratorprotected static final String SAVE_EDITOR_IMG
protected static final String CLEAR_EDITOR_IMG
protected static final String KEY_VALUE_SEPARATOR_IMG
protected static final String MODE_CTX_PARAM
protected org.zkoss.zul.Listbox editorView
public void render(org.zkoss.zk.ui.Component parent,
EditorContext<Map<K,V>> context,
EditorListener<Map<K,V>> listener)
CockpitEditorRendererComponent component.parent - parent component the editor should be attached tocontext - the context for the editor creationlistener - the listener to notify the rest of the world about value changes and other eventsprotected org.zkoss.zul.Listfooter createFooter(EditorListener<Map<K,V>> listener, EditorContext<Map<K,V>> context)
protected org.zkoss.zul.Div createFooterContent(EditorContext<Map<K,V>> context, EditorListener<Map<K,V>> listener, org.zkoss.zul.Listfooter footer)
protected String getFooterContentImage()
protected void swapValues(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
org.zkoss.zul.Listitem swappableListitemYang,
org.zkoss.zul.Listitem swappableListitemYing)
protected org.zkoss.zul.ListitemRenderer<Map.Entry<K,V>> createItemRenderer(EditorContext<Map<K,V>> context, EditorListener<Map<K,V>> listener)
ListitemRenderer for the items in the list.context - defines editor's environmentlistener - reacts on editor's eventsListitemRendererprotected org.zkoss.zul.Div createInlineEditor(EditorContext<Map<K,V>> context, EditorListener<Map<K,V>> listener, org.zkoss.zul.Listitem listItem, Map.Entry<K,V> data)
context - - editor contextlistener - - editor listenerlistItem - - list item where the editor should be rendereddata - - initial data for the editorDiv with the inline editorprotected org.zkoss.zk.ui.HtmlBasedComponent getInlineEditorKeyComponent(Object key)
protected org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event> createSaveInlineValueListener(K key, Editor inlineEditorKey, Editor inlineEditorValue, EditorListener<Map<K,V>> listener, EditorContext<Map<K,V>> context)
protected void revert(DefaultMapEditorRenderer.InlineEditorMode mode, EditorListener<Map<K,V>> listener, EditorContext<Map<K,V>> context)
protected void revertValue(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener)
protected void updateCurrentValue(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
Map<K,V> newValue)
protected void revertFooter(EditorContext<Map<K,V>> context, EditorListener<Map<K,V>> listener)
protected String extractKeyEditorType(EditorContext<Map<K,V>> context)
protected String extractValueEditorType(EditorContext<Map<K,V>> context)
protected org.apache.commons.lang3.tuple.Pair<String,String> extractArguments(String value)
protected int getEditorTypeSeparatorPosition(String value)
protected org.zkoss.zul.Popup createAddPopup(org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener,
EditorContext<Map<K,V>> context)
createAddPopup in class AbstractPaginableEditorRenderer<Map<K,V>>protected EditorContext<Map<K,V>> prepareNestedContext(EditorContext<Map<K,V>> context, String editorType, String valueType)
protected org.apache.commons.lang3.tuple.Pair<String,String> extractDefaultEditors(EditorContext<Map<K,V>> context)
protected void editValue(K key, V value, org.zkoss.zul.Listbox listbox, EditorListener<Map<K,V>> listener)
protected void deleteValueAtIndex(int idx,
org.zkoss.zul.Listbox listbox,
EditorListener<Map<K,V>> listener)
protected org.zkoss.zul.ListModel<Map.Entry<K,V>> getListModel(org.zkoss.zul.Listbox listbox)
protected LabelService getLabelService()
public void setLabelService(LabelService labelService)
public TypeFacade getTypeFacade()
public void setTypeFacade(TypeFacade typeFacade)
Copyright © 2018. All rights reserved.