Package xal.extension.widgets.olmplot
Class TrajectoryGraph
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
xal.extension.widgets.plot.FunctionGraphsJPanel
xal.extension.widgets.olmplot.TrajectoryGraph
- All Implemented Interfaces:
MouseListener
,MouseMotionListener
,ImageObserver
,MenuContainer
,Serializable
,EventListener
,Accessible
Represents a graph of an online model simulation solution. The graph will
display the horizontal, vertical, and longitudinal RMS envelopes (see
EnvelopeCurve
), particle positions (see
ParticleCurve
), or any other object derived from
BasicGraphData
.- Since:
- Nov 26, 2012
- Author:
- Christopher K. Allen
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class xal.extension.widgets.plot.FunctionGraphsJPanel
FunctionGraphsJPanel.ClickedPoint
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
-
Field Summary
Fields inherited from class xal.extension.widgets.plot.FunctionGraphsJPanel
HORIZONTAL, LEGEND_POSITION_ARBITRARY, LEGEND_POSITION_BOTTOM_LEFT, LEGEND_POSITION_BOTTOM_RIGHT, LEGEND_POSITION_TOP_LEFT, LEGEND_POSITION_TOP_RIGHT, STRING_DEC_FORMAT, VERTICAL
Fields inherited from class javax.swing.JComponent
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
accessibleContext, 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
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addGraphData
(PLANE plane, BasicGraphData crvTrj) Adds a new curve to the trajectory graph for the give plane.static TrajectoryGraph
Creates a new graph object of the RMS envelope solution contained in the given trajectory.static TrajectoryGraph
Creates a new graph object of the particle trajectory contained in the givenTrajectory
object.Methods inherited from class xal.extension.widgets.plot.FunctionGraphsJPanel
addChooseListener, addCurveData, addCurveData, addDraggedHorLinesListener, addDraggedVerLinesListener, addGraphData, addGraphData, addHorizontalLine, addHorizontalLine, addHorLimitsListener, addVerLimitsListener, addVerticalLine, addVerticalLine, clearZoomStack, getAllCurveData, getAllGraphData, getBorderBackGroundColor, getClickedPointObject, getColorSurfaceData, getCurrentGL, getCurrentMaxX, getCurrentMaxY, getCurrentMinX, getCurrentMinY, getCurveData, getDraggedLineIndex, getExternalGL, getGraphBackGroundColor, getGraphChosenIndex, getGraphColor, getGraphsDefaultColor, getGridLinesVisibleX, getGridLinesVisibleY, getHorizontalValue, getHorLimitsListeners, getInnerMaxX, getInnerMaxY, getInnerMinX, getInnerMinY, getInstanceOfGraphData, getLegendKeyString, getName, getNewGridLimits, getNumberOfHorizontalLines, getNumberOfInstanceOfGraphData, getNumberOfVerticalLines, getNumbTotalGraphPoints, getPointChosenIndex, getPointChosenX, getPointChosenY, getScreenX, getScreenY, getVerLimitsListeners, getVerticalValue, isLegendVisible, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, paintComponent, refreshGraphJPanel, removeAllCurveData, removeAllGraphData, removeColorForAllGraphs, removeCurveData, removeCurveData, removeGraphData, removeGraphData, removeGraphData, removeHorizontalValue, removeHorizontalValues, removeHorLimitsListener, removeVerLimitsListener, removeVerticalValue, removeVerticalValues, resetGraphsDefaultColor, setAxisNameColorX, setAxisNameColorY, setAxisNameFontX, setAxisNameFontY, setAxisNames, setAxisNameX, setAxisNameY, setBorderBackGroundColor, setChooseModeButtonVisible, setChoosingGraphMode, setColorSurfaceData, setCurveData, setDisplayGraphMode, setDraggedHorLinesMotionListen, setDraggedVerLinesMotionListen, setDraggingHorLinesGraphMode, setDraggingVerLinesGraphMode, setExternalGL, setGraphBackGroundColor, setGraphColor, setGraphData, setGraphLineChoosenColor, setGraphsDefaultColor, setGridLineColor, setGridLinesVisibleX, setGridLinesVisibleY, setHorizontalLineColor, setHorizontalLineValue, setHorLinesButtonVisible, setLegendBackground, setLegendButtonVisible, setLegendColor, setLegendFont, setLegendKeyString, setLegendPosition, setLegendVisible, setLimitsAndTicksX, setLimitsAndTicksX, setLimitsAndTicksX, setLimitsAndTicksX, setLimitsAndTicksY, setLimitsAndTicksY, setLimitsAndTicksY, setLimitsAndTicksY, setMakrsScaleX, setMakrsScaleY, setName, setNameColor, setNameFont, setNumberColor, setNumberFont, setNumberFormatX, setNumberFormatY, setOffScreenImageDrawing, setSmartGL, setVerLinesButtonVisible, setVerticalLineColor, setVerticalLineValue, xMarkersOn, yMarkersOn
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, 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, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, 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, 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, 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, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Method Details
-
createParticleGraph
public static TrajectoryGraph createParticleGraph(Trajectory<ParticleProbeState> trjPar) throws IllegalArgumentException Creates a new graph object of the particle trajectory contained in the givenTrajectory
object.- Parameters:
trjPar
- trajectory object containing particle coordinate positions as function of beamline position- Returns:
- graph with curves showing particle positions in each phase plane
- Throws:
IllegalArgumentException
- the argument is not a particle trajectory object- Since:
- Nov 26, 2012
-
createEnvelopeGraph
public static TrajectoryGraph createEnvelopeGraph(Trajectory<EnvelopeProbeState> trjEnv) throws IllegalArgumentException Creates a new graph object of the RMS envelope solution contained in the given trajectory.- Parameters:
trjEnv
- trajectory object containing envelope solution- Returns:
- graph with curves showing envelope trajectory for each phase plane
- Throws:
IllegalArgumentException
- the argument is not an envelope trajectory object- Since:
- Nov 26, 2012
-
addGraphData
Adds a new curve to the trajectory graph for the give plane. The curve type need only be derived fromBasicGraphData
so this is a general object.- Parameters:
plane
- the curve will display under this phase plane characteristicscrvTrj
- the curve being displayed- Since:
- Apr 18, 2013
-