src/globe/TiledElevationCoverage.js
function (config) {
            if (!config) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingConfig"));
            }

            if (!config.coverageSector) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingSector"));
            }

            if (!config.resolution) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingResolution"));
            }

            if (!config.retrievalImageFormat) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingImageFormat"));
            }

            ElevationCoverage.call(this, config.resolution);

            var firstLevelDelta = 45,
                tileWidth = 256,
                lastLevel = LevelSet.numLevelsForResolution(firstLevelDelta / tileWidth, config.resolution),
                numLevels = Math.ceil(lastLevel); // match or exceed the specified resolution

            /**
             * The sector this coverage spans.
             * @type {Sector}
             * @readonly
             */
            this.coverageSector = config.coverageSector;

            /**
             * The mime type to use when retrieving elevations.
             * @type {String}
             * @readonly
             */
            this.retrievalImageFormat = config.retrievalImageFormat;

            /**
             * This coverage's minimum elevation in meters.
             * @type {Number}
             * @default 0
             */
            this.minElevation = config.minElevation || 0;

            /**
             * This coverage's maximum elevation in meters.
             * @type {Number}
             */
            this.maxElevation = config.maxElevation || 0;

            /**
             * Indicates whether the data associated with this coverage is point data. A value of false
             * indicates that the data is area data (pixel is area).
             * @type {Boolean}
             * @default true
             */
            this.pixelIsPoint = false;

            /**
             * The {@link LevelSet} dividing this coverage's geographic domain into a multi-resolution, hierarchical
             * collection of tiles.
             * @type {LevelSet}
             * @readonly
             */
            this.levels = new LevelSet(this.coverageSector, new Location(firstLevelDelta, firstLevelDelta),
                numLevels, tileWidth, tileWidth);

            /**
             * Internal use only
             * The list of assembled tiles.
             * @type {Array}
             * @ignore
             */
            this.currentTiles = [];

            /**
             * Internal use only
             * A scratch sector for use in computations.
             * @type {Sector}
             * @ignore
             */
            this.currentSector = new Sector(0, 0, 0, 0);

            /**
             * Internal use only
             * A cache of elevation tiles.
             * @type {MemoryCache}
             * @ignore
             */
            this.tileCache = new MemoryCache(1000000, 800000);

            /**
             * Internal use only
             * A cache of elevations.
             * @type {MemoryCache}
             * @ignore
             */
            this.imageCache = new MemoryCache(10000000, 8000000);

            /**
             * Controls how many concurrent tile requests are allowed for this coverage.
             * @type {Number}
             * @default WorldWind.configuration.coverageRetrievalQueueSize
             */
            this.retrievalQueueSize = WorldWind.configuration.coverageRetrievalQueueSize;

            /**
             * Internal use only
             * The list of elevation retrievals in progress.
             * @type {Array}
             * @ignore
             */
            this.currentRetrievals = [];

            /**
             * Internal use only
             * The list of resources pending acquisition.
             * @type {Array}
             * @ignore
             */
            this.absentResourceList = new AbsentResourceList(3, 5e3);

            /**
             * Internal use only
             * The factory to create URLs for data requests. This property is typically set in the constructor of child
             * classes. See {@link WcsUrlBuilder} for a concrete example.
             * @type {UrlBuilder}
             * @ignore
             */
            this.urlBuilder = config.urlBuilder || null;
        }
