             [cmr.spatial.polygon :as poly]
             [cmr.spatial.point :as p]
             [cmr.spatial.mbr :as m]
-            [cmr.spatial.ring :as r]
+            [cmr.spatial.ring-relations :as rr]
             [cmr.spatial.derived :as derived]
             [cmr.spatial.codec]
             [clojure.string :as str]


(defmethod ords->shape :polygon
  [spatial-type ords]
  (derived/calculate-derived (apply polygon ords)))

(defmethod ords->shape :bounding_box
  [spatial-type ords]

(comment

  ;; A polygon with a hole
  (let [outer (rr/ords->ring :geodetic -5.26,-2.59, 11.56,-2.77, 10.47,8.71, -5.86,8.63, -5.26,-2.59)
        hole1 (rr/ords->ring :geodetic 6.95,2.05, 2.98,2.06, 3.92,-0.08, 6.95,2.05)
        hole2 (rr/ords->ring :geodetic 5.18,6.92, -1.79,7.01, -2.65,5, 4.29,5.05, 5.18,6.92)
        polygon-with-holes  (poly/polygon :geodetic [outer hole1 hole2])
        search-area (polygon 0 0, 1 0, 1 1, 0 0)]
    (visual-interactive-search [polygon-with-holes] search-area))

