Class PMITreeView
- java.lang.Object
- 
- java.awt.Component
- 
- java.awt.Container
- 
- javax.swing.JComponent
- 
- javax.swing.JScrollPane
- 
- com.inductiveautomation.vision.api.client.components.model.AbstractVisionScrollPane
- 
- com.inductiveautomation.factorypmi.application.components.PMITreeView
 
 
 
 
 
 
- 
- All Implemented Interfaces:
- DynamicPropertyProvider,- LocaleListener,- MutableDynamicPropertyProvider,- StyleProvider,- ComponentLifecycle,- DesignerInitializable,- EnabledEx,- QualityMonitor,- VisionComponent,- java.awt.image.ImageObserver,- java.awt.MenuContainer,- java.io.Serializable,- java.util.EventListener,- javax.accessibility.Accessible,- javax.swing.event.TreeSelectionListener,- javax.swing.ScrollPaneConstants
 
 public class PMITreeView extends AbstractVisionScrollPane implements javax.swing.event.TreeSelectionListener, DesignerInitializable, EnabledEx - See Also:
- Serialized Form
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classPMITreeView.TreeViewItemConfig- 
Nested classes/interfaces inherited from class javax.swing.JScrollPanejavax.swing.JScrollPane.AccessibleJScrollPane, javax.swing.JScrollPane.ScrollBar
 - 
Nested classes/interfaces inherited from class javax.swing.JComponentjavax.swing.JComponent.AccessibleJComponent
 
- 
 - 
Field SummaryFields Modifier and Type Field Description static intANGLEDstatic java.lang.Class<?>[]COLUMN_CLASSESstatic java.lang.String[]COLUMN_NAMESstatic intHORIZONTALstatic java.lang.String[]LINE_STYLESstatic intNONEstatic java.lang.Class<?>[]REAL_COLUMN_CLASSES- 
Fields inherited from class com.inductiveautomation.vision.api.client.components.model.AbstractVisionScrollPaneantialias, context, cursorCode
 - 
Fields inherited from class javax.swing.JScrollPanecolumnHeader, horizontalScrollBar, horizontalScrollBarPolicy, lowerLeft, lowerRight, rowHeader, upperLeft, upperRight, verticalScrollBar, verticalScrollBarPolicy, viewport
 - 
Fields inherited from class javax.swing.JComponentlistenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 - 
Fields inherited from class java.awt.ComponentaccessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 - 
Fields inherited from interface com.inductiveautomation.vision.api.client.components.model.ComponentLifecycleCOMPONENT_RUNNING
 - 
Fields inherited from interface com.inductiveautomation.vision.api.client.components.model.EnabledExDISABLED_BY_PERMISSIONS
 - 
Fields inherited from interface java.awt.image.ImageObserverABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 - 
Fields inherited from interface com.inductiveautomation.ignition.client.model.LocaleListenerLOCAL_CHANGE_EVENT
 - 
Fields inherited from interface com.inductiveautomation.vision.api.client.binding.MutableDynamicPropertyProviderRESERVED_SET_KEY
 - 
Fields inherited from interface javax.swing.ScrollPaneConstantsCOLUMN_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 com.inductiveautomation.vision.api.client.components.model.VisionComponentCOMPONENT_LOCKED, COMPONENT_PERMISSIONS, COMPONENT_SECURITY, COMPONENT_TRANSLATIONS
 
- 
 - 
