Minor doc updates again!
Sun Sep 7 12:22:07 PDT 2008 mail@chaitanyagupta.com
* Minor doc updates again!
diff -rN -u old-cl-bzip2/bzip2.lisp new-cl-bzip2/bzip2.lisp
--- old-cl-bzip2/bzip2.lisp 2014-07-28 19:40:59.000000000 -0700
+++ new-cl-bzip2/bzip2.lisp 2014-07-28 19:40:59.000000000 -0700
@@ -338,13 +338,14 @@
(block-size-100k *block-size-100k*)
(verbosity *verbosity*)
(work-factor *work-factor*))
- "Compresses data from IN to OUT. IN or OUT can either be a binary
- stream or a pathname.
+ "Compresses data from IN to OUT. IN or OUT can either be a
+binary stream or a pathname. This function doesn't return any
+value.
BLOCK-SIZE-100K (default 9), VERBOSITY (default 0) and
- WORK-FACTOR (default 30) correspond to the parameters
- `blockSize100k', `verbosity' and `workFactor', respectively, for
- the libbzip2 function `BZ2_bzCompressInit'.
+WORK-FACTOR (default 30) correspond to the parameters
+`blockSize100k', `verbosity' and `workFactor', respectively, for
+the libbzip2 function `BZ2_bzCompressInit'.
From the bzip2 manual:
@@ -428,12 +429,13 @@
(defun decompress (in out &key
(verbosity *verbosity*)
(smallp *smallp*))
- "Decompresses data from IN to OUT. IN or OUT can either be a binary
- stream or a pathname.
+ "Decompresses data from IN to OUT. IN or OUT can either be a
+binary stream or a pathname. This function doesn't return any
+value.
VERBOSITY and SMALLP (default NIL) correspond to the parameters
- `verbosity' and `small', respectively, for the libbzip2
- function `BZ2_bzDecompressInit'.
+`verbosity' and `small', respectively, for the libbzip2 function
+`BZ2_bzDecompressInit'.
For the meaning of VERBOSITY, see the documentation for
COMPRESS. A non-NIL value for SMALLP corresponds to a non-zero
diff -rN -u old-cl-bzip2/doc/index.html new-cl-bzip2/doc/index.html
--- old-cl-bzip2/doc/index.html 2014-07-28 19:40:59.000000000 -0700
+++ new-cl-bzip2/doc/index.html 2014-07-28 19:40:59.000000000 -0700
@@ -139,7 +139,7 @@
<b>compress</b> <i>in out <tt>&amp;key</tt> block-size-100k verbosity work-factor</i></p>
<blockquote>
- <p>Compresses data from <i><code>IN</code></i> to <i><code>OUT</code></i>. <i><code>IN</code></i> or <i><code>OUT</code></i> can either be a binary stream or a pathname.</p>
+ <p>Compresses data from <i><code>IN</code></i> to <i><code>OUT</code></i>. <i><code>IN</code></i> or <i><code>OUT</code></i> can either be a binary stream or a pathname. This function doesn&#8217;t return any value.</p>
<p><i><code>BLOCK-SIZE-100K</code></i> (default 9), <i><code>VERBOSITY</code></i> (default 0) and <i><code>WORK-FACTOR</code></i> (default 30) correspond to the parameters <i><code>blockSize100k</code></i>, <i><code>verbosity</code></i> and <i><code>workFactor</code></i>, respectively, for the libbzip2 function <i><code>BZ2_bzCompressInit</code></i>.</p>
<p>From the bzip2 manual:</p>
<p>Parameter <i><code>blockSize100k</code></i> specifies the block size to be used for compression. It should be a value between 1 and 9 inclusive, and the actual block size used is 100000 x this figure. 9 gives the best compression but takes most memory.</p>
@@ -151,7 +151,7 @@
<b>decompress</b> <i>in out <tt>&amp;key</tt> verbosity smallp</i></p>
<blockquote>
- <p>Decompresses data from <i><code>IN</code></i> to <i><code>OUT</code></i>. <i><code>IN</code></i> or <i><code>OUT</code></i> can either be a binary stream or a pathname.</p>
+ <p>Decompresses data from <i><code>IN</code></i> to <i><code>OUT</code></i>. <i><code>IN</code></i> or <i><code>OUT</code></i> can either be a binary stream or a pathname. This function doesn&#8217;t return any value.</p>
<p><i><code>VERBOSITY</code></i> and <i><code>SMALLP</code></i> (default <span class="caps">NIL</span>) correspond to the parameters <i><code>verbosity</code></i> and <i><code>small</code></i>, respectively, for the libbzip2 function <i><code>BZ2_bzDecompressInit</code></i>.</p>
<p>For the meaning of <i><code>VERBOSITY</code></i>, see the documentation for <span class="caps">COMPRESS</span>. A non-<span class="caps">NIL</span> value for <i><code>SMALLP</code></i> corresponds to a non-zero value for the parameter <i><code>small</code></i>. Here&#8217;s what the bzip2 manual says about <i><code>small</code></i>:</p>
<p>If <i><code>small</code></i> is nonzero, the library will use an alternative decompression algorithm which uses less memory but at the cost of decompressing more slowly (roughly speaking, half the speed, but the maximum memory requirement drops to around 2300k).</p>
@@ -161,7 +161,7 @@
<p>As of now, cl-bzip2 works only with binary streams. I haven&#8217;t figured out an easy way to make it work with string streams (i.e. easily using them as input). If you know how that can be done, please <a href="#support">let us know</a>.</p>
- <p>Also, performance is definitely not as great as it can be. If you want to fix that, the guts of the code lie in <span class="caps">COMPRESS-STREAM</span> and <span class="caps">COMPRESS-STREAM-AUX</span> (for compression), and <span class="caps">DECOMPRESS-STREAM</span> and <span class="caps">DECOMPRESS-STREAM-AUX</span> (for decompression). Any help would be greatly appreciated!</p>
+ <p>Also, performance <em>might</em> not be as great as you expect. If you want to improve that, the guts of the code lie in <span class="caps">COMPRESS-STREAM</span> and <span class="caps">COMPRESS-STREAM-AUX</span> (for compression), and <span class="caps">DECOMPRESS-STREAM</span> and <span class="caps">DECOMPRESS-STREAM-AUX</span> (for decompression). Any help would be greatly appreciated!</p>
<h3 id="acknowledgements">Acknowledgements</h3>
diff -rN -u old-cl-bzip2/doc/index.textile new-cl-bzip2/doc/index.textile
--- old-cl-bzip2/doc/index.textile 2014-07-28 19:40:59.000000000 -0700
+++ new-cl-bzip2/doc/index.textile 2014-07-28 19:40:59.000000000 -0700
@@ -56,18 +56,18 @@
<pre><code>
;;; Compression usage
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
;;; No values are returned if execution was successful
;;; Using pathnames
CL-USER> (bzip2:compress #p"test.txt" #p"test.txt.bz2")
; No value
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
;;; Using binary streams
CL-USER> (with-open-file (in "test.txt" :direction :input :element-type '(unsigned-byte 8))
(with-open-file (out "test.txt.bz2" :direction :output :element-type '(unsigned-byte 8))
(bzip2:compress in out)))
; No value
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
;;; Mixing stream and pathname
CL-USER> (with-open-file (in "test.txt" :direction :input :element-type '(unsigned-byte 8))
(bzip2:compress in #p"test.txt.bz2"))
@@ -80,11 +80,11 @@
<pre><code>
;;; Decompression usage is similar to that for compression
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
;;; Using pathnames
CL-USER> (bzip2:decompress #p"test.txt.bz2" #p"test.txt")
; No value
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
;;; Using binary streams
CL-USER> (with-open-file (in "test.txt.bz2" :direction :input :element-type '(unsigned-byte 8))
(with-open-file (out "test.txt" :direction :output :element-type '(unsigned-byte 8))
@@ -99,19 +99,19 @@
<pre><code>
CL-USER> (defvar *vec* #(66 104 97 107 99 104 111 100 105 32 109 97 116 32 107 97 114 111 46))
*VEC*
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
CL-USER> (flex:with-input-from-sequence (in *vec*)
(flex:with-output-to-sequence (out)
(bzip2:compress in out)))
#(66 90 104 57 49 65 89 38 83 89 188 189 88 250 0 0 1 149 128 64 1 16 0
44 106 148 0 32 0 34 4 245 52 204 144 128 104 3 109 12 42 5 148 84
110 113 190 46 228 138 112 161 33 121 122 177 244)
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
CL-USER> (flex:with-input-from-sequence (in *)
(flex:with-output-to-sequence (out)
(bzip2:decompress in out)))
#(66 104 97 107 99 104 111 100 105 32 109 97 116 32 107 97 114 111 46)
-;;; Remove me ;;;
+==<!-- TMPL_VAR remove-me -->==
CL-USER> (equalp * *vec*)
T
</code></pre>
@@ -126,7 +126,7 @@
p(symbol#compress). [Function]
<b>compress</b> <i>in out <tt>&amp;key</tt> block-size-100k verbosity work-factor</i>
-bq.. Compresses data from <i>@IN@</i> to <i>@OUT@</i>. <i>@IN@</i> or <i>@OUT@</i> can either be a binary stream or a pathname.
+bq.. Compresses data from <i>@IN@</i> to <i>@OUT@</i>. <i>@IN@</i> or <i>@OUT@</i> can either be a binary stream or a pathname. This function doesn't return any value.
<i>@BLOCK-SIZE-100K@</i> (default 9), <i>@VERBOSITY@</i> (default 0) and <i>@WORK-FACTOR@</i> (default 30) correspond to the parameters <i>@blockSize100k@</i>, <i>@verbosity@</i> and <i>@workFactor@</i>, respectively, for the libbzip2 function <i>@BZ2_bzCompressInit@</i>.
@@ -141,7 +141,7 @@
p(symbol#decompress). [Function]
<b>decompress</b> <i>in out <tt>&amp;key</tt> verbosity smallp</i>
-bq.. Decompresses data from <i>@IN@</i> to <i>@OUT@</i>. <i>@IN@</i> or <i>@OUT@</i> can either be a binary stream or a pathname.
+bq.. Decompresses data from <i>@IN@</i> to <i>@OUT@</i>. <i>@IN@</i> or <i>@OUT@</i> can either be a binary stream or a pathname. This function doesn't return any value.
<i>@VERBOSITY@</i> and <i>@SMALLP@</i> (default NIL) correspond to the parameters <i>@verbosity@</i> and <i>@small@</i>, respectively, for the libbzip2 function <i>@BZ2_bzDecompressInit@</i>.
@@ -153,7 +153,7 @@
As of now, cl-bzip2 works only with binary streams. I haven't figured out an easy way to make it work with string streams (i.e. easily using them as input). If you know how that can be done, please "let us know":#support.
-Also, performance is definitely not as great as it can be. If you want to fix that, the guts of the code lie in COMPRESS-STREAM and COMPRESS-STREAM-AUX (for compression), and DECOMPRESS-STREAM and DECOMPRESS-STREAM-AUX (for decompression). Any help would be greatly appreciated!
+Also, performance _might_ not be as great as you expect. If you want to improve that, the guts of the code lie in COMPRESS-STREAM and COMPRESS-STREAM-AUX (for compression), and DECOMPRESS-STREAM and DECOMPRESS-STREAM-AUX (for decompression). Any help would be greatly appreciated!
h3(#acknowledgements). Acknowledgements