 
 (defn- format-utc
   "Produces an ISO-8601 formatted date-time string from the given Date."
-  [^java.util.Date date]
+  [^Date date]
   (let [date-format (doto (java.text.SimpleDateFormat.
                             "yyyy-MM-dd'T'HH:mm:ss.SSS-00:00")
-                       (.setTimeZone (java.util.TimeZone/getTimeZone "GMT")))]
+                       (.setTimeZone (TimeZone/getTimeZone "GMT")))]
     (.format date-format date)))
 
 
-(extend-type java.util.Date
+(extend-type Date
   TaggedValue
   (edn-tag [this] 'inst)
   (edn-value [this] (format-utc this)))

(ns vault.data
  "Code to handle structured data, usually represented as EDN."
  (:require [clojure.string :as string]
            [clojure.data.codec.base64 :as b64]))


;; TOTAL-ORDERING COMPARATOR


; #uri - Universal Resource Identifier string.

(extend-type URI
  TaggedValue
  (edn-tag [this] 'uri)
  (edn-value [this] (str this)))


(defprint-method URI)


(defn read-uri
  "Constructs a URI from a string value."
  ^URI
  [^String uri]
  (URI. uri))
