JRubik v0.6

es.aeat.eett.plugins.scrollNavi
Class JScrollNavi

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjavax.swing.JComponent
              extended byjavax.swing.JScrollPane
                  extended byes.aeat.eett.plugins.scrollNavi.JScrollNavi
All Implemented Interfaces:
javax.accessibility.Accessible, java.util.EventListener, java.awt.image.ImageObserver, java.awt.MenuContainer, com.tonbeller.jpivot.core.ModelChangeListener, javax.swing.ScrollPaneConstants, java.io.Serializable

public class JScrollNavi
extends javax.swing.JScrollPane
implements com.tonbeller.jpivot.core.ModelChangeListener

Author:
f00992

en:

es: JScrollPane que contiene un arbol que perminte navegar por los elementos del cubo olap, dimensiones, levels, etc...

See Also:
Serialized Form

Nested Class Summary
(package private)  class JScrollNavi.ActionApply
           
(package private)  class JScrollNavi.ActionDown
           
(package private)  class JScrollNavi.ActionToCol
           
(package private)  class JScrollNavi.ActionToFilter
           
(package private)  class JScrollNavi.ActionToRow
           
(package private)  class JScrollNavi.ActionUp
           
(package private)  class JScrollNavi.ClickMouseTrigger
           
(package private)  class JScrollNavi.MouseTrigger
          Esta clase procesa los eventos del raton bien mostrado un menu o moviendo elementos del arbol.
 
Nested classes inherited from class javax.swing.JScrollPane
javax.swing.JScrollPane.AccessibleJScrollPane, javax.swing.JScrollPane.ScrollBar
 
Nested classes inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
private  javax.swing.ActionMap amScrollMenuBar
           
private  boolean autoUpdate
           
private  javax.swing.JTree jTreeNavi
           
static java.lang.String KEY_ACTION_APPLY
           
static java.lang.String KEY_ACTION_CLOSE
           
static java.lang.String KEY_ACTION_DOWN
           
static java.lang.String KEY_ACTION_TO_COL
           
static java.lang.String KEY_ACTION_TO_FILTER
           
static java.lang.String KEY_ACTION_TO_ROW
           
static java.lang.String KEY_ACTION_UP
           
protected static java.util.ResourceBundle localizationResources
           
private static org.apache.log4j.Logger logger
           
static java.lang.String NAME_COLS
           
static java.lang.String NAME_FILTER
           
static java.lang.String NAME_ROWS
           
private  javax.swing.JPopupMenu popup
           
private  CheckNode root
           
 
Fields inherited from class javax.swing.JScrollPane
columnHeader, horizontalScrollBar, horizontalScrollBarPolicy, lowerLeft, lowerRight, rowHeader, upperLeft, upperRight, verticalScrollBar, verticalScrollBarPolicy, viewport
 
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.Container
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.ScrollPaneConstants
COLUMN_HEADER, HORIZONTAL_SCROLLBAR, HORIZONTAL_SCROLLBAR_ALWAYS, HORIZONTAL_SCROLLBAR_AS_NEEDED, HORIZONTAL_SCROLLBAR_NEVER, HORIZONTAL_SCROLLBAR_POLICY, LOWER_LEADING_CORNER, LOWER_LEFT_CORNER, LOWER_RIGHT_CORNER, LOWER_TRAILING_CORNER, ROW_HEADER, UPPER_LEADING_CORNER, UPPER_LEFT_CORNER, UPPER_RIGHT_CORNER, UPPER_TRAILING_CORNER, VERTICAL_SCROLLBAR, VERTICAL_SCROLLBAR_ALWAYS, VERTICAL_SCROLLBAR_AS_NEEDED, VERTICAL_SCROLLBAR_NEVER, VERTICAL_SCROLLBAR_POLICY, VIEWPORT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
JScrollNavi()
          Las dimensiones del arbol siguen el orden del esquema
 
Method Summary
private  void addHierarchysTable(CheckNode node, int index)
           
private  void cfgPopupMenu(CheckNode nodo)
          Configura jPopupMenu en funcion del nodo seleccionad.
private  javax.swing.JToolBar createJToolBar()
          Crea JToolBar e inicializa amScrollMenuBar con su ActionMap.
private  javax.swing.JPopupMenu createPopupMenu(javax.swing.JTree jTree)
          Crea JPopupMenu su ActionMap.
