Class PMIMomentaryButton2
- java.lang.Object
- 
- java.awt.Component
- 
- java.awt.Container
- 
- javax.swing.JComponent
- 
- javax.swing.AbstractButton
- 
- javax.swing.JButton
- 
- com.inductiveautomation.vision.api.client.components.model.AbstractVisionButton
- 
- com.inductiveautomation.factorypmi.application.components.PMIMomentaryButton2
 
 
 
 
 
 
 
- 
- All Implemented Interfaces:
- DynamicPropertyProvider,- LocaleListener,- MutableDynamicPropertyProvider,- StyleProvider,- ComponentLifecycle,- DesignerInitializable,- EnabledEx,- QualityMonitor,- VisionComponent,- java.awt.image.ImageObserver,- java.awt.ItemSelectable,- java.awt.MenuContainer,- java.io.Serializable,- javax.accessibility.Accessible,- javax.swing.SwingConstants
 
 public class PMIMomentaryButton2 extends AbstractVisionButton implements LocaleListener, DesignerInitializable - See Also:
- Serialized Form
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description protected classPMIMomentaryButton2.PhysicalButtonReleaseEmulation- 
Nested classes/interfaces inherited from class javax.swing.JButtonjavax.swing.JButton.AccessibleJButton
 - 
Nested classes/interfaces inherited from class javax.swing.AbstractButtonjavax.swing.AbstractButton.AccessibleAbstractButton, javax.swing.AbstractButton.ButtonChangeListener
 - 
Nested classes/interfaces inherited from class javax.swing.JComponentjavax.swing.JComponent.AccessibleJComponent
 
- 
 - 
Field Summary- 
Fields inherited from class com.inductiveautomation.vision.api.client.components.model.AbstractVisionButtoncontext, cursorCode, DEFAULT_MARGIN
 - 
Fields inherited from class javax.swing.AbstractButtonactionListener, BORDER_PAINTED_CHANGED_PROPERTY, changeEvent, changeListener, CONTENT_AREA_FILLED_CHANGED_PROPERTY, DISABLED_ICON_CHANGED_PROPERTY, DISABLED_SELECTED_ICON_CHANGED_PROPERTY, FOCUS_PAINTED_CHANGED_PROPERTY, HORIZONTAL_ALIGNMENT_CHANGED_PROPERTY, HORIZONTAL_TEXT_POSITION_CHANGED_PROPERTY, ICON_CHANGED_PROPERTY, itemListener, MARGIN_CHANGED_PROPERTY, MNEMONIC_CHANGED_PROPERTY, model, MODEL_CHANGED_PROPERTY, PRESSED_ICON_CHANGED_PROPERTY, ROLLOVER_ENABLED_CHANGED_PROPERTY, ROLLOVER_ICON_CHANGED_PROPERTY, ROLLOVER_SELECTED_ICON_CHANGED_PROPERTY, SELECTED_ICON_CHANGED_PROPERTY, TEXT_CHANGED_PROPERTY, VERTICAL_ALIGNMENT_CHANGED_PROPERTY, VERTICAL_TEXT_POSITION_CHANGED_PROPERTY
 - 
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.SwingConstantsBOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 - 
Fields inherited from interface com.inductiveautomation.vision.api.client.components.model.VisionComponentCOMPONENT_LOCKED, COMPONENT_PERMISSIONS, COMPONENT_SECURITY, COMPONENT_TRANSLATIONS
 
- 
 - 
Constructor SummaryConstructors Constructor Description PMIMomentaryButton2()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddoClick(int pressTime)This override and the Emulation runnable are here so that users can emulate physical press & hold via scripting, and allow the proper setting of control values.intgetControlValue()intgetIndicatorValue()intgetIndicatorWidth()javax.swing.border.BordergetInnerBorder()intgetMaxOnTime()java.awt.ColorgetOffColor()intgetOffValue()java.awt.ColorgetOnColor()intgetOnTime()intgetOnValue()voidinitialize()booleanisActive()voidlocaleChanged(java.util.Locale newLocale)voidsetActive(boolean active)voidsetControlValue(int value)voidsetIndicatorValue(int indicatorValue)voidsetIndicatorWidth(int padding)voidsetInnerBorder(javax.swing.border.Border innerBorder)voidsetMaxOnTime(int maxOnTime)voidsetOffColor(java.awt.Color offColor)voidsetOffValue(int offValue)voidsetOnColor(java.awt.Color onColor)voidsetOnTime(int onTime)voidsetOnValue(int onValue)java.lang.StringtoString()- 
Methods inherited from class com.inductiveautomation.vision.api.client.components.model.AbstractVisionButtonevaluateEnabled, getAppContext, getButtonBG, getCursorCode, getDataQuality, getDisabledPath, getDynamicProps, getMnemonicChar, getPath, getProperties, getPropertyValue, getQuality, getStyles, getText, getToolTipText, isBackground3D, isComponentEnabled, isPropertyDefined, onShutdown, onStartup, paintChildren, setAntialias, setBackground3D, setBorderPainted, setButtonBG, setComponentEnabled, setCursorCode, setDataQuality, setDisabledPath, setDynamicProps, setEnabled, setMnemonicChar, setName, setPath, setPropertyValue, setQuality, setStyles, setText, setToolTipText, setVisible, shutdownComponent, startupComponent, updateQuality
 - 
