net.datacrow.console.components.lists
Class DcObjectList

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JList
                  extended by net.datacrow.console.components.lists.DcList
                      extended by net.datacrow.console.components.lists.DcObjectList
All Implemented Interfaces:
java.awt.event.ComponentListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible, javax.swing.Scrollable, ISortableComponent, IViewComponent

public class DcObjectList
extends DcList
implements IViewComponent

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JList
javax.swing.JList.AccessibleJList, javax.swing.JList.DropLocation
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
static int _CARDS
           
static int _ELABORATE
           
static int _LISTING
           
 
Fields inherited from class javax.swing.JList
HORIZONTAL_WRAP, VERTICAL, VERTICAL_WRAP
 
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
DcObjectList(DcModule module, int style, boolean wrap, boolean evenOddColors)
           
DcObjectList(int style, boolean wrap, boolean evenOddColors)
           
 
Method Summary
 void activate()
           
 int add(DcObject dco)
           
 void add(java.util.List<? extends DcObject> objects)
           
 void add(java.util.Map<java.lang.String,java.lang.Integer> keys)
           
 int add(java.lang.String key)
           
 void addSelectionListener(javax.swing.event.ListSelectionListener lsl)
           
 void afterUpdate()
           
 boolean allowsHorizontalTraversel()
           
 boolean allowsVerticalTraversel()
           
 void applySettings()
           
 void cancelEdit()
           
 void clear()
           
 void clear(int idx)
           
 void deselect()
           
 void fireIntervalAdded(int from, int to)
           
 int[] getChangedIndices()
           
 DcObjectListElement getDisplayElement(int module)
           
 int getIndex(java.lang.String ID)
           
 DcObject getItem(java.lang.String ID)
           
 DcObject getItemAt(int idx)
           
 int getItemCount()
           
 java.lang.String getItemKey(int idx)
           
 java.util.List<java.lang.String> getItemKeys()
           
 java.util.List<DcObject> getItems()
           
 DcModule getModule()
           
 int getModule(int idx)
           
 int getOptimalItemAdditionBatchSize()
           
 DcObject getSelectedItem()
           
 java.util.List<java.lang.String> getSelectedItemKeys()
           
 java.util.List<DcObject> getSelectedItems()
           
 View getView()
           
 int getViewportBufferSize()
           
 void ignoreEdit(boolean b)
           
 boolean isChangesSaved()
           
 boolean isIgnoringPaintRequests()
           
 boolean isVisibleIndex(int index)
           
 void paintRegionChanged()
           
 boolean remove(java.lang.String[] keys)
           
 void removeSelectionListener(javax.swing.event.ListSelectionListener lsl)
           
 void saveSettings()
           
 void setIgnorePaintRequests(boolean b)
           
 void setSelected(int index)
           
 void setView(View view)
           
 void undoChanges()
           
 int update(java.lang.String ID)
           
 int update(java.lang.String ID, DcObject dco)
           
 
Methods inherited from class net.datacrow.console.components.lists.DcList
addElements, componentHidden, componentMoved, componentResized, componentShown, ensureIndexIsVisible, getColumnsPerRow, getDcModel, getElements, getFirstIndexOnLastVisibleRow, getLastVisibleIndex, getPreferredScrollableViewportSize, getScrollableUnitIncrement, getUIClassID, getVisibleColumnCount, locationToIndex, locationToNearestIndex, moveRowDown, moveRowToBottom, moveRowToTop, moveRowUp, remove, remove, setColumnsPerRow, setListData, setListenersEnabled, setMaxVisibleColumnsPerRow, setSelectionMode, setVisibleColumnCount, update
 
Methods inherited from class javax.swing.JList
addListSelectionListener, addSelectionInterval, clearSelection, createSelectionModel, fireSelectionValueChanged, getAccessibleContext, getAnchorSelectionIndex, getCellBounds, getCellRenderer, getDragEnabled, getDropLocation, getDropMode, getFirstVisibleIndex, getFixedCellHeight, getFixedCellWidth, getLayoutOrientation, getLeadSelectionIndex, getListSelectionListeners, getMaxSelectionIndex, getMinSelectionIndex, getModel, getNextMatch, getPrototypeCellValue, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getSelectedIndex, getSelectedIndices, getSelectedValue, getSelectedValues, getSelectionBackground, getSelectionForeground, getSelectionMode, getSelectionModel, getToolTipText, getUI, getValueIsAdjusting, getVisibleRowCount, indexToLocation, isSelectedIndex, isSelectionEmpty, paramString, removeListSelectionListener, removeSelectionInterval, setCellRenderer, setDragEnabled, setDropMode, setFixedCellHeight, setFixedCellWidth, setLayoutOrientation, setListData, setModel, setPrototypeCellValue, setSelectedIndex, setSelectedIndices, setSelectedValue, setSelectionBackground, setSelectionForeground, setSelectionInterval, setSelectionModel, setUI, setValueIsAdjusting, setVisibleRowCount, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.datacrow.console.views.IViewComponent
addKeyListener, addMouseListener, getFirstVisibleIndex, getLastVisibleIndex, getMouseListeners, getSelectedIndex, getSelectedIndices, locationToIndex, remove, removeMouseListener, repaint, revalidate, setCursor, setSelectionMode
 
