public class LineOfSightPane extends javax.swing.JPanel implements GpsDataListener, TrackerListener, java.io.Closeable
| Modifier and Type | Class and Description |
|---|---|
static interface |
LineOfSightPane.AGLChangeListener
Define a callback so other data structures can be updated when one of the
AGL sliders is manually updated by the user.
|
javax.swing.JPanel.AccessibleJPaneljavax.swing.JComponent.AccessibleJComponentlistenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW| Constructor and Description |
|---|
LineOfSightPane(double lat,
double lon,
boolean isStartPos,
GeoMapGuiIfc geoMap)
Create a LineOfSightPane originated at the specified coordinates.
|
LineOfSightPane(double lat,
double lon,
boolean isStartPos,
java.lang.String name,
GeoMapGuiIfc geoMap)
Create a LineOfSightPane originated at the specified coordinates.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addAGLChangeListener(LineOfSightPane.AGLChangeListener l)
Register a new AGLChangeListener against this LineOfSightPane.
|
void |
close()
Closes this pane and releases any system resources associated
with it.
|
DrawExtraOnLineOfSight |
getDrawExtraOnLineOfSight()
Get the current extension for drawing the line of sight plot.
|
java.awt.geom.Point2D |
getEndPoint()
Get the ending coordinates.
|
java.awt.geom.Point2D |
getStartPoint()
Get the starting coordinates.
|
void |
gpsDataUpdated(GPSDistributor distributor,
GpsFix currentFix,
boolean isLocal,
java.lang.String source)
Called by the GPSDistributor when the GPS data has been updated.
|
void |
messageAdded(StationState ss,
int index,
AX25Message msg)
Called when a AX25Message is added to the history for a station in the tracker.
|
void |
messageDeleted(StationState ss,
int index,
AX25Message msg)
Called when a AX25Message is deleted from the history for a station in the tracker.
|
protected void |
recalculateDistanceLabel(java.awt.geom.Point2D pt,
java.awt.geom.Point2D endPoint) |
void |
registerMapKeystrokeActions()
Register the keystrokes that can be used to move this object's associated
map around.
|
void |
removeAGLChangeListener(LineOfSightPane.AGLChangeListener l)
Unregister a new AGLChangeListener from this LineOfSightPane.
|
void |
satDataUpdated(GPSDistributor distributor,
SatelliteCatalog satCatalog,
boolean isLocal,
java.lang.String source)
Called when the satellite constellation in use changes.
|
void |
setDrawExtraOnLineOfSight(DrawExtraOnLineOfSight drawExtraOnLineOfSight)
Set the current extension for drawing the line of sight plot.
|
void |
setEndAGLM(float aglM)
Change the ending point's antenna altitude above ground level.
|
void |
setEndName(java.lang.String name)
Set the name for the ending position.
|
void |
setEndPoint(java.awt.geom.Point2D pt)
Change the ending point of the line of sight path.
|
void |
setRemoteStation(StationState remoteStation)
Specify the remote station to be tracked on the right side of the pane.
|
void |
setStartAGLM(float aglM)
Change the starting point's antenna altitude above ground level.
|
void |
setStartName(java.lang.String name)
Set the name for the starting position.
|
void |
setStartPoint(java.awt.geom.Point2D pt)
Change the starting point of the line of sight path.
|
void |
stationAdded(StationState ss,
int index)
Called when a new station is initially added to the tracker.
|
void |
stationDeleted(StationState ss,
int index)
Called when an existing station is deleted from the tracker.
|
void |
stationUpdated(StationState ss)
Called when an existing station is updated with new information in the tracker.
|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIaddAncestorListener, 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, 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, updateadd, 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, validateTreeaction, 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, 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, transferFocusBackward, transferFocusUpCyclepublic LineOfSightPane(double lat,
double lon,
boolean isStartPos,
GeoMapGuiIfc geoMap)
lat - endpoint latitude in degrees Northlon - endpoint longitude in degrees EastisStartPos - boolean true if passed coordinate is the first coordinate, false if secondgeoMap - GeoMapGuiIfc window parenting the dialog containing this panepublic LineOfSightPane(double lat,
double lon,
boolean isStartPos,
java.lang.String name,
GeoMapGuiIfc geoMap)
lat - endpoint latitude in degrees Northlon - endpoint longitude in degrees EastisStartPos - boolean true if passed coordinate is the first coordinate, false if secondname - String name of specified end-pointgeoMap - GeoMapGuiIfc window parenting the dialog containing this panepublic java.awt.geom.Point2D getStartPoint()
public void setStartPoint(java.awt.geom.Point2D pt)
pt - Point2D containing the latitude and longitude of the starting pointprotected void recalculateDistanceLabel(java.awt.geom.Point2D pt,
java.awt.geom.Point2D endPoint)
public java.awt.geom.Point2D getEndPoint()
public void setEndPoint(java.awt.geom.Point2D pt)
pt - Point2D containing the latitude and longitude of the ending pointpublic void setStartAGLM(float aglM)
aglM - float endpoint antenna altitude in meters above local ground levelpublic void setEndAGLM(float aglM)
aglM - float endpoint antenna altitude in meters above local ground levelpublic void setStartName(java.lang.String name)
name - String name for starting positionpublic void setEndName(java.lang.String name)
name - String name for ending positionpublic void setRemoteStation(StationState remoteStation)
remoteStation - StationState of possibly mobile station to anchor one end of the plotpublic void addAGLChangeListener(LineOfSightPane.AGLChangeListener l)
l - AGLChangeListener to notify of GUI control changespublic void removeAGLChangeListener(LineOfSightPane.AGLChangeListener l)
l - AGLChangeListener to stop notifying of GUI control changespublic void gpsDataUpdated(GPSDistributor distributor, GpsFix currentFix, boolean isLocal, java.lang.String source)
GpsDataListenergpsDataUpdated in interface GpsDataListenerdistributor - instance of the GPSDistributorcurrentFix - current position data reported by the local GPSisLocal - boolean true if this is GPS data for the local station, false if for a remote GPS receiversource - String name assigned to remote GPS receiver, or null if for the local receiverpublic void satDataUpdated(GPSDistributor distributor, SatelliteCatalog satCatalog, boolean isLocal, java.lang.String source)
GpsDataListenersatDataUpdated in interface GpsDataListenerdistributor - instance of the GPSDistributorsatCatalog - updated SatelliteCatalog instanceisLocal - boolean true if this is GPS data for the local station, false if for a remote GPS receiversource - String name assigned to remote GPS receiver, or null if for the local receiverpublic void stationAdded(StationState ss, int index)
TrackerListenerstationAdded in interface TrackerListenerss - StationState containing the station's information; the initial AX25Message
will not yet be stored within the StationState objectindex - zero-based integer sequence number for this station in the StationTrackerpublic void stationUpdated(StationState ss)
TrackerListenerstationUpdated in interface TrackerListenerss - StationState containing the station's informationpublic void stationDeleted(StationState ss, int index)
TrackerListenerstationDeleted in interface TrackerListenerss - StationState containing the station's informationindex - zero-based integer sequence number for this station in the StationTrackerpublic void messageAdded(StationState ss, int index, AX25Message msg)
TrackerListenermessageAdded in interface TrackerListenerss - StationState containing the station's informationindex - zero-based index of the message added to the StationState objectmsg - APRS Message object being added to the tracker; note that non-APRS packets
that can still be decoded (such as OpenTRAC) will also be passed
here; AX25Frames that cannot be decoded will pass null herepublic void messageDeleted(StationState ss, int index, AX25Message msg)
TrackerListenermessageDeleted in interface TrackerListenerss - StationState containing the station's information; the AX25Message
will already be removed from the StationState objectindex - zero-based index of the message removed from the StationState objectmsg - APRS Message object being removed from the tracker; note that non-APRS packets
that can still be decoded (such as OpenTRAC) will also be passed
here; AX25Frames that cannot be decoded will pass null herepublic void close()
close in interface java.io.Closeableclose in interface java.lang.AutoCloseablepublic void registerMapKeystrokeActions()
public DrawExtraOnLineOfSight getDrawExtraOnLineOfSight()
public void setDrawExtraOnLineOfSight(DrawExtraOnLineOfSight drawExtraOnLineOfSight)
drawExtraOnLineOfSight - active DrawExtraOnLineOfSight implementation, or null if no extension