gov.nasa.worldwind.layers
Class BasicTiledImageLayer
java.lang.Object
gov.nasa.worldwind.avlist.AVListImpl
gov.nasa.worldwind.WWObjectImpl
gov.nasa.worldwind.layers.AbstractLayer
gov.nasa.worldwind.layers.TiledImageLayer
gov.nasa.worldwind.layers.BasicTiledImageLayer
- All Implemented Interfaces:
- AVList, Disposable, Layer, NamedObject, Restorable, BulkRetrievable, WWObject, java.beans.PropertyChangeListener, java.util.EventListener
- Direct Known Subclasses:
- Clementine30Layer, Clementine40Layer, MDIMLayer, MOCColorizedLayer, MOCLayer, MolaColorASULayer, MolaColoredJPLLayer, MSVirtualEarthLayer, ShadedElevationLayer, THEMISColorLayer, THEMISLayer, USGSDigitalOrtho, USGSTopographicMaps, USGSTopoHighRes, USGSTopoLowRes, USGSTopoMedRes, USGSUrbanAreaOrtho, WMSTiledImageLayer
public class BasicTiledImageLayer
- extends TiledImageLayer
- implements BulkRetrievable
|
Method Summary |
protected void |
checkResources()
|
protected org.w3c.dom.Document |
createConfigurationDocument(AVList params)
|
protected void |
doGetRestorableStateForAVPair(java.lang.String key,
java.lang.Object value,
RestorableSupport rs,
RestorableSupport.StateObject context)
|
protected void |
doRestoreState(RestorableSupport rs,
RestorableSupport.StateObject context)
|
protected void |
doRestoreStateForObject(RestorableSupport rs,
RestorableSupport.StateObject so)
|
protected void |
downloadTexture(TextureTile tile,
BasicTiledImageLayer.DownloadPostProcessor postProcessor)
|
protected void |
doWriteConfigurationParams(FileStore fileStore,
java.lang.String fileName,
AVList params)
|
protected void |
forceTextureLoad(TextureTile tile)
|
protected AVList |
getConfigurationParams(AVList params)
|
long |
getEstimatedMissingDataSize(Sector sector,
double resolution)
Get the estimated size in bytes of the imagery not in the World Wind file cache for the given sector and
resolution. |
long |
getEstimatedMissingDataSize(Sector sector,
double resolution,
FileStore fileStore)
Get the estimated size in bytes of the imagery not in a specified file store for a specified sector and
resolution. |
protected static AVList |
getParamsFromDocument(org.w3c.dom.Element domElement,
AVList params)
|
java.lang.String |
getRestorableState()
Returns an XML document string describing the object's state. |
protected void |
initializeResources(AVList params)
|
protected void |
initPropertiesFromCapabilities(Capabilities caps,
AVList params)
|
protected void |
initPropertiesFromService(AVList params)
|
protected boolean |
isTextureFileExpired(TextureTile tile,
java.net.URL textureURL,
FileStore fileStore)
|
BulkRetrievalThread |
makeLocal(Sector sector,
double resolution)
Start a new BulkRetrievalThread that downloads all imagery for a given sector and resolution to the
current World Wind file cache, without downloading imagery that is already in the cache. |
BulkRetrievalThread |
makeLocal(Sector sector,
double resolution,
FileStore fileStore)
Start a new BulkRetrievalThread that downloads all imagery for a given sector and resolution to a
specified FileStore, without downloading imagery tht is already in the file store. |
protected boolean |
needsConfigurationFile(FileStore fileStore,
java.lang.String fileName,
AVList params,
boolean removeIfExpired)
|
protected void |
requestTexture(DrawContext dc,
TextureTile tile)
|
protected static AVList |
restorableStateToParams(java.lang.String stateInXml)
|
void |
restoreState(java.lang.String stateInXml)
Restores the object's state to what is described in the specified XML document string. |
protected static void |
restoreStateForParams(RestorableSupport rs,
RestorableSupport.StateObject context,
AVList params)
|
protected static void |
setFallbacks(AVList params)
|
protected void |
writeConfigurationFile(FileStore fileStore)
|
protected void |
writeConfigurationParams(FileStore fileStore,
AVList params)
|
| Methods inherited from class gov.nasa.worldwind.layers.TiledImageLayer |
composeImageForSector, computeLevelForResolution, countImagesInSector, countImagesInSector, doRender, downloadImage, getAvailableImageFormats, getDefaultImageFormat, getLevels, getReferencePoint, getRequestQ, getTilesInSector, getTopLevels, isAtMaxResolution, isDrawBoundingVolumes, isDrawTileBoundaries, isDrawTileIDs, isForceLevelZeroLoads, isImageFormatAvailable, isLayerInView, isMultiResolution, isRetainLevelZeroTiles, isShowImageTileOutlines, isUseMipMaps, isUseTransparentTextures, render, requestImage, setAvailableImageFormats, setBlendingFunction, setDrawBoundingVolumes, setDrawTileBoundaries, setDrawTileIDs, setExpiryTime, setForceLevelZeroLoads, setName, setRetainLevelZeroTiles, setShowImageTileOutlines, setSplitScale, setUseMipMaps, setUseTransparentTextures |
| Methods inherited from class gov.nasa.worldwind.layers.AbstractLayer |
dispose, doPick, doPreRender, getDataFileStore, getExpiryTime, getMaxActiveAltitude, getMinActiveAltitude, getName, getOpacity, getScale, getScreenCredit, isEnabled, isLayerActive, isNetworkRetrievalEnabled, isPickEnabled, pick, preRender, setDataFileStore, setEnabled, setMaxActiveAltitude, setMinActiveAltitude, setNetworkRetrievalEnabled, setOpacity, setPickEnabled, setScreenCredit, toString |
| Methods inherited from class gov.nasa.worldwind.avlist.AVListImpl |
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getDoubleValue, getDoubleValue, getEntries, getIntegerValue, getIntegerValue, getLongValue, getLongValue, getStringValue, getStringValue, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, 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 java.beans.PropertyChangeListener |
propertyChange |
SERVICE_CAPABILITIES_RESOURCE_ID
protected static final int SERVICE_CAPABILITIES_RESOURCE_ID
- See Also:
- Constant Field Values
BasicTiledImageLayer
public BasicTiledImageLayer(AVList params)
BasicTiledImageLayer
public BasicTiledImageLayer(org.w3c.dom.Document dom,
AVList params)
BasicTiledImageLayer
public BasicTiledImageLayer(org.w3c.dom.Element domElement,
AVList params)
BasicTiledImageLayer
public BasicTiledImageLayer(LevelSet levelSet)
BasicTiledImageLayer
public BasicTiledImageLayer(java.lang.String restorableStateInXml)
checkResources
protected void checkResources()
- Specified by:
checkResources in class TiledImageLayer
createConfigurationDocument
protected org.w3c.dom.Document createConfigurationDocument(AVList params)
doGetRestorableStateForAVPair
protected void doGetRestorableStateForAVPair(java.lang.String key,
java.lang.Object value,
RestorableSupport rs,
RestorableSupport.StateObject context)
doRestoreState
protected void doRestoreState(RestorableSupport rs,
RestorableSupport.StateObject context)
doRestoreStateForObject
protected void doRestoreStateForObject(RestorableSupport rs,
RestorableSupport.StateObject so)
downloadTexture
protected void downloadTexture(TextureTile tile,
BasicTiledImageLayer.DownloadPostProcessor postProcessor)
doWriteConfigurationParams
protected void doWriteConfigurationParams(FileStore fileStore,
java.lang.String fileName,
AVList params)
forceTextureLoad
protected void forceTextureLoad(TextureTile tile)
- Specified by:
forceTextureLoad in class TiledImageLayer
getConfigurationParams
protected AVList getConfigurationParams(AVList params)
getEstimatedMissingDataSize
public long getEstimatedMissingDataSize(Sector sector,
double resolution)
- Get the estimated size in bytes of the imagery not in the World Wind file cache for the given sector and
resolution.
Note that the target resolution must be provided in radians of latitude per texel, which is the resolution in
meters divided by the globe radius.
- Specified by:
getEstimatedMissingDataSize in interface BulkRetrievable
- Parameters:
sector - the sector to estimate.resolution - the target resolution, provided in radians of latitude per texel.
- Returns:
- the estimated size in bytes of the missing imagery.
- Throws:
java.lang.IllegalArgumentException - if the sector is null or the resolution is less than zero.
getEstimatedMissingDataSize
public long getEstimatedMissingDataSize(Sector sector,
double resolution,
FileStore fileStore)
- Get the estimated size in bytes of the imagery not in a specified file store for a specified sector and
resolution.
Note that the target resolution must be provided in radians of latitude per texel, which is the resolution in
meters divided by the globe radius.
- Specified by:
getEstimatedMissingDataSize in interface BulkRetrievable
- Parameters:
sector - the sector to estimate.resolution - the target resolution, provided in radians of latitude per texel.fileStore - the file store to examine. If null the current World Wind file cache is used.
- Returns:
- the estimated size in byte of the missing imagery.
- Throws:
java.lang.IllegalArgumentException - if the sector is null or the resolution is less than zero.
getParamsFromDocument
protected static AVList getParamsFromDocument(org.w3c.dom.Element domElement,
AVList params)
getRestorableState
public java.lang.String getRestorableState()
- Description copied from interface:
Restorable
- Returns an XML document string describing the object's state. This state can be restored later by calling
restoreState and passing the XML document.
- Specified by:
getRestorableState in interface Restorable- Overrides:
getRestorableState in class AbstractLayer
- Returns:
- an XML document string describing the object's state.
initializeResources
protected void initializeResources(AVList params)
initPropertiesFromCapabilities
protected void initPropertiesFromCapabilities(Capabilities caps,
AVList params)
initPropertiesFromService
protected void initPropertiesFromService(AVList params)
isTextureFileExpired
protected boolean isTextureFileExpired(TextureTile tile,
java.net.URL textureURL,
FileStore fileStore)
makeLocal
public BulkRetrievalThread makeLocal(Sector sector,
double resolution)
- Start a new
BulkRetrievalThread that downloads all imagery for a given sector and resolution to the
current World Wind file cache, without downloading imagery that is already in the cache.
This method creates and starts a thread to perform the download. A reference to the thread is returned. To create
a downloader that has not been started, construct a BasicTiledImageLayerBulkDownloader.
Note that the target resolution must be provided in radians of latitude per texel, which is the resolution in
meters divided by the globe radius.
- Specified by:
makeLocal in interface BulkRetrievable
- Parameters:
sector - the sector to download imagery for.resolution - the target resolution, provided in radians of latitude per texel.
- Returns:
- the
BulkRetrievalThread executing the retrieval.
- Throws:
java.lang.IllegalArgumentException - if the sector is null or the resolution is less than zero.- See Also:
BasicTiledImageLayerBulkDownloader
makeLocal
public BulkRetrievalThread makeLocal(Sector sector,
double resolution,
FileStore fileStore)
- Start a new
BulkRetrievalThread that downloads all imagery for a given sector and resolution to a
specified FileStore, without downloading imagery tht is already in the file store.
This method creates and starts a thread to perform the download. A reference to the thread is returned. To create
a downloader that has not been started, construct a BasicTiledImageLayerBulkDownloader.
Note that the target resolution must be provided in radians of latitude per texel, which is the resolution in
meters divided by the globe radius.
- Specified by:
makeLocal in interface BulkRetrievable
- Parameters:
sector - the sector to download data for.resolution - the target resolution, provided in radians of latitude per texel.fileStore - the file store in which to place the downloaded imagery. If null the current World Wind file
cache is used.
- Returns:
- the
BulkRetrievalThread executing the retrieval.
- Throws:
java.lang.IllegalArgumentException - if the sector is null or the resolution is less than zero.- See Also:
BasicTiledImageLayerBulkDownloader
needsConfigurationFile
protected boolean needsConfigurationFile(FileStore fileStore,
java.lang.String fileName,
AVList params,
boolean removeIfExpired)
requestTexture
protected void requestTexture(DrawContext dc,
TextureTile tile)
- Specified by:
requestTexture in class TiledImageLayer
restorableStateToParams
protected static AVList restorableStateToParams(java.lang.String stateInXml)
restoreState
public void restoreState(java.lang.String stateInXml)
- Description copied from interface:
Restorable
- Restores the object's state to what is described in the specified XML document string.
- Specified by:
restoreState in interface Restorable- Overrides:
restoreState in class AbstractLayer
- Parameters:
stateInXml - an XML document string describing an object's state.
restoreStateForParams
protected static void restoreStateForParams(RestorableSupport rs,
RestorableSupport.StateObject context,
AVList params)
setFallbacks
protected static void setFallbacks(AVList params)
writeConfigurationFile
protected void writeConfigurationFile(FileStore fileStore)
writeConfigurationParams
protected void writeConfigurationParams(FileStore fileStore,
AVList params)