The cl-qprint Reference Manual

This is the cl-qprint Reference Manual, version 0.9.9, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Sep 15 04:22:31 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 cl-qprint

Encode and decode quoted-printable encoded strings.

Maintainer

Max Rottenkolber <>

Author

Robert Marlow <>

Version

0.9.9

Dependency

flexi-streams (system).

Source

cl-qprint.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 cl-qprint/cl-qprint.asd

Source

cl-qprint.asd.

Parent Component

cl-qprint (system).

ASDF Systems

cl-qprint.

Packages

cl-qprint-system.


3.1.2 cl-qprint/base.lisp

Source

cl-qprint.asd.

Parent Component

cl-qprint (system).

Packages

cl-qprint.

Public Interface
Internals

3.1.3 cl-qprint/test.lisp

Dependency

base.lisp (file).

Source

cl-qprint.asd.

Parent Component

cl-qprint (system).

Packages

cl-qprint-test.

Public Interface

test-cl-qprint (function).

Internals

4 Packages

Packages are listed by definition order.


4.1 cl-qprint-test

Test routines for CL-QPRINT.

Source

test.lisp.

Use List
Public Interface

test-cl-qprint (function).

Internals

4.2 cl-qprint

Encode and decode quoted-printable encoded strings as defined by [RFC 2045](http://tools.ietf.org/html/rfc2045).

Source

base.lisp.

Nicknames
  • qprint
  • quoted-printable
Use List
  • common-lisp.
  • flexi-streams.
Used By List

cl-qprint-test.

Public Interface
Internals

4.3 cl-qprint-system

Source

cl-qprint.asd.

Use List
  • asdf/interface.
  • common-lisp.

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Ordinary functions

Function: decode (input &key error-p)

*Arguments and Values:*

_input_—a _string_ or a _character stream_.

_error-p_—a _generalized boolean_. The default is false.

*Description*:

{decode} reads from _quoted-printable_ encoded _input_ and returns a decoded _vector_ with {(unsigned-byte 8)} as its _element type_.

*Exceptional Situations:*

If _error-p_ is _true_, an error of _type_ {decode-error} signaled when _input_ is malformed.

Package

cl-qprint.

Source

base.lisp.

Function: encode (input &key columns)

*Arguments and Values:*

_input_—a _vector_ or a _stream_ with element type {(unsigned-byte 8)}.

_columns_—a positive _integer_.

*Description*:

{encode} reads from _input_ and returns a _quoted-printable_ encoded _string_. _Columns_ denotes the maximum line length of _string_.

Package

cl-qprint.

Source

base.lisp.

Function: test-cl-qprint ()

Test integritiy of CL-QPRINT by asserting the following to be true:

{(EQUALP (DECODE (ENCODE input)) input)}

for {input} being randomized data.

Package

cl-qprint-test.

Source

test.lisp.


5.1.2 Conditions

Condition: decode-error

The _type_ {decode-error} consists of error conditions related to malformed encodings.

Package

cl-qprint.

Source

base.lisp.

Direct superclasses

error.


5.2 Internals


5.2.1 Special variables

Special Variable: *ascii-!*

ASCII code for exclamation mark character.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *ascii-=*

ASCII code for equal sign character.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *ascii-whitespace*

List of ASCII codes of whitespace characters.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *ascii-~*

ASCII code for tilde character.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *encoded-crlf*

CRLF string.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *soft-line-break*

Soft line break.

Package

cl-qprint.

Source

base.lisp.

Special Variable: *test-iterations*

Number of random strings tested.

Package

cl-qprint-test.

Source

test.lisp.

Special Variable: *value-range*

Range of values in random vectors.

Package

cl-qprint-test.

Source

test.lisp.


5.2.2 Ordinary functions

Function: byte-encoding (byte)

Produce quoted-printable encoding string for BYTE.

Package

cl-qprint.

Source

base.lisp.

Function: char-code-ascii (char)

Return ASCII code for CHAR.

Package

cl-qprint.

Source

base.lisp.

Function: code-char-ascii (code)

Return ASCII character for CODE.

Package

cl-qprint.

Source

base.lisp.

Function: decode-byte (char2 char3)

Decode byte encoded by CHAR2 and CHAR2.

Package

cl-qprint.

Source

base.lisp.

Function: decode-quoted (char2 char3 &key error-p)

Decode quoted CHAR2 and CHAR3, signal DECODE-ERROR when ERROR-P is non NIL and sequence is invalid.

Package

cl-qprint.

Source

base.lisp.

Function: encode-byte (byte)

Encode BYTE for quoted-printable encoding and return string.

Package

cl-qprint.

Source

base.lisp.

Function: encode-byte-p (byte)

Predicate to check wether BYTE has to be encoded in quoted-printable encoding.

Package

cl-qprint.

Source

base.lisp.

Function: plain-char-code (char &key error-p)

Return ASCII code for unencoded CHAR if possible otherwise return NIL or signal DECODE-ERROR depending on ERROR-P.

Package

cl-qprint.

Source

base.lisp.

Function: random-vector (length)

Return a random vector of LENGTH.

Package

cl-qprint-test.

Source

test.lisp.

Function: upper-case-hex-p (char)

Predicate to check if CHAR is a upper case hexadecimal digit.

Package

cl-qprint.

Source

base.lisp.


Appendix A Indexes


A.1 Concepts