private  int getIndexAxis(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
           
private  java.util.List getMembersVisbles(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
           
private  CheckNode getRootNode()
           
private  void initComponents()
           
 boolean isAutoUpdate()
           
private  boolean isInSlicer(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
           
 void modelChanged(com.tonbeller.jpivot.core.ModelChangeEvent e)
           
private  void move(CheckNode node, java.lang.String nameNodo)
           
 void setAutoUpdate(boolean autoUpdate)
           
 void structureChanged(com.tonbeller.jpivot.core.ModelChangeEvent e)
           
 void updateTree()
           
private  void updateTreeComponen()
           
 
Methods inherited from class javax.swing.JScrollPane
createHorizontalScrollBar, createVerticalScrollBar, createViewport, getAccessibleContext, getColumnHeader, getCorner, getHorizontalScrollBar, getHorizontalScrollBarPolicy, getRowHeader, getUI, getUIClassID, getVerticalScrollBar, getVerticalScrollBarPolicy, getViewport, getViewportBorder, getViewportBorderBounds, isValidateRoot, isWheelScrollingEnabled, paramString, setColumnHeader, setColumnHeaderView, setComponentOrientation, setCorner, setHorizontalScrollBar, setHorizontalScrollBarPolicy, setLayout, setRowHeader, setRowHeaderView, setUI, setVerticalScrollBar, setVerticalScrollBarPolicy, setViewport, setViewportBorder, setViewportView, setWheelScrollingEnabled, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, 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, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, 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, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, 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, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, 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
 

Field Detail

localizationResources

protected static java.util.ResourceBundle localizationResources

logger

private static org.apache.log4j.Logger logger

KEY_ACTION_TO_COL

public static final java.lang.String KEY_ACTION_TO_COL
See Also:
Constant Field Values

KEY_ACTION_TO_ROW

public static final java.lang.String KEY_ACTION_TO_ROW
See Also:
Constant Field Values

KEY_ACTION_TO_FILTER

public static final java.lang.String KEY_ACTION_TO_FILTER
See Also:
Constant Field Values

KEY_ACTION_UP

public static final java.lang.String KEY_ACTION_UP
See Also:
Constant Field Values

KEY_ACTION_DOWN

public static final java.lang.String KEY_ACTION_DOWN
See Also:
Constant Field Values

KEY_ACTION_CLOSE

public static final java.lang.String KEY_ACTION_CLOSE
See Also:
Constant Field Values

KEY_ACTION_APPLY

public static final java.lang.String KEY_ACTION_APPLY
See Also:
Constant Field Values

NAME_COLS

public static final java.lang.String NAME_COLS

NAME_ROWS

public static final java.lang.String NAME_ROWS

NAME_FILTER

public static final java.lang.String NAME_FILTER

jTreeNavi

private javax.swing.JTree jTreeNavi

root

private CheckNode root

amScrollMenuBar

private javax.swing.ActionMap amScrollMenuBar

popup

private javax.swing.JPopupMenu popup

autoUpdate

private boolean autoUpdate
Constructor Detail

JScrollNavi

public JScrollNavi()
Las dimensiones del arbol siguen el orden del esquema

Method Detail

isAutoUpdate

public boolean isAutoUpdate()
Returns:
Returns the autoUpdate.

setAutoUpdate

public void setAutoUpdate(boolean autoUpdate)
Parameters:
autoUpdate - The autoUpdate to set.

initComponents

private void initComponents()

getRootNode

private CheckNode getRootNode()

addHierarchysTable

private void addHierarchysTable(CheckNode node,
                                int index)
                         throws java.lang.Exception
Throws:
java.lang.Exception

updateTree

public void updateTree()

updateTreeComponen

private void updateTreeComponen()

getIndexAxis

private int getIndexAxis(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
                  throws com.tonbeller.jpivot.olap.model.OlapException
Parameters:
hierarchy -
Returns:
El indice del eje en el que se encuentra la hierarchy ( o alguno de sus miembros, caso del slicer,) -1, 0, 1, 2 (No esta en ninguno, col, row, slicer ).
Throws:
com.tonbeller.jpivot.olap.model.OlapException

getMembersVisbles

private java.util.List getMembersVisbles(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
Parameters:
hierarchy -
Returns:
Una lista con los miembros visibles (usados) de ja Jerarquia por la query.

isInSlicer

private boolean isInSlicer(com.tonbeller.jpivot.olap.model.Hierarchy hierarchy)
Parameters:
hierarchy -
Returns:
true si la hierarchy esta en el Slicer

createJToolBar

private javax.swing.JToolBar createJToolBar()
Crea JToolBar e inicializa amScrollMenuBar con su ActionMap.

Returns:
la JToolBar creada.

move

private void move(CheckNode node,
                  java.lang.String nameNodo)

createPopupMenu

private javax.swing.JPopupMenu createPopupMenu(javax.swing.JTree jTree)
Crea JPopupMenu su ActionMap.

Returns:
popup

cfgPopupMenu

private void cfgPopupMenu(CheckNode nodo)
Configura jPopupMenu en funcion del nodo seleccionad.

Parameters:
nodo -

modelChanged

public void modelChanged(com.tonbeller.jpivot.core.ModelChangeEvent e)
Specified by:
modelChanged in interface com.tonbeller.jpivot.core.ModelChangeListener
See Also:
ModelChangeListener.modelChanged(com.tonbeller.jpivot.core.ModelChangeEvent)

structureChanged

public void structureChanged(com.tonbeller.jpivot.core.ModelChangeEvent e)
Specified by:
structureChanged in interface com.tonbeller.jpivot.core.ModelChangeListener
See Also:
ModelChangeListener.structureChanged(com.tonbeller.jpivot.core.ModelChangeEvent)

JRubik v0.6

JRubik v0.6