The vom Reference Manual

This is the vom Reference Manual, version 0.1.4, generated automatically by Declt version 4.0 beta 2 "William Riker" on Mon Feb 26 18:16:19 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

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


2.1 vom

A tiny logging utility.

Author

Andrew Danger Lyon <>

License

MIT

Version

0.1.4

Source

vom.asd.

Child Component

vom.lisp (file).


3 Files

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


3.1 Lisp


3.1.1 vom/vom.asd

Source

vom.asd.

Parent Component

vom (system).

ASDF Systems

vom.


3.1.2 vom/vom.lisp

Source

vom.asd.

Parent Component

vom (system).

Packages

vom.

Public Interface
Internals

4 Packages

Packages are listed by definition order.


4.1 vom

Source

vom.lisp.

Public Interface
Internals

5 Definitions

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


5.1 Public Interface


5.1.1 Special variables

Special Variable: *config*

Holds the logging config as a plist. Holds package -> level mappings, using T as the default (used if logging from a package that hasn’t been configured).

Package

vom.

Source

vom.lisp.

Special Variable: *log-formatter*

A function that takes a format string (user-supplied), a level string (eg ’notice’ or ’error’), a keyword of the current package, and a list of args the user supplied with the format string and returns a string of the log line we want logged.

Package

vom.

Source

vom.lisp.

Special Variable: *log-hook*

Holds a function that, given a log-level, a package name, and the effective log-level for that package, returns one or more (via (values ...)) streams that this log will be sent to.

Package

vom.

Source

vom.lisp.

Special Variable: *log-stream*

Holds the default stream we’re logging to.

Package

vom.

Source

vom.lisp.

Special Variable: *time-formatter*

A function of 0 args that returns the current time in the desired format.

Package

vom.

Source

vom.lisp.


5.1.2 Macros

Macro: alert (format-str &rest args)

Log output to the :ALERT log level (2)

Package

vom.

Alias for

log-alert.

Macro: crit (format-str &rest args)

Log output to the :CRIT log level (3)

Package

vom.

Alias for

log-crit.

Macro: debug (format-str &rest args)

Log output to the :DEBUG log level (8)

Package

vom.

Alias for

log-debug.

Macro: debug1 (format-str &rest args)

Log output to the :DEBUG1 log level (9)

Package

vom.

Alias for

log-debug1.

Macro: debug2 (format-str &rest args)

Log output to the :DEBUG2 log level (10)

Package

vom.

Alias for

log-debug2.

Macro: debug3 (format-str &rest args)

Log output to the :DEBUG3 log level (11)

Package

vom.

Alias for

log-debug3.

Macro: debug4 (format-str &rest args)

Log output to the :DEBUG4 log level (12)

Package

vom.

Alias for

log-debug4.

Macro: emerg (format-str &rest args)

Log output to the :EMERG log level (1)

Package

vom.

Alias for

log-emerg.

Macro: error (format-str &rest args)

Log output to the :ERROR log level (4)

Package

vom.

Alias for

log-error.

Macro: info (format-str &rest args)

Log output to the :INFO log level (7)

Package

vom.

Alias for

log-info.

Macro: notice (format-str &rest args)

Log output to the :NOTICE log level (6)

Package

vom.

Alias for

log-notice.

Macro: warn (format-str &rest args)

Log output to the :WARN log level (5)

Package

vom.

Alias for

log-warn.


5.1.3 Ordinary functions

Function: config (package-keyword level-name)

Configure the log level for a package (or use t for the package name to set the default log level). The log level is given as a keyword.

Package

vom.

Source

vom.lisp.


5.2 Internals


5.2.1 Special variables

Special Variable: *levels*

Holds the log level mappings (keyword -> value).

Package

vom.

Source

vom.lisp.

Special Variable: *max-level-name-length*

Holds the number of characters in the longest log-level name.

Package

vom.

Source

vom.lisp.

Special Variable: *package-level-cache*

A cache that holds package alias -> package loglevel values for quick lookup.

Package

vom.

Source

vom.lisp.


5.2.2 Macros

Macro: define-level (name level-value)

