   (:require
     [freactive.core :as r]))
 
-
 (def ^:dynamic *tx-coll*)
 
 (defprotocol IObservableCollection
-  (-transact!* [coll f])
-  (-add-change-watch [coll key f])
-  (-remove-change-watch [coll key])
-  (-update! [coll key f])
-  (-insert! [coll val]
-   "Inserts a value into the collection with an auto-generated key if supported and returns the
-  generated key. Throws an exception if not supported.")
-  (-get-cursor [coll key]))
+  (-add-collection-watch [coll key f])
+  (-remove-collection-watch [coll key]))
 
 (def ^:dynamic ^:private *tx-state*)
 (def ^:dynamic ^:private *tx-changes*)

(defn observable-map
  ([])
  ([init]
   (ObservableCollection. init nil nil nil)))

(defn observable-seq
  ([])

(defn- add-change [change]
  (set! *tx-changes* (conj *tx-changes* change)))

(deftype ObservableMap [state-ref observers]
  IDeref
  (-deref [_] @state-ref)

  IPrintWithWriter
  (-pr-writer [a writer opts]
    (-write writer "#<ObservableMap: ")
    (pr-writer @state-ref writer opts)
    (-write writer ">"))

