code: function (wwd) {
  
              if (!wwd) {
                  throw new ArgumentError(
                      Logger.logMessage(Logger.LEVEL_SEVERE, "LengthMeasurer", "constructor", "missingWorldWindow"));
              }
  
              this.wwd = wwd;
  
              // Private. The minimum length of a terrain following subdivision.
              this.DEFAULT_MIN_SEGMENT_LENGTH = 30;
  
              // Private. Documentation is with the defined property below.
              this._maxSegmentLength = 100e3;
  
              // Private. Documentation is with the defined property below.
              this._lengthTerrainSamplingSteps = 128;
  
              // Private. A list of positions with no segment longer then maxLength and elevations following terrain or not.
              this.subdividedPositions = null;
          }
docs: Utility class to measure length along a path on a globe. <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/> <p>For follow terrain, the computed length will
  account for terrain deformations as if someone was walking along that path. Otherwise the length is the sum
  of the cartesian distance between the positions.</p>
  <p/>
  <p>When following terrain the measurer will sample terrain elevations at regular intervals along the path.
  The minimum number of samples used for the whole length can be set with lengthTerrainSamplingSteps.
  However, the minimum sampling interval is 30 meters.
  @alias LengthMeasurer
  @constructor
  @param {WorldWindow} wwd The WorldWindow associated with LengthMeasurer.
  @throws {ArgumentError} If the specified WorldWindow is null or undefined.