Define a log level.

Package

vom.

Source

vom.lisp.

Macro: log-alert (format-str &rest args)

Log output to the :ALERT log level (2)

Package

vom.

Source

vom.lisp.

Macro: log-crit (format-str &rest args)

Log output to the :CRIT log level (3)

Package

vom.

Source

vom.lisp.

Macro: log-debug (format-str &rest args)

Log output to the :DEBUG log level (8)

Package

vom.

Source

vom.lisp.

Macro: log-debug1 (format-str &rest args)

Log output to the :DEBUG1 log level (9)

Package

vom.

Source

vom.lisp.

Macro: log-debug2 (format-str &rest args)

Log output to the :DEBUG2 log level (10)

Package

vom.

Source

vom.lisp.

Macro: log-debug3 (format-str &rest args)

Log output to the :DEBUG3 log level (11)

Package

vom.

Source

vom.lisp.

Macro: log-debug4 (format-str &rest args)

Log output to the :DEBUG4 log level (12)

Package

vom.

Source

vom.lisp.

Macro: log-emerg (format-str &rest args)

Log output to the :EMERG log level (1)

Package

vom.

Source

vom.lisp.

Macro: log-error (format-str &rest args)

Log output to the :ERROR log level (4)

Package

vom.

Source

vom.lisp.

Macro: log-info (format-str &rest args)

Log output to the :INFO log level (7)

Package

vom.

Source

vom.lisp.

Macro: log-notice (format-str &rest args)

Log output to the :NOTICE log level (6)

Package

vom.

Source

vom.lisp.

Macro: log-warn (format-str &rest args)

Log output to the :WARN log level (5)

Package

vom.

Source

vom.lisp.


5.2.3 Ordinary functions

Function: clear-level-cache ()

Clears the package loglevel cache.

Package

vom.

Source

vom.lisp.

Function: do-log (level-name log-level package-keyword format-str &rest args)

The given data to the current *log-stream* stream.

Package

vom.

Source

vom.lisp.

Function: find-package-level (package-keyword)

Given package keyword (doesn’t have to be an exact match, can be an alias), find the configured loglevel of that package.

This caches the package->level connection in *package-level-cache*.

Package

vom.

Source

vom.lisp.


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   A   C   D   E   F   I   L   M   N   W  
Index Entry  Section

A
alert: Public macros

C
clear-level-cache: Private ordinary functions
config: Public ordinary functions
crit: Public macros

D
debug: Public macros
debug1: Public macros
debug2: Public macros
debug3: Public macros
debug4: Public macros
define-level: Private macros
do-log: Private ordinary functions

E
emerg: Public macros
error: Public macros

F
find-package-level: Private ordinary functions
Function, clear-level-cache: Private ordinary functions
Function, config: Public ordinary functions
Function, do-log: Private ordinary functions
Function, find-package-level: Private ordinary functions

I
info: Public macros

L
log-alert: Private macros
log-crit: Private macros
log-debug: Private macros
log-debug1: Private macros
log-debug2: Private macros
log-debug3: Private macros
log-debug4: Private macros
log-emerg: Private macros
log-error: Private macros
log-info: Private macros
log-notice: Private macros
log-warn: Private macros

M
Macro, alert: Public macros
Macro, crit: Public macros
Macro, debug: Public macros
Macro, debug1: Public macros
Macro, debug2: Public macros
Macro, debug3: Public macros
Macro, debug4: Public macros
Macro, define-level: Private macros
Macro, emerg: Public macros
Macro, error: Public macros
Macro, info: Public macros
Macro, log-alert: Private macros
Macro, log-crit: Private macros
Macro, log-debug: Private macros
Macro, log-debug1: Private macros
Macro, log-debug2: Private macros
Macro, log-debug3: Private macros
Macro, log-debug4: Private macros
Macro, log-emerg: Private macros
Macro, log-error: Private macros
Macro, log-info: Private macros
Macro, log-notice: Private macros
Macro, log-warn: Private macros
Macro, notice: Public macros
Macro, warn: Public macros

N
notice: Public macros

W
warn: Public macros