code: function (wwd) {
  
              if (!wwd) {
                  throw new ArgumentError(
                      Logger.logMessage(Logger.LEVEL_SEVERE, "AreaMeasurer", "constructor", "missingWorldWindow"));
              }
  
              this.wwd = wwd;
  
              // Private. Sampling grid max rows or cols
              this.DEFAULT_AREA_SAMPLING_STEPS = 32;
  
              // Private. Documentation is with the defined property below.
              this._areaTerrainSamplingSteps = this.DEFAULT_AREA_SAMPLING_STEPS;
  
              // Private. Documentation is with the defined property below.
              this._maxSegmentLength = 100e3;
  
              // Private. A list of positions with no segment longer then maxLength and elevations following terrain or not.
              this.subdividedPositions = null;
  
              // Private.
              this.vecZ = new Vec3(0, 0, 1);
  
              // Private. Reusable Location.
              this.scratchLocation = new Location(0, 0);
  
          }
docs: Utility class to compute approximations of projected and surface (terrain following) area on a globe.
  
  <p>To properly compute surface area the measurer must be provided with a list of positions that describe a
  closed path - one which last position is equal to the first.</p>
  
  <p>Segments which are longer then the current maxSegmentLength will be subdivided along lines following the
  current pathType - WorldWind.LINEAR, WorldWind.RHUMB_LINE or WorldWind.GREAT_CIRCLE.</p>
  
  <p>Projected or non terrain following area is computed in a sinusoidal projection which is equivalent or
  equal area.
  Surface or terrain following area is approximated by sampling the path bounding sector with square cells
  along a grid. Cells which center is inside the path  have their area estimated and summed according to the
  overall slope at the cell south-west corner.</p>
  
  @alias AreaMeasurer
  @constructor
  @param {WorldWindow} wwd The WorldWindow associated with AreaMeasurer.
  @throws {ArgumentError} If the specified WorldWindow is null or undefined.