function (config) {
            if (!config) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingConfig"));
            }

            if (!config.coverageSector) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingSector"));
            }

            if (!config.resolution) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingResolution"));
            }

            if (!config.retrievalImageFormat) {
                throw new ArgumentError(
                    Logger.logMessage(Logger.LEVEL_SEVERE, "TiledElevationCoverage", "constructor", "missingImageFormat"));
            }

            ElevationCoverage.call(this, config.resolution);

            var firstLevelDelta = 45,
                tileWidth = 256,
                lastLevel = LevelSet.numLevelsForResolution(firstLevelDelta / tileWidth, config.resolution),
                numLevels = Math.ceil(lastLevel); // match or exceed the specified resolution

            /**
             * The sector this coverage spans.
             * @type {Sector}
             * @readonly
             */
            this.coverageSector = config.coverageSector;

            /**
             * The mime type to use when retrieving elevations.
             * @type {String}
             * @readonly
             */
            this.retrievalImageFormat = config.retrievalImageFormat;

            /**
             * This coverage's minimum elevation in meters.
             * @type {Number}
             * @default 0
             */
            this.minElevation = config.minElevation || 0;

            /**
             * This coverage's maximum elevation in meters.
             * @type {Number}
             */
            this.maxElevation = config.maxElevation || 0;

            /**
             * Indicates whether the data associated with this coverage is point data. A value of false
             * indicates that the data is area data (pixel is area).
             * @type {Boolean}
             * @default true
             */
            this.pixelIsPoint = false;

            /**
             * The {@link LevelSet} dividing this coverage's geographic domain into a multi-resolution, hierarchical
             * collection of tiles.
             * @type {LevelSet}
             * @readonly
             */
            this.levels = new LevelSet(this.coverageSector, new Location(firstLevelDelta, firstLevelDelta),
                numLevels, tileWidth, tileWidth);

            /**
             * Internal use only
             * The list of assembled tiles.
             * @type {Array}
             * @ignore
             */
            this.currentTiles = [];

            /**
             * Internal use only
             * A scratch sector for use in computations.
             * @type {Sector}
             * @ignore
             */
            this.currentSector = new Sector(0, 0, 0, 0);

            /**
             * Internal use only
             * A cache of elevation tiles.
             * @type {MemoryCache}
             * @ignore
             */
            this.tileCache = new MemoryCache(1000000, 800000);

            /**
             * Internal use only
             * A cache of elevations.
             * @type {MemoryCache}
             * @ignore
             */
            this.imageCache = new MemoryCache(10000000, 8000000);

            /**
             * Controls how many concurrent tile requests are allowed for this coverage.
             * @type {Number}
             * @default WorldWind.configuration.coverageRetrievalQueueSize
             */
            this.retrievalQueueSize = WorldWind.configuration.coverageRetrievalQueueSize;

            /**
             * Internal use only
             * The list of elevation retrievals in progress.
             * @type {Array}
             * @ignore
             */
            this.currentRetrievals = [];

            /**
             * Internal use only
             * The list of resources pending acquisition.
             * @type {Array}
             * @ignore
             */
            this.absentResourceList = new AbsentResourceList(3, 5e3);

            /**
             * Internal use only
             * The factory to create URLs for data requests. This property is typically set in the constructor of child
             * classes. See {@link WcsUrlBuilder} for a concrete example.
             * @type {UrlBuilder}
             * @ignore
             */
            this.urlBuilder = config.urlBuilder || null;
        }
function ( config ) { if ( ! config ) { throw new ArgumentError ( Logger . logMessage ( Logger . LEVEL_SEVERE , "TiledElevationCoverage" , "constructor" , "missingConfig" ) ) ; } if ( ! config . coverageSector ) { throw new ArgumentError ( Logger . logMessage ( Logger . LEVEL_SEVERE , "TiledElevationCoverage" , "constructor" , "missingSector" ) ) ; } if ( ! config . resolution ) { throw new ArgumentError ( Logger . logMessage ( Logger . LEVEL_SEVERE , "TiledElevationCoverage" , "constructor" , "missingResolution" ) ) ; } if ( ! config . retrievalImageFormat ) { throw new ArgumentError ( Logger . logMessage ( Logger . LEVEL_SEVERE , "TiledElevationCoverage" , "constructor" , "missingImageFormat" ) ) ; } ElevationCoverage . call ( this , config . resolution ) ; var firstLevelDelta = 45 , tileWidth = 256 , lastLevel = LevelSet . numLevelsForResolution ( firstLevelDelta / tileWidth , config . resolution ) , numLevels = Math . ceil ( lastLevel ) ; // match or exceed the specified resolution /**
             * The sector this coverage spans.
             * @type {Sector}
             * @readonly
             */ this . coverageSector = config . coverageSector ; /**
             * The mime type to use when retrieving elevations.
             * @type {String}
             * @readonly
             */ this . retrievalImageFormat = config . retrievalImageFormat ; /**
             * This coverage's minimum elevation in meters.
             * @type {Number}
             * @default 0
             */ this . minElevation = config . minElevation || 0 ; /**
             * This coverage's maximum elevation in meters.
             * @type {Number}
             */ this . maxElevation = config . maxElevation || 0 ; /**
             * Indicates whether the data associated with this coverage is point data. A value of false
             * indicates that the data is area data (pixel is area).
             * @type {Boolean}
             * @default true
             */ this . pixelIsPoint = false ; /**
             * The {@link LevelSet} dividing this coverage's geographic domain into a multi-resolution, hierarchical
             * collection of tiles.
             * @type {LevelSet}
             * @readonly
             */ this . levels = new LevelSet ( this . coverageSector , new Location ( firstLevelDelta , firstLevelDelta ) , numLevels , tileWidth , tileWidth ) ; /**
             * Internal use only
             * The list of assembled tiles.
             * @type {Array}
             * @ignore
             */ this . currentTiles = [ ] ; /**
             * Internal use only
             * A scratch sector for use in computations.
             * @type {Sector}
             * @ignore
             */ this . currentSector = new Sector ( 0 , 0 , 0 , 0 ) ; /**
             * Internal use only
             * A cache of elevation tiles.
             * @type {MemoryCache}
             * @ignore
             */ this . tileCache = new MemoryCache ( 1000000 , 800000 ) ; /**
             * Internal use only
             * A cache of elevations.
             * @type {MemoryCache}
             * @ignore
             */ this . imageCache = new MemoryCache ( 10000000 , 8000000 ) ; /**
             * Controls how many concurrent tile requests are allowed for this coverage.
             * @type {Number}
             * @default WorldWind.configuration.coverageRetrievalQueueSize
             */ this . retrievalQueueSize = WorldWind . configuration . coverageRetrievalQueueSize ; /**
             * Internal use only
             * The list of elevation retrievals in progress.
             * @type {Array}
             * @ignore
             */ this . currentRetrievals = [ ] ; /**
             * Internal use only
             * The list of resources pending acquisition.
             * @type {Array}
             * @ignore
             */ this . absentResourceList = new AbsentResourceList ( 3 , 5e3 ) ; /**
             * Internal use only
             * The factory to create URLs for data requests. This property is typically set in the constructor of child
             * classes. See {@link WcsUrlBuilder} for a concrete example.
             * @type {UrlBuilder}
             * @ignore
             */ this . urlBuilder = config . urlBuilder || null ; }
Constructs a TiledElevationCoverage
@alias TiledElevationCoverage
@constructor
@classdesc Represents the elevations for an area, often but not necessarily the whole globe.
@param {{}} config Configuration properties for the coverage:
<ul>
<li>coverageSector: {Sector} The sector this coverage spans.</li>
<li>resolution: {Number} The resolution of the coverage, in degrees. (To compute degrees from meters, divide the number of meters by the globe's radius to obtain radians and convert the result to degrees.)</li>
<li>retrievalImageFormat: {String} The mime type of the elevation data retrieved by this coverage.</li>
<li>minElevation (optional): {Number} The coverage's minimum elevation in meters.</li>
<li>maxElevation (optional): {Number} Te coverage's maximum elevation in meters.</li>
<li>urlBuilder (optional): {UrlBuilder} The factory to create URLs for elevation data requests.</li>
<ul>
@throws {ArgumentError} If any required configuration parameter is null or undefined.
Constructs a TiledElevationCoverage