Constructor SummaryConstructors Constructor Description PMITreeView()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclearSelection()voidcollapseAll()voidevaluateEnabled()voidexpandAll()voidexpandNode(javax.swing.tree.TreeNode node, boolean expand)voidexpandNodeForLevel(javax.swing.tree.TreeNode rootNode, int levelsToExpand)intgetAutoExpansionLevel()java.awt.ColorgetBackground()DatasetgetData()java.awt.ColorgetDefaultBackground()javax.swing.border.BordergetDefaultBorder()javax.swing.IcongetDefaultClosedIcon()java.lang.StringgetDefaultClosedIconPath()java.awt.ColorgetDefaultForeground()javax.swing.IcongetDefaultLeafIcon()java.lang.StringgetDefaultLeafIconPath()javax.swing.IcongetDefaultOpenIcon()java.lang.StringgetDefaultOpenIconPath()java.awt.ColorgetDefaultSelectedBackground()javax.swing.border.BordergetDefaultSelectedBorder()java.awt.ColorgetDefaultSelectedForeground()java.lang.ObjectgetDefaultValue(java.lang.String col, int row)intgetLineStyle()javax.swing.tree.TreeModelgetModel()intgetRowHeight()intgetSelectedItem()Returns the index of the most recently selected node, or -1 if no node is selectedint[]getSelectedItems()Finds the row indexes of the selected tree nodes.java.lang.StringgetSelectedPath()java.lang.String[]getSelectedPaths()java.awt.ColorgetSelectionFillColor()intgetSelectionMode()java.lang.StringgetSeparationCharacter()voidinitialize()booleanisAutoExpand()booleanisAutoSort()booleanisComponentEnabled()booleanisFullWidthSelection()booleanisShowRootHandles()protected voidonStartup()Subclasses should override this to provide startup logic.voidsetAutoExpand(boolean autoExpand)voidsetAutoExpansionLevel(int startupExpansionLevel)voidsetAutoSort(boolean autoSort)voidsetBackground(java.awt.Color bg)voidsetComponentEnabled(boolean componentEnabled)voidsetData(Dataset ds)voidsetDefaultBackground(java.awt.Color defaultBackground)voidsetDefaultBorder(javax.swing.border.Border defaultBorder)voidsetDefaultClosedIconPath(java.lang.String path)voidsetDefaultForeground(java.awt.Color defaultForeground)voidsetDefaultLeafIconPath(java.lang.String path)voidsetDefaultOpenIconPath(java.lang.String path)voidsetDefaultSelectedBackground(java.awt.Color defaultSelectedBackground)voidsetDefaultSelectedBorder(javax.swing.border.Border defaultSelectedBorder)voidsetDefaultSelectedForeground(java.awt.Color defaultSelectedForeground)voidsetFont(java.awt.Font font)voidsetFullWidthSelection(boolean fullWidthSelection)voidsetLineStyle(int lineStyle)voidsetRowHeight(int rowHeight)voidsetSelectedItem(int selectedItem)voidsetSelectedItemImpl(int selectedItem, boolean alterSelection)voidsetSelectedPath(java.lang.String selectedPath)voidsetSelectionFillColor(java.awt.Color selectionFillColor)voidsetSelectionMode(int mode)voidsetSeparationCharacter(java.lang.String separationCharacter)voidsetShowRootHandles(boolean showRootHandles)voidvalueChanged(javax.swing.event.TreeSelectionEvent e)Listens to the tree selection change events in order to update the "selectedItem" property- 
Methods inherited from class com.inductiveautomation.vision.api.client.components.model.AbstractVisionScrollPanegetAppContext, getCursorCode, getDataQuality, getDynamicProps, getProperties, getPropertyValue, getQuality, getStyles, getToolTipText, initStyleListener, isAntialias, isComponentRunning, isPropertyDefined, localeChanged, onShutdown, paintChildren, paintComponent, setAntialias, setCursorCode, setDataQuality, setDynamicProps, setName, setPropertyValue, setQuality, setStyles, setToolTipText, setVisible, shutdownComponent, startupComponent, updateQuality
 - 
Methods inherited from class javax.swing.JScrollPanecreateHorizontalScrollBar, 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.JComponentaddAncestorListener, 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, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, paint, paintBorder, 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, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, unregisterKeyboardAction, update
 - 
Methods inherited from class java.awt.Containeradd, 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, transferFocusDownCycle, validate, validateTree
 - 