Methods inherited from interface net.datacrow.console.views.ISortableComponent
moveRowDown, moveRowToBottom, moveRowToTop, moveRowUp
 

Field Detail

_ELABORATE

public static final int _ELABORATE
See Also:
Constant Field Values

_CARDS

public static final int _CARDS
See Also:
Constant Field Values

_LISTING

public static final int _LISTING
See Also:
Constant Field Values
Constructor Detail

DcObjectList

public DcObjectList(int style,
                    boolean wrap,
                    boolean evenOddColors)

DcObjectList

public DcObjectList(DcModule module,
                    int style,
                    boolean wrap,
                    boolean evenOddColors)
Method Detail

setIgnorePaintRequests

public void setIgnorePaintRequests(boolean b)
Specified by:
setIgnorePaintRequests in interface IViewComponent

isIgnoringPaintRequests

public boolean isIgnoringPaintRequests()
Specified by:
isIgnoringPaintRequests in interface IViewComponent

isVisibleIndex

public boolean isVisibleIndex(int index)

getItemKey

public java.lang.String getItemKey(int idx)
Specified by:
getItemKey in interface IViewComponent

getModule

public int getModule(int idx)
Specified by:
getModule in interface IViewComponent

activate

public void activate()
Specified by:
activate in interface IViewComponent

paintRegionChanged

public void paintRegionChanged()
Specified by:
paintRegionChanged in interface IViewComponent

clear

public void clear(int idx)
Specified by:
clear in interface IViewComponent

getViewportBufferSize

public int getViewportBufferSize()
Specified by:
getViewportBufferSize in interface IViewComponent

saveSettings

public void saveSettings()
Specified by:
saveSettings in interface IViewComponent

getOptimalItemAdditionBatchSize

public int getOptimalItemAdditionBatchSize()

ignoreEdit

public void ignoreEdit(boolean b)
Specified by:
ignoreEdit in interface IViewComponent

undoChanges

public void undoChanges()
Specified by:
undoChanges in interface IViewComponent

isChangesSaved

public boolean isChangesSaved()
Specified by:
isChangesSaved in interface IViewComponent

setView

public void setView(View view)
Specified by:
setView in interface IViewComponent

allowsHorizontalTraversel

public boolean allowsHorizontalTraversel()
Specified by:
allowsHorizontalTraversel in interface IViewComponent

allowsVerticalTraversel

public boolean allowsVerticalTraversel()
Specified by:
allowsVerticalTraversel in interface IViewComponent

cancelEdit

public void cancelEdit()
Specified by:
cancelEdit in interface IViewComponent

getModule

public DcModule getModule()
Specified by:
getModule in interface IViewComponent

getView

public View getView()
Specified by:
getView in interface IViewComponent

getItemAt

public DcObject getItemAt(int idx)
Specified by:
getItemAt in interface IViewComponent

getItemCount

public int getItemCount()
Specified by:
getItemCount in interface IViewComponent

getItems

public java.util.List<DcObject> getItems()
Specified by:
getItems in interface IViewComponent

getItemKeys

public java.util.List<java.lang.String> getItemKeys()
Specified by:
getItemKeys in interface IViewComponent

getSelectedItems

public java.util.List<DcObject> getSelectedItems()

getSelectedItemKeys

public java.util.List<java.lang.String> getSelectedItemKeys()
Specified by:
getSelectedItemKeys in interface IViewComponent

getItem

public DcObject getItem(java.lang.String ID)
Specified by:
getItem in interface IViewComponent

getIndex

public int getIndex(java.lang.String ID)
Specified by:
getIndex in interface IViewComponent

afterUpdate

public void afterUpdate()
Specified by:
afterUpdate in interface IViewComponent

deselect

public void deselect()
Specified by:
deselect in interface IViewComponent

fireIntervalAdded

public void fireIntervalAdded(int from,
                              int to)

setSelected

public void setSelected(int index)
Specified by:
setSelected in interface IViewComponent

applySettings

public void applySettings()
Specified by:
applySettings in interface IViewComponent

update

public int update(java.lang.String ID)
Specified by:
update in interface IViewComponent

update

public int update(java.lang.String ID,
                  DcObject dco)
Specified by:
update in interface IViewComponent

getChangedIndices

public int[] getChangedIndices()
Specified by:
getChangedIndices in interface IViewComponent

remove

public boolean remove(java.lang.String[] keys)
Specified by:
remove in interface IViewComponent

getSelectedItem

public DcObject getSelectedItem()
Specified by:
getSelectedItem in interface IViewComponent

add

public int add(java.lang.String key)
Specified by:
add in interface IViewComponent

add

public void add(java.util.Map<java.lang.String,java.lang.Integer> keys)
Specified by:
add in interface IViewComponent

add

public int add(DcObject dco)
Specified by:
add in interface IViewComponent

add

public void add(java.util.List<? extends DcObject> objects)
Specified by:
add in interface IViewComponent

clear

public void clear()
Specified by:
clear in interface IViewComponent
Overrides:
clear in class DcList

getDisplayElement

public DcObjectListElement getDisplayElement(int module)

addSelectionListener

public void addSelectionListener(javax.swing.event.ListSelectionListener lsl)
Specified by:
addSelectionListener in interface IViewComponent

removeSelectionListener

public void removeSelectionListener(javax.swing.event.ListSelectionListener lsl)
Specified by:
removeSelectionListener in interface IViewComponent