Class Boundary
- java.lang.Object
-
- gov.nasa.worldwind.avlist.AVListImpl
-
- gov.nasa.worldwind.symbology.AbstractTacticalGraphic
-
- gov.nasa.worldwind.symbology.milstd2525.AbstractMilStd2525TacticalGraphic
-
- gov.nasa.worldwind.symbology.milstd2525.graphics.lines.PhaseLine
-
- gov.nasa.worldwind.symbology.milstd2525.graphics.lines.Boundary
-
- All Implemented Interfaces:
AVList
,Draggable
,Movable
,Highlightable
,Renderable
,MilStd2525TacticalGraphic
,TacticalGraphic
public class Boundary extends PhaseLine
Implementation of the Boundary graphic (2.X.2.1.2.1).
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
additionalText
The value of an optional second text string for the graphic.protected static Offset
BOTTOM_LABEL_OFFSET
Offset applied to the graphic's lower label.protected java.util.List<EchelonSymbol>
echelonSymbols
Tactical symbols used to render the echelon modifiers.protected boolean
haveBottomLabel
Indicates whether or not there are labels below the boundary line.protected boolean
haveHostileLabels
Indicates whether or not there are hostile indicator labels ("ENY") along the line.protected boolean
haveTopLabel
Indicates whether or not there are labels above the boundary line.protected TacticalSymbolAttributes
symbolAttributes
Attribute bundle for the echelon symbols.protected static Offset
TOP_LABEL_OFFSET
Offset applied to the graphic's upper label.-
Fields inherited from class gov.nasa.worldwind.symbology.milstd2525.graphics.lines.PhaseLine
path, PLD_OUTLINE_STIPPLE_FACTOR
-
Fields inherited from class gov.nasa.worldwind.symbology.milstd2525.AbstractMilStd2525TacticalGraphic
maskedSymbolCode, OUTLINE_STIPPLE_FACTOR_ANTICIPATED, OUTLINE_STIPPLE_FACTOR_PRESENT, OUTLINE_STIPPLE_PATTERN, symbolCode
-
Fields inherited from class gov.nasa.worldwind.symbology.AbstractTacticalGraphic
activeOverrides, activeShapeAttributes, DEFAULT_HIGHLIGHT_MATERIAL, DEFAULT_LABEL_INTERIOR_OPACITY, delegateOwner, dragEnabled, draggableSupport, frameTimestamp, highlightAttributes, highlighted, labelOffset, labels, modifiers, mustCreateLabels, normalAttributes, showGraphicModifiers, showHostileIndicator, showLocation, showTextModifiers, text, unitsFormat, visible
-
-
Constructor Summary
Constructors Constructor Description Boundary(java.lang.String sidc)
Create a new Boundary.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
applyDelegateOwner(java.lang.Object owner)
Invoked each frame to apply to the current delegate owner to all renderable objects used to draw the graphic.protected EchelonSymbol
createEchelonSymbol(java.lang.String sidc)
Create a tactical symbol to render the echelon modifier.protected void
createLabels()
Create labels for the start and end of the path.protected void
determineActiveAttributes()
Determine active attributes for this frame.protected void
determineLabelPositions(DrawContext dc)
Determine positions for the start and end labels.protected void
doRenderGraphicModifiers(DrawContext dc)
Render the graphic modifiers.java.lang.String
getAdditionalText()
Indicates an additional text identification for this graphic.protected Offset
getBottomLabelOffset()
Indicates the offset applied to the lower label.protected Offset
getDefaultLabelOffset()
Indicates the default offset applied to the graphic's main label.java.lang.Object
getModifier(java.lang.String key)
Indicates the current value of a text or graphic modifier.static java.util.List<java.lang.String>
getSupportedGraphics()
Indicates the graphics supported by this class.protected Offset
getTopLabelOffset()
Indicates the offset applied to the upper label.protected boolean
mustCreateIdentityLabels()
void
setAdditionalText(java.lang.String text)
Indicates an additional text identification for this graphic.void
setModifier(java.lang.String key, java.lang.Object value)
Specifies the value of a text or graphic modifier.-
Methods inherited from class gov.nasa.worldwind.symbology.milstd2525.graphics.lines.PhaseLine
applyDefaultAttributes, createPath, doRenderGraphic, getGraphicLabel, getPositions, getReferencePosition, setPositions
-
Methods inherited from class gov.nasa.worldwind.symbology.milstd2525.AbstractMilStd2525TacticalGraphic
createSymbol, getDefaultMaterial, getIdentifier, getOutlineStippleFactor, getOutlineStipplePattern, getStatus, getText, mustShowHostileIndicator, setStatus
-
Methods inherited from class gov.nasa.worldwind.symbology.AbstractTacticalGraphic
addLabel, applyLabelAttributes, applyOverrideAttributes, computeGeometry, computeLabelInteriorOpacity, determineDelegateOwner, determinePerFrameAttributes, doDrag, doRenderTextModifiers, drag, getActiveDelegateOwner, getActiveOverrideAttributes, getActiveShapeAttributes, getAttributes, getDelegateOwner, getHighlightAttributes, getLabelMaterial, getLabelOffset, getUnitsFormat, isDragEnabled, isHighlighted, isShowGraphicModifiers, isShowHostileIndicator, isShowLocation, isShowTextModifiers, isVisible, move, moveTo, onModifierChanged, render, setAttributes, setDelegateOwner, setDragEnabled, setHighlightAttributes, setHighlighted, setLabelOffset, setShowGraphicModifiers, setShowHostileIndicator, setShowLocation, setShowTextModifiers, setText, setUnitsFormat, setVisible
-
Methods inherited from class gov.nasa.worldwind.avlist.AVListImpl
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getBooleanValue, getBooleanValue, getChangeSupport, getDoubleValue, getDoubleValue, getEntries, getIntegerValue, getIntegerValue, getLongValue, getLongValue, getRestorableStateForAVPair, getStringValue, getStringValue, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues
-
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface gov.nasa.worldwind.avlist.AVList
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getEntries, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues
-
Methods inherited from interface gov.nasa.worldwind.render.Highlightable
isHighlighted, setHighlighted
-
Methods inherited from interface gov.nasa.worldwind.render.Renderable
render
-
Methods inherited from interface gov.nasa.worldwind.symbology.TacticalGraphic
getAttributes, getDelegateOwner, getHighlightAttributes, getLabelOffset, getUnitsFormat, isShowGraphicModifiers, isShowHostileIndicator, isShowLocation, isShowTextModifiers, isVisible, setAttributes, setDelegateOwner, setHighlightAttributes, setLabelOffset, setShowGraphicModifiers, setShowHostileIndicator, setShowLocation, setShowTextModifiers, setText, setUnitsFormat, setVisible
-
-
-
-
Field Detail
-
TOP_LABEL_OFFSET
protected static final Offset TOP_LABEL_OFFSET
Offset applied to the graphic's upper label. This offset aligns the bottom edge of the label with the geographic position, in order to keep the label above the graphic as the zoom changes.
-
BOTTOM_LABEL_OFFSET
protected static final Offset BOTTOM_LABEL_OFFSET
Offset applied to the graphic's lower label. This offset aligns the top edge of the label with the geographic position, in order to keep the label above the graphic as the zoom changes.
-
echelonSymbols
protected java.util.List<EchelonSymbol> echelonSymbols
Tactical symbols used to render the echelon modifiers.
-
symbolAttributes
protected TacticalSymbolAttributes symbolAttributes
Attribute bundle for the echelon symbols.
-
haveTopLabel
protected boolean haveTopLabel
Indicates whether or not there are labels above the boundary line.
-
haveBottomLabel
protected boolean haveBottomLabel
Indicates whether or not there are labels below the boundary line.
-
haveHostileLabels
protected boolean haveHostileLabels
Indicates whether or not there are hostile indicator labels ("ENY") along the line.
-
additionalText
protected java.lang.String additionalText
The value of an optional second text string for the graphic. This value is equivalent to the "T1" modifier defined by MIL-STD-2525C. It can be set usingsetAdditionalText(String)
, or by passing an Iterable tosetModifier(String, Object)
with a key ofSymbologyConstants.UNIQUE_DESIGNATION
(additional text is the second value in the iterable).
-
-
Method Detail
-
getSupportedGraphics
public static java.util.List<java.lang.String> getSupportedGraphics()
Indicates the graphics supported by this class.- Returns:
- List of masked SIDC strings that identify graphics that this class supports.
-
getAdditionalText
public java.lang.String getAdditionalText()
Indicates an additional text identification for this graphic. This value is equivalent to the "T1" modifier in MIL-STD-2525C (a second Unique Designation modifier).- Returns:
- The additional text. May be null.
-
setAdditionalText
public void setAdditionalText(java.lang.String text)
Indicates an additional text identification for this graphic. Setting this value is equivalent to setting the "T1" modifier in MIL-STD-2525C (a second Unique Designation modifier).- Parameters:
text
- The additional text. May be null.
-
getModifier
public java.lang.Object getModifier(java.lang.String key)
Description copied from class:AbstractMilStd2525TacticalGraphic
Indicates the current value of a text or graphic modifier.- Specified by:
getModifier
in interfaceTacticalGraphic
- Overrides:
getModifier
in classAbstractMilStd2525TacticalGraphic
- Parameters:
key
- Key that identifies the modifier to retrieve. The possible modifiers depends on the symbol set.- Returns:
- The value of the modifier, or
null
if the modifier is not set.
-
setModifier
public void setModifier(java.lang.String key, java.lang.Object value)
Description copied from class:AbstractMilStd2525TacticalGraphic
Specifies the value of a text or graphic modifier.- Specified by:
setModifier
in interfaceTacticalGraphic
- Overrides:
setModifier
in classAbstractMilStd2525TacticalGraphic
- Parameters:
key
- Key that identifies the modifier to set. The possible modifiers depends on the symbol set.value
- New value for the modifier.
-
doRenderGraphicModifiers
protected void doRenderGraphicModifiers(DrawContext dc)
Render the graphic modifiers. This base class does not render anything, but subclasses may override this method to draw graphic modifiers. Overridden to render the echelon modifier.- Overrides:
doRenderGraphicModifiers
in classAbstractTacticalGraphic
- Parameters:
dc
- Current draw context.
-
createLabels
protected void createLabels()
Create labels for the start and end of the path.- Overrides:
createLabels
in classPhaseLine
-
mustCreateIdentityLabels
protected boolean mustCreateIdentityLabels()
-
determineLabelPositions
protected void determineLabelPositions(DrawContext dc)
Determine positions for the start and end labels.- Overrides:
determineLabelPositions
in classPhaseLine
- Parameters:
dc
- Current draw context.
-
applyDelegateOwner
protected void applyDelegateOwner(java.lang.Object owner)
Invoked each frame to apply to the current delegate owner to all renderable objects used to draw the graphic. This base class will apply the delegate owner to Label objects. Subclasses must implement this method to apply the delegate owner to any Renderables that they will draw in order to render the graphic. Overridden to apply owner to echelon modifiers.- Overrides:
applyDelegateOwner
in classPhaseLine
- Parameters:
owner
- Current delegate owner.
-
getDefaultLabelOffset
protected Offset getDefaultLabelOffset()
Indicates the default offset applied to the graphic's main label. This offset may be overridden by the graphic attributes.- Overrides:
getDefaultLabelOffset
in classAbstractTacticalGraphic
- Returns:
- Offset to apply to the main label.
-
getTopLabelOffset
protected Offset getTopLabelOffset()
Indicates the offset applied to the upper label.- Returns:
- Offset applied to the upper label.
-
getBottomLabelOffset
protected Offset getBottomLabelOffset()
Indicates the offset applied to the lower label.- Returns:
- Offset applied to the bottom label.
-
determineActiveAttributes
protected void determineActiveAttributes()
Determine active attributes for this frame. Overridden to update echelon symbol attributes.- Overrides:
determineActiveAttributes
in classAbstractTacticalGraphic
-
createEchelonSymbol
protected EchelonSymbol createEchelonSymbol(java.lang.String sidc)
Create a tactical symbol to render the echelon modifier.- Parameters:
sidc
- Identifier for the symbol.- Returns:
- A symbol to render the echelon modifier.
-
-