[isidorus-cvs] r926 - branches/gdl-frontend/src/rest_interface
lgiessmann at common-lisp.net
lgiessmann at common-lisp.net
Mon Sep 19 14:48:01 UTC 2011
Author: lgiessmann
Date: Mon Sep 19 07:48:01 2011
New Revision: 926
Log:
Modified:
branches/gdl-frontend/src/rest_interface/rest-interface.lisp
branches/gdl-frontend/src/rest_interface/set-up-gdl-interface.lisp
Modified: branches/gdl-frontend/src/rest_interface/rest-interface.lisp
==============================================================================
--- branches/gdl-frontend/src/rest_interface/rest-interface.lisp Mon Sep 19 07:46:18 2011 (r925)
+++ branches/gdl-frontend/src/rest_interface/rest-interface.lisp Mon Sep 19 07:48:01 2011 (r926)
@@ -56,9 +56,11 @@
:*gdl-get-schema*
:*gdl-commit-fragment*
:*gdl-delete-fragment*
- :*gdl-host-address*
+ :*gdl-host-address-hash-object*
+ :*gdl-host-address-environment*
:*gdl-base-path*
- :*gdl-host-file*
+ :*gdl-host-file-hash-object*
+ :*gdl-host-file-environment*
:*gdl-tm-id*
:*gdl-sparql*))
Modified: branches/gdl-frontend/src/rest_interface/set-up-gdl-interface.lisp
==============================================================================
--- branches/gdl-frontend/src/rest_interface/set-up-gdl-interface.lisp Mon Sep 19 07:46:18 2011 (r925)
+++ branches/gdl-frontend/src/rest_interface/set-up-gdl-interface.lisp Mon Sep 19 07:48:01 2011 (r926)
@@ -13,11 +13,13 @@
(defparameter *gdl-get-schema* "/gdl/schema/?$")
(defparameter *gdl-commit-fragment* "/gdl/commit/?")
(defparameter *gdl-delete-fragment* "/gdl/delete/?")
-(defparameter *gdl-host-address* "/anatomia")
+(defparameter *gdl-host-address-hash-object* "/hash-object")
+(defparameter *gdl-host-address-environment* "/environment")
(defparameter *gdl-base-path* "anaToMia/hosted_files/")
-(defparameter *gdl-host-file* (concat *gdl-base-path* "GDL_Widgets.html"))
+(defparameter *gdl-host-file-hash-object* (concat *gdl-base-path* "hash-object-ui/GDL_Widgets.html"))
+(defparameter *gdl-host-file-environment* (concat *gdl-base-path* "environment-ui/GDL_Widgets.html"))
(defparameter *gdl-tm-id* "http://textgrid.org/serviceregistry/gdl-frontend/gdl-tm")
-(defparameter *gdl-sparql* "/gdl/sparql/?$")
+(defparameter *gdl-sparql* "/gdl/tm-sparql/?$")
(defun set-up-gdl-interface (&key (get-fragment *gdl-get-fragment*)
@@ -26,10 +28,14 @@
(delete-fragment *gdl-delete-fragment*)
(gdl-sparql *gdl-sparql*)
(base-path *gdl-base-path*)
- (host-address *gdl-host-address*)
- (host-file *gdl-host-file*))
+ (host-address-hash-object *gdl-host-address-hash-object*)
+ (host-address-environment *gdl-host-address-environment*)
+ (host-file-hash-object *gdl-host-file-hash-object*)
+ (host-file-environment *gdl-host-file-environment*))
(declare (String get-fragment get-schema commit-fragment
- delete-fragment host-address))
+ delete-fragment host-address-hash-object
+ host-address-environment host-file-hash-object
+ host-file-environment))
;(init-cache nil)
;(format t "~%")
@@ -41,8 +47,8 @@
;; e.g. a json error-message.
(push hunchentoot:+http-internal-server-error+ hunchentoot:*approved-return-codes*)
- (init-hosted-files :host-address host-address :host-file host-file
- :base-path base-path)
+ (init-hosted-files :host-address host-address-hash-object :host-file host-file-hash-object
+ :base-path (concat base-path "hash-object-ui/"))
(push
(create-regex-dispatcher get-fragment #'return-json-fragment-handler)
@@ -65,8 +71,8 @@
hunchentoot:*dispatch-table*))
-(defun init-hosted-files (&key (host-address *gdl-host-address*)
- (host-file *gdl-host-file*)
+(defun init-hosted-files (&key (host-address *gdl-host-address-hash-object*)
+ (host-file *gdl-host-file-hash-object*)
(base-path *gdl-base-path*))
"Adds handlers for the css, html and js files needed by the frontend."
(declare (String host-address host-file base-path))
@@ -94,6 +100,7 @@
(let* ((rel-addr (subseq (namestring item) absolute-base-path-len))
(content-type (generate-content-type (file-namestring item)))
(rel-uri (concat "/" rel-addr)))
+ (format t "rel-addr: ~a~%rel-uri: ~a~%~%" rel-addr rel-uri)
(push
(create-static-file-dispatcher-and-handler
rel-uri item content-type)
More information about the Isidorus-cvs
mailing list