4 " Replacing these characters http encoded ones
14 (clojure.contrib.string/replace-str " " "%20"
15 (clojure.contrib.string/replace-str "'" "%27"
16 (clojure.contrib.string/replace-str ";" "%3B"
17 (clojure.contrib.string/replace-str "[" "%5B"
18 (clojure.contrib.string/replace-str "@" "%40"
19 (clojure.contrib.string/replace-str "=" "%3D"
20 (clojure.contrib.string/replace-str "]" "%5D" text
25 ;; set get base URL ...TODO - put in config
26 (def db-base-URL "http://localhost:8080/exist/rest/")
28 ;; set root/system dir fragment ...TODO - put in config
29 (def db-system-DIR "rootDir/system.main.system/")
31 ;; working directory lookup ...TODO - put these lookups into config
32 (defn working-dir-lookup [token]
34 (println "DEBUG > 'working-dir-lookup' CALLED > ["(keyword token)"]" )
36 ( { :group "aauthentication.main.authentication/groups.aauth.groups"
37 :user "aauthentication.main.authentication/users.aauth.users"
38 :account "groups.main.groups"
39 :journal "groups.main.groups"
40 :entry "groups.main.groups"
41 :entries "groups.main.groups"
42 :debit "groups.main.groups"
43 :credit "groups.main.groups"
48 (defn namespace-lookup
51 (println "DEBUG > 'namespace-lookup' CALLED > ["token"]" )
53 ( { "group" "com/interrupt/bookkeeping/users"
54 "user" "com/interrupt/bookkeeping/users"
55 "account" "com/interrupt/bookkeeping/account"
56 "journal" "com/interrupt/bookkeeping/journal"
57 "entry" "com/interrupt/bookkeeping/journal"
58 "debit" "com/interrupt/bookkeeping/account"
59 "credit" "com/interrupt/bookkeeping/account"