   getRangeForPath: (path) ->
     result = @mappings[path]
     unless result? then throw new Error "Found no range for path '" + path + "'!"
-    if @restricted
-      result = $.extend {}, result;
-      result.pathInfo = $.extend {}, result.pathInfo
-      delete result.pathInfo.node
     result
 
   # Return the character range mappings for a given node in the DOM


  constructor: ->
    @setRealRoot()
    @restrictToSerializable false
    window.DomTextMapper.instances.push this

  # ===== Public methods =======

  # Switch the library into "serializable-only" mode.
  # If set to true, all public API calls will be restricted to return
  # strictly serializable data structures.
  # (References to DOM objects will be omitted.)
  restrictToSerializable: (value = true) -> @restricted = value

  # Consider only the sub-tree beginning with the given node.
  # 

  #   content: the text content of the node, as rendered by the browser
  #   length: the length of the next content
  scan: ->
    if @domStableSince @lastScanned
      # We have a valid paths structure!
#      console.log "We have a valid DOM structure cache."
      return @allpaths

#    console.log "No valid cache, will have to calculate getAllPaths."
    startTime = @timestamp()
