[cxml-cvs] CVS cxml/klacks

dlichteblau dlichteblau at common-lisp.net
Wed Oct 3 15:22:57 UTC 2007


Update of /project/cxml/cvsroot/cxml/klacks
In directory clnet:/tmp/cvs-serv25228

Modified Files:
	klacks.lisp package.lisp 
Log Message:
Minor klacks enhancements.

	klacks/klacks.lisp (CONSUME-CHARACTERS): New function.

	klacks/package.lisp (KLACKS): Export dribble-handler and
	consume-characters.



--- /project/cxml/cvsroot/cxml/klacks/klacks.lisp	2007/05/01 18:21:41	1.8
+++ /project/cxml/cvsroot/cxml/klacks/klacks.lisp	2007/10/03 15:22:57	1.9
@@ -79,6 +79,12 @@
     (check-type key (member :characters))
     characters))
 
+(defun klacks:consume-characters (source)
+  (with-output-to-string (s)
+    (while (eq (klacks:peek source) :characters)
+      (write-string (klacks:current-characters source) s)
+      (klacks:consume source))))
+
 (defun klacks:serialize-event (source handler &key (consume t))
   (multiple-value-bind (key a b c) (klacks:peek source)
     (let ((result nil))
--- /project/cxml/cvsroot/cxml/klacks/package.lisp	2007/05/01 18:21:41	1.6
+++ /project/cxml/cvsroot/cxml/klacks/package.lisp	2007/10/03 15:22:57	1.7
@@ -21,8 +21,10 @@
   (:export #:source
 	   #:close-source
 	   #:with-open-source
+
 	   #:tapping-source
 	   #:make-tapping-source
+	   #:dribble-handler
 
 	   #:peek
 	   #:peek-value
@@ -42,6 +44,7 @@
 	   #:current-lname
 	   #:current-qname
 	   #:current-characters
+	   #:consume-characters
 	   #:current-cdata-section-p
 	   #:map-current-namespace-declarations
 	   




More information about the Cxml-cvs mailing list