Methods inherited from class java.awt.Componentaction, 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, 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, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, 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, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
 
- 
 
- 
- 
- 
Field Detail- 
COLUMN_NAMESpublic static final java.lang.String[] COLUMN_NAMES 
 - 
REAL_COLUMN_CLASSESpublic static final java.lang.Class<?>[] REAL_COLUMN_CLASSES 
 - 
COLUMN_CLASSESpublic static final java.lang.Class<?>[] COLUMN_CLASSES 
 - 
LINE_STYLESpublic static final java.lang.String[] LINE_STYLES 
 - 
ANGLEDpublic static final int ANGLED - See Also:
- Constant Field Values
 
 - 
HORIZONTALpublic static final int HORIZONTAL - See Also:
- Constant Field Values
 
 - 
NONEpublic static final int NONE - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
getModelpublic javax.swing.tree.TreeModel getModel() 
 - 
getDefaultValuepublic java.lang.Object getDefaultValue(java.lang.String col, int row)
 - 
expandAllpublic void expandAll() 
 - 
collapseAllpublic void collapseAll() 
 - 
expandNodepublic void expandNode(javax.swing.tree.TreeNode node, boolean expand)
 - 
expandNodeForLevelpublic void expandNodeForLevel(javax.swing.tree.TreeNode rootNode, int levelsToExpand)
 - 
getDatapublic Dataset getData() 
 - 
setDatapublic void setData(Dataset ds) 
 - 
getSelectedItempublic int getSelectedItem() Returns the index of the most recently selected node, or -1 if no node is selected
 - 
setSelectedItempublic void setSelectedItem(int selectedItem) 
 - 
getSelectedPathpublic java.lang.String getSelectedPath() 
 - 
setSelectedPathpublic void setSelectedPath(java.lang.String selectedPath) 
 - 
setSelectedItemImplpublic void setSelectedItemImpl(int selectedItem, boolean alterSelection)
 - 
getSelectedItemspublic int[] getSelectedItems() Finds the row indexes of the selected tree nodes. Implicitly created folder nodes have no index.- Returns:
- An array of ints representing the indices of selected files. The array may be empty if only folders are selected. Not null.
 
 - 
getSelectedPathspublic java.lang.String[] getSelectedPaths() - Returns:
- Returns the paths of the selected items, including implicitly created folders. Not null.
 
 - 
clearSelectionpublic void clearSelection() 
 - 
getRowHeightpublic int getRowHeight() 
 - 
setRowHeightpublic void setRowHeight(int rowHeight) 
 - 
getLineStylepublic int getLineStyle() 
 - 
setLineStylepublic void setLineStyle(int lineStyle) 
 - 
getSelectionModepublic int getSelectionMode() 
 - 
setSelectionModepublic void setSelectionMode(int mode) 
 - 
isAutoSortpublic boolean isAutoSort() 
 - 
setAutoSortpublic void setAutoSort(boolean autoSort) 
 - 
isAutoExpandpublic boolean isAutoExpand() 
 - 
setAutoExpandpublic void setAutoExpand(boolean autoExpand) 
 - 
getAutoExpansionLevelpublic int getAutoExpansionLevel() 
 - 
setAutoExpansionLevelpublic void setAutoExpansionLevel(int startupExpansionLevel) 
 - 
isShowRootHandlespublic boolean isShowRootHandles() 
 - 
setShowRootHandlespublic void setShowRootHandles(boolean showRootHandles) 
 - 
getSeparationCharacterpublic java.lang.String getSeparationCharacter() 
 - 
setSeparationCharacterpublic void setSeparationCharacter(java.lang.String separationCharacter) 
 - 
getDefaultBackgroundpublic java.awt.Color getDefaultBackground() 
 - 
setDefaultBackgroundpublic void setDefaultBackground(java.awt.Color defaultBackground) 
 - 
