 
     ))
 
+(defn create-contract [symbol]
+  (doto (com.ib.controller.NewContract.)
+    (.symbol symbol)
+    (.secType com.ib.controller.Types$SecType/STK)
+    (.expiry "")
+    (.strike 0.0)
+    (.right com.ib.controller.Types$Right/None)
+    (.multiplier "")
+    (.exchange "SMART")
+    (.currency "USD")
+    (.localSymbol "")
+    (.tradingClass "")))
+
 (defn api-ctrl []
   (com.ib.controller.ApiController. (create-controller)
                                     (reify com.ib.controller.ApiConnection$ILogger

                                    (reify com.ib.controller.ApiConnection$ILogger
                                      (log [this s] (print s)))))


(defn start []
  (let [api (api-ctrl)]
    (.connect api "localhost" 7497 5)
    (Thread/sleep 1000)
    (.disconnect api)))


(defn -main
  "the main function"
  []
 (start)


      )

(ns ibclj.core
  [:import  com.ib.controller.ApiController])


(defn create-controller []
  (reify
