NASA World Wind

gov.nasa.worldwind
Class Level

java.lang.Object
  extended by gov.nasa.worldwind.Level
All Implemented Interfaces:
Comparable<Level>

public class Level
extends Object
implements Comparable<Level>


Nested Class Summary
static interface Level.TileURLBuilder
           
 
Field Summary
static String CACHE_NAME
           
static String DATASET_NAME
           
static String EXPIRY_TIME
           
static String FORMAT_SUFFIX
           
static String LEVEL_NAME
           
static String LEVEL_NUMBER
           
static String LEVEL_ZERO_TILE_DELTA
           
static String MAX_ABSENT_TILE_ATTEMPTS
           
static String MIN_ABSENT_TILE_CHECK_INTERVAL
           
static String NUM_EMPTY_LEVELS
           
static String NUM_LEVELS
           
static String SERVICE
           
static String TILE_DELTA
           
static String TILE_HEIGHT
           
static String TILE_URL_BUILDER
           
static String TILE_WIDTH
           
 
Constructor Summary
Level(AVList params)
           
 
Method Summary
 int compareTo(Level that)
           
 boolean equals(Object o)
           
 String getCacheName()
           
 String getDataset()
           
 long getExpiryTime()
           
 String getFormatSuffix()
           
 String getLevelName()
           
 int getLevelNumber()
           
 AVList getParams()
           
 String getPath()
           
 String getService()
           
 double getTexelSize(double radius)
           
 LatLon getTileDelta()
           
 int getTileHeight()
           
 URL getTileResourceURL(Tile tile)
          Returns the URL necessary to retrieve the specified tile.
 int getTileWidth()
           
 int hashCode()
           
 boolean isEmpty()
           
 boolean isResourceAbsent(long tileNumber)
           
 void markResourceAbsent(long tileNumber)
           
 void setExpiryTime(long expiryTime)
           
 String toString()
           
 void unmarkResourceAbsent(long tileNumber)
           
protected  String validate(AVList params)
          Determines whether the constructor arguments are valid.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

CACHE_NAME

public static final String CACHE_NAME
See Also:
Constant Field Values

DATASET_NAME

public static final String DATASET_NAME
See Also:
Constant Field Values

EXPIRY_TIME

public static final String EXPIRY_TIME
See Also:
Constant Field Values

FORMAT_SUFFIX

public static final String FORMAT_SUFFIX
See Also:
Constant Field Values

LEVEL_NAME

public static final String LEVEL_NAME
See Also:
Constant Field Values

LEVEL_NUMBER

public static final String LEVEL_NUMBER
See Also:
Constant Field Values

LEVEL_ZERO_TILE_DELTA

public static final String LEVEL_ZERO_TILE_DELTA
See Also:
Constant Field Values

MAX_ABSENT_TILE_ATTEMPTS

public static final String MAX_ABSENT_TILE_ATTEMPTS
See Also:
Constant Field Values

MIN_ABSENT_TILE_CHECK_INTERVAL

public static final String MIN_ABSENT_TILE_CHECK_INTERVAL
See Also:
Constant Field Values

NUM_EMPTY_LEVELS

public static final String NUM_EMPTY_LEVELS
See Also:
Constant Field Values

NUM_LEVELS

public static final String NUM_LEVELS
See Also:
Constant Field Values

SERVICE

public static final String SERVICE
See Also:
Constant Field Values

TILE_DELTA

public static final String TILE_DELTA
See Also:
Constant Field Values

TILE_HEIGHT

public static final String TILE_HEIGHT
See Also:
Constant Field Values

TILE_URL_BUILDER

public static final String TILE_URL_BUILDER
See Also:
Constant Field Values

TILE_WIDTH

public static final String TILE_WIDTH
See Also:
Constant Field Values
Constructor Detail

Level

public Level(AVList params)
Method Detail

compareTo

public int compareTo(Level that)
Specified by:
compareTo in interface Comparable<Level>

equals

public boolean equals(Object o)
Overrides:
equals in class Object

getCacheName

public final String getCacheName()

getDataset

public final String getDataset()

getExpiryTime

public final long getExpiryTime()

getFormatSuffix

public final String getFormatSuffix()

getLevelName

public String getLevelName()

getLevelNumber

public final int getLevelNumber()

getParams

public final AVList getParams()

getPath

public String getPath()

getService

public final String getService()

getTexelSize

public final double getTexelSize(double radius)

getTileDelta

public LatLon getTileDelta()

getTileHeight

public final int getTileHeight()

getTileResourceURL

public URL getTileResourceURL(Tile tile)
                       throws MalformedURLException
Returns the URL necessary to retrieve the specified tile.

Parameters:
tile - the tile who's resources will be retrieved.
Returns:
the resource URL.
Throws:
MalformedURLException - if the URL cannot be formed from the tile's parameters.
IllegalArgumentException - if tile is null.

getTileWidth

public final int getTileWidth()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

isEmpty

public final boolean isEmpty()

isResourceAbsent

public final boolean isResourceAbsent(long tileNumber)

markResourceAbsent

public final void markResourceAbsent(long tileNumber)

setExpiryTime

public void setExpiryTime(long expiryTime)

toString

public String toString()
Overrides:
toString in class Object

unmarkResourceAbsent

public final void unmarkResourceAbsent(long tileNumber)

validate

protected String validate(AVList params)
Determines whether the constructor arguments are valid.

Parameters:
params - the list of parameters to validate.
Returns:
null if valid, otherwise a String containing a description of why it's invalid.

NASA World Wind