getDefaultForegroundpublic java.awt.Color getDefaultForeground() 
 - 
setDefaultForegroundpublic void setDefaultForeground(java.awt.Color defaultForeground) 
 - 
getDefaultBorderpublic javax.swing.border.Border getDefaultBorder() 
 - 
setDefaultBorderpublic void setDefaultBorder(javax.swing.border.Border defaultBorder) 
 - 
getDefaultSelectedBackgroundpublic java.awt.Color getDefaultSelectedBackground() 
 - 
setDefaultSelectedBackgroundpublic void setDefaultSelectedBackground(java.awt.Color defaultSelectedBackground) 
 - 
getDefaultSelectedForegroundpublic java.awt.Color getDefaultSelectedForeground() 
 - 
setDefaultSelectedForegroundpublic void setDefaultSelectedForeground(java.awt.Color defaultSelectedForeground) 
 - 
getDefaultSelectedBorderpublic javax.swing.border.Border getDefaultSelectedBorder() 
 - 
setDefaultSelectedBorderpublic void setDefaultSelectedBorder(javax.swing.border.Border defaultSelectedBorder) 
 - 
getSelectionFillColorpublic java.awt.Color getSelectionFillColor() 
 - 
setSelectionFillColorpublic void setSelectionFillColor(java.awt.Color selectionFillColor) 
 - 
isFullWidthSelectionpublic boolean isFullWidthSelection() 
 - 
setFullWidthSelectionpublic void setFullWidthSelection(boolean fullWidthSelection) 
 - 
getDefaultClosedIconpublic javax.swing.Icon getDefaultClosedIcon() 
 - 
getDefaultLeafIconpublic javax.swing.Icon getDefaultLeafIcon() 
 - 
getDefaultOpenIconpublic javax.swing.Icon getDefaultOpenIcon() 
 - 
getDefaultLeafIconPathpublic java.lang.String getDefaultLeafIconPath() 
 - 
setDefaultLeafIconPathpublic void setDefaultLeafIconPath(java.lang.String path) 
 - 
getDefaultOpenIconPathpublic java.lang.String getDefaultOpenIconPath() 
 - 
setDefaultOpenIconPathpublic void setDefaultOpenIconPath(java.lang.String path) 
 - 
getDefaultClosedIconPathpublic java.lang.String getDefaultClosedIconPath() 
 - 
setDefaultClosedIconPathpublic void setDefaultClosedIconPath(java.lang.String path) 
 - 
valueChangedpublic void valueChanged(javax.swing.event.TreeSelectionEvent e) Listens to the tree selection change events in order to update the "selectedItem" property- Specified by:
- valueChangedin interface- javax.swing.event.TreeSelectionListener
 
 - 
initializepublic void initialize() - Specified by:
- initializein interface- DesignerInitializable
 
 - 
onStartupprotected void onStartup() Description copied from class:AbstractVisionScrollPaneSubclasses should override this to provide startup logic.- Overrides:
- onStartupin class- AbstractVisionScrollPane
 
 - 
setBackgroundpublic void setBackground(java.awt.Color bg) - Overrides:
- setBackgroundin class- javax.swing.JComponent
 
 - 
getBackgroundpublic java.awt.Color getBackground() - Overrides:
- getBackgroundin class- java.awt.Component
 
 - 
setFontpublic void setFont(java.awt.Font font) - Overrides:
- setFontin class- javax.swing.JComponent
 
 - 
isComponentEnabledpublic boolean isComponentEnabled() - Specified by:
- isComponentEnabledin interface- EnabledEx
 
 - 
setComponentEnabledpublic void setComponentEnabled(boolean componentEnabled) - Specified by:
- setComponentEnabledin interface- EnabledEx
 
 - 
evaluateEnabledpublic void evaluateEnabled() - Specified by:
- evaluateEnabledin interface- EnabledEx
 
 
- 
 
-