Methods inherited from class javax.swing.JButtongetAccessibleContext, getUIClassID, isDefaultButton, isDefaultCapable, paramString, removeNotify, setDefaultCapable, updateUI
 - 
Methods inherited from class javax.swing.AbstractButtonactionPropertyChanged, addActionListener, addChangeListener, addImpl, addItemListener, checkHorizontalKey, checkVerticalKey, configurePropertiesFromAction, createActionListener, createActionPropertyChangeListener, createChangeListener, createItemListener, doClick, fireActionPerformed, fireItemStateChanged, fireStateChanged, getAction, getActionCommand, getActionListeners, getChangeListeners, getDisabledIcon, getDisabledSelectedIcon, getDisplayedMnemonicIndex, getHideActionText, getHorizontalAlignment, getHorizontalTextPosition, getIcon, getIconTextGap, getItemListeners, getLabel, getMargin, getMnemonic, getModel, getMultiClickThreshhold, getPressedIcon, getRolloverIcon, getRolloverSelectedIcon, getSelectedIcon, getSelectedObjects, getUI, getVerticalAlignment, getVerticalTextPosition, imageUpdate, init, isBorderPainted, isContentAreaFilled, isFocusPainted, isRolloverEnabled, isSelected, paintBorder, removeActionListener, removeChangeListener, removeItemListener, setAction, setActionCommand, setContentAreaFilled, setDisabledIcon, setDisabledSelectedIcon, setDisplayedMnemonicIndex, setFocusPainted, setHideActionText, setHorizontalAlignment, setHorizontalTextPosition, setIcon, setIconTextGap, setLabel, setLayout, setMargin, setMnemonic, setMnemonic, setModel, setMultiClickThreshhold, setPressedIcon, setRolloverEnabled, setRolloverIcon, setRolloverSelectedIcon, setSelected, setSelectedIcon, setUI, setVerticalAlignment, setVerticalTextPosition
 - 
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, isValidateRoot, paint, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, 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, 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, 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, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, 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, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycle
 
- 
 
- 
- 
- 
Method Detail- 
initializepublic void initialize() - Specified by:
- initializein interface- DesignerInitializable
 
 - 
doClickpublic void doClick(int pressTime) This override and the Emulation runnable are here so that users can emulate physical press & hold via scripting, and allow the proper setting of control values. We attempt the doPress() and then stage an invokeLater to run the release() functionality.- Overrides:
- doClickin class- javax.swing.AbstractButton
- Parameters:
- pressTime- the duration that a button press should be simulated
 
 - 
toStringpublic java.lang.String toString() - Overrides:
- toStringin class- java.awt.Component
 
 - 
getOnTimepublic int getOnTime() 
 - 
setOnTimepublic void setOnTime(int onTime) 
 - 
getMaxOnTimepublic int getMaxOnTime() 
 - 
setMaxOnTimepublic void setMaxOnTime(int maxOnTime) 
 - 
getOnValuepublic int getOnValue() 
 - 
setOnValuepublic void setOnValue(int onValue) 
 - 
getOffValuepublic int getOffValue() 
 - 
setOffValuepublic void setOffValue(int offValue) 
 - 
getControlValuepublic int getControlValue() 
 - 
setControlValuepublic void setControlValue(int value) 
 - 
getIndicatorValuepublic int getIndicatorValue() 
 - 
setIndicatorValuepublic void setIndicatorValue(int indicatorValue) 
 - 
isActivepublic boolean isActive() 
 - 
setActivepublic void setActive(boolean active) 
 - 
getIndicatorWidthpublic int getIndicatorWidth() 
 - 
setIndicatorWidthpublic void setIndicatorWidth(int padding) 
 - 
localeChangedpublic void localeChanged(java.util.Locale newLocale) - Specified by:
- localeChangedin interface- LocaleListener
- Overrides:
- localeChangedin class- AbstractVisionButton
 
 - 
getInnerBorderpublic javax.swing.border.Border getInnerBorder() 
 - 
setInnerBorderpublic void setInnerBorder(javax.swing.border.Border innerBorder) 
 - 
getOnColorpublic java.awt.Color getOnColor() 
 - 
setOnColorpublic void setOnColor(java.awt.Color onColor) 
 - 
getOffColorpublic java.awt.Color getOffColor() 
 - 
setOffColorpublic void setOffColor(java.awt.Color offColor) 
 
- 
 
-