]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/SearchContext.php
Merge pull request #1099 from lonvia/sanity-check-pyosmium
[nominatim.git] / lib / SearchContext.php
index 3e722d87af9b318c055fcae60058298061a0b20f..c0ae903295073b237bb44e19bc30b440ba48f46c 100644 (file)
@@ -47,7 +47,7 @@ class SearchContext
     /**
      * Get radius around reference point.
      *
-     * @return float Search radius around refernce point.
+     * @return float Search radius around reference point.
      */
     public function nearRadius()
     {
@@ -267,4 +267,18 @@ class SearchContext
 
         return '';
     }
+
+    public function debugInfo()
+    {
+        return array(
+                'Near radius' => $this->fNearRadius,
+                'Near point (SQL)' => $this->sqlNear,
+                'Bounded viewbox' => $this->bViewboxBounded,
+                'Viewbox (SQL, small)' => $this->sqlViewboxSmall,
+                'Viewbox (SQL, large)' => $this->sqlViewboxLarge,
+                'Viewbox (SQL, centre)' => $this->sqlViewboxCentre,
+                'Countries (SQL)' => $this->sqlCountryList,
+                'Excluded IDs (SQL)' => $this->sqlExcludeList
+               );
+    }
 }