|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nasa.worldwind.symbology.AbstractIconRetriever
gov.nasa.worldwind.symbology.milstd2525.MilStd2525PointGraphicRetriever
public class MilStd2525PointGraphicRetriever
Retriever to fetch icons for MIL-STD-2525C point graphics. The retriever can fetch images from either local or remote locations. See Offline Use for information on how to set the icon retrieval location.
The retriever base URL must identify a location on a local or remote file system (including zip and jar files) that holds the icon files in an expected directory structure. Each icon URL is constructed from three parts: [base]/icons/[scheme]/[sidc].png. Parts of the SIDC that do not identify a type of graphic (such as echelon, status, standard identity, order of battle, etc.) are replaced with hyphens. For example, the Underwater Datum graphic (2.X.2.1.1.1.1.1) will be retrieved from this URL: [base]/icons/tacgrp/g-g-gpuud------.png An application should only use this class directly if it needs to access point graphics independent of theTacticalGraphic system (for example, to populate a UI independent of the globe).
| Field Summary | |
|---|---|
protected static String |
DIR_FILL_TACGRP
Subdirectory for fill graphics. |
protected static String |
DIR_ICON_EMS
Subdirectory for graphics in the Emergency Management scheme. |
protected static String |
DIR_ICON_METOC
Subdirectory for graphics in the Meteorological and Oceanographic scheme. |
protected static String |
DIR_ICON_TACGRP
Subdirectory for graphics in the Tactical Graphics scheme. |
protected static String |
PATH_SUFFIX
Suffix added to file names to indicate the file type. |
| Fields inherited from class gov.nasa.worldwind.symbology.AbstractIconRetriever |
|---|
retrieverPath |
| Constructor Summary | |
|---|---|
MilStd2525PointGraphicRetriever(String retrieverPath)
Create a new retriever that will retrieve icons from the specified location. |
|
| Method Summary | |
|---|---|
protected String |
composeFilename(SymbolCode code)
Indicates the filename of the icon for a graphic. |
protected String |
composeFilenameEms(SymbolCode code)
Indicates the filename of a graphic in the Emergency Management scheme (MIL-STD-2525C Appendix G). |
protected String |
composeFilenameMetoc(SymbolCode code)
Indicates the filename of a graphic in the Meteorological and Oceanographic scheme (MIL-STD-2525C Appendix C). |
protected String |
composeFilenameTacticalGraphic(SymbolCode code,
String dir)
Indicates the filename of a graphic in the Tactical Graphics scheme (MIL-STD-2525C Appendix B). |
protected BufferedImage |
composeFilledImage(BufferedImage srcImg,
SymbolCode symbolCode)
Create an image by drawing over a fill image. |
protected String |
composeFillPath(SymbolCode code)
Compose a file path to the fill icon for a graphic. |
BufferedImage |
createIcon(String sidc,
AVList params)
Create an icon for a MIL-STD-2525C point graphic. |
protected Color |
getColorForStandardIdentity(SymbolCode code)
Indicates the color to apply to a graphic based on the graphic's standard identity. |
protected Color |
getColorFromParams(AVList params)
Retrieves the value of the AVKey.COLOR parameter. |
protected boolean |
mustDrawFill(SymbolCode code)
Indicates whether or not a fill must be drawn for a graphic. |
| Methods inherited from class gov.nasa.worldwind.symbology.AbstractIconRetriever |
|---|
drawImage, equals, getRetrieverPath, hashCode, multiply, readImage, replaceColor |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final String DIR_FILL_TACGRP
protected static final String DIR_ICON_EMS
protected static final String DIR_ICON_METOC
protected static final String DIR_ICON_TACGRP
protected static final String PATH_SUFFIX
| Constructor Detail |
|---|
public MilStd2525PointGraphicRetriever(String retrieverPath)
retrieverPath - File path or URL to the symbol directory, for example "http://myserver.com/milstd2525/".| Method Detail |
|---|
protected String composeFilename(SymbolCode code)
code - Code that identifies a graphic in MIL-STD-2525C.
protected String composeFilenameEms(SymbolCode code)
code - Code that identifies a graphic in the EMS scheme.
protected String composeFilenameMetoc(SymbolCode code)
code - Code that identifies a graphic in the Metoc scheme.
protected String composeFilenameTacticalGraphic(SymbolCode code,
String dir)
code - Code that identifies a graphic in the Tactical Graphics scheme.dir - Directory to prepend to file name.
protected BufferedImage composeFilledImage(BufferedImage srcImg,
SymbolCode symbolCode)
srcImg - Image to draw over fill.symbolCode - Symbol code that identifies the graphic.
srcImg drawn over the appropriate fill.protected String composeFillPath(SymbolCode code)
code - Code the identifies the graphic.
public BufferedImage createIcon(String sidc,
AVList params)
sidc - SIDC identifier for the symbol.params - Parameters that affect icon retrieval. This retriever accepts only one parameter: AVKey.COLOR,
which determines the color of the image. By default the color will be determined from the standard
identity.
protected Color getColorForStandardIdentity(SymbolCode code)
code - Symbol code that identifies the graphic.
protected Color getColorFromParams(AVList params)
params - Parameter list.
protected boolean mustDrawFill(SymbolCode code)
code - Symbol code of a point graphic.
|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||