This is the cl-grip Reference Manual, version 0.0.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Sep 15 04:03:50 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
cl-grip
Grip is a simple logging interface and framework. The core package contains basic infrastructure and interfaces.
Sam Kleinman <sam@tychoish.com>
Apache v2
0.0.1
local-time
(system).
cl-strings
(system).
trivial-types
(system).
src
(module).
Modules are listed depth-first from the system components tree.
cl-grip/src
cl-grip
(system).
level.lisp
(file).
message.lisp
(file).
logger.lisp
(file).
grip.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
cl-grip/cl-grip.asd
cl-grip/src/level.lisp
cl-grip/src/message.lisp
cl-grip/src/logger.lisp
cl-grip/src/grip.lisp
cl-grip/src/level.lisp
src
(module).
+alert+
(special variable).
+critical+
(special variable).
+debug+
(special variable).
+emergency+
(special variable).
+error+
(special variable).
+info+
(special variable).
+notice+
(special variable).
+trace+
(special variable).
+warning+
(special variable).
make-priority
(function).
priority
(class).
priority-string
(generic function).
priority-value
(reader method).
priority>=
(generic function).
string-for-level
(function).
cl-grip/src/message.lisp
level.lisp
(file).
src
(module).
base-message
(class).
basic-formatter
(class).
batch-message
(class).
export-message
(generic function).
format-config
(class).
format-timestamp
(reader method).
(setf format-timestamp)
(writer method).
loggable-p
(generic function).
make-message
(generic function).
merge-messages
(generic function).
message-batch
(reader method).
(setf message-batch)
(writer method).
message-conditional
(reader method).
(setf message-conditional)
(writer method).
message-level
(reader method).
(setf message-level)
(method).
(setf message-level)
(writer method).
message-payload
(reader method).
message-payload
(reader method).
message-payload
(reader method).
(setf message-payload)
(writer method).
(setf message-payload)
(writer method).
(setf message-payload)
(writer method).
message-timestamp
(reader method).
new-message
(function).
resolve-output
(generic function).
simple-message
(class).
sprintf-message
(class).
structured-message
(class).
export-message-p
(function).
message-sprintf-args
(reader method).
(setf message-sprintf-args)
(writer method).
message-sprintf-template
(reader method).
(setf message-sprintf-template)
(writer method).
sprintf
(function).
cl-grip/src/logger.lisp
level.lisp
(file).
message.lisp
(file).
src
(module).
alert>
(generic function).
base-journal
(class).
critical>
(generic function).
debug>
(generic function).
emergency>
(generic function).
error>
(generic function).
format-message
(generic function).
info>
(generic function).
log>
(generic function).
merge-journals
(generic function).
merged-journal
(class).
message-formatter
(reader method).
(setf message-formatter)
(writer method).
name
(reader method).
(setf name)
(writer method).
notice>
(generic function).
output-target
(reader method).
output-target
(reader method).
(setf output-target)
(writer method).
(setf output-target)
(writer method).
send-message
(generic function).
stream-journal
(class).
threshold
(reader method).
(setf threshold)
(writer method).
trace>
(generic function).
warning>
(generic function).
cl-grip/src/grip.lisp
level.lisp
(file).
message.lisp
(file).
logger.lisp
(file).
src
(module).
grip
.
Packages are listed by definition order.
grip.message
common-lisp
.
grip.level
.
base-message
(class).
basic-formatter
(class).
batch-message
(class).
export-message
(generic function).
format-config
(class).
format-timestamp
(generic reader).
(setf format-timestamp)
(generic writer).
loggable-p
(generic function).
make-message
(generic function).
merge-messages
(generic function).
message-batch
(generic reader).
(setf message-batch)
(generic writer).
message-conditional
(generic reader).
(setf message-conditional)
(generic writer).
message-level
(generic reader).
(setf message-level)
(generic function).
message-payload
(generic reader).
(setf message-payload)
(generic writer).
message-timestamp
(generic reader).
new-message
(function).
resolve-output
(generic function).
simple-message
(class).
sprintf-message
(class).
structured-message
(class).
export-message-p
(function).
message-sprintf-args
(generic reader).
(setf message-sprintf-args)
(generic writer).
message-sprintf-template
(generic reader).
(setf message-sprintf-template)
(generic writer).
sprintf
(function).
grip.logger
Logger contains basic implementation of logging
implementations ’journal’ with limited external dependencies, and
related interface.
common-lisp
.
grip.message
.
alert>
(generic function).
base-journal
(class).
critical>
(generic function).
debug>
(generic function).
emergency>
(generic function).
error>
(generic function).
format-message
(generic function).
info>
(generic function).
log>
(generic function).
merge-journals
(generic function).
merged-journal
(class).
message-formatter
(generic reader).
(setf message-formatter)
(generic writer).
name
(generic reader).
(setf name)
(generic writer).
notice>
(generic function).
output-target
(generic reader).
(setf output-target)
(generic writer).
send-message
(generic function).
stream-journal
(class).
threshold
(generic reader).
(setf threshold)
(generic writer).
trace>
(generic function).
warning>
(generic function).
grip.level
common-lisp
.
+alert+
(special variable).
+critical+
(special variable).
+debug+
(special variable).
+emergency+
(special variable).
+error+
(special variable).
+info+
(special variable).
+notice+
(special variable).
+trace+
(special variable).
+warning+
(special variable).
make-priority
(function).
priority
(class).
priority-string
(generic function).
priority-value
(generic reader).
priority>=
(generic function).
string-for-level
(function).
Definitions are sorted by export status, category, package, and then by lexicographic order.
default package logger, should not be exported
Constructs a new message from an input type, with optional
parameters:
LEVEL: sets the level of the message that’s created, defaulting to debug.
WHEN: sets the conditional flag, making it possible to avoid wrapping
log statements in conditionals, to render a log statement
un-loggable.
ARGS: When the input is a string and args, this will produce a message that is roughly equivalent to ’sprintf’ in other languages, though this implementation caches the string (for multi-output reuse) and supports both the ’format’ macro’s syntax when the args list is a proper list, or a double-bracketed token form when the the args list is an alist.
Sends the message to a logger at level
’alert’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Sends the message to a logger at level
’alert’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Sends the message to a logger at level
’debug’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Sends the message to a logger at level
’emergency’. This functionality is provided as a generic method to
make it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Sends the message to a logger at level
’debug’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Tmplement export-message to support messages which can convert themselves into message objects.
implement format-message to control message output
base-journal
) (fmt basic-formatter
) (msg base-message
)) ¶format-config
) (msg base-message
)) ¶basic-formatter
)) ¶automatically generated reader method
basic-formatter
)) ¶automatically generated writer method
Sends the message to a logger at level ’info’. This
functionality is provided as a generic method to make it possible to
extend or override for some logging implementations. The default
implementation wraps ’log’.
provides a basic shim between send-message and
logging methods and makes it possible to deliver messages to
different log levels.
test if a message is logable
batch-message
) (threshold priority
)) ¶sprintf-message
) (threshold priority
)) ¶simple-message
) (threshold priority
)) ¶structured-message
) (threshold priority
)) ¶base-message
) (threshold priority
)) ¶method to convert an arbitrary type to a message implementation
priority
) (msg base-message
)) ¶takes two journals and combines or merges them into a single stream, as best as possible
merged-journal
) (logger base-journal
)) ¶base-journal
) (second base-journal
)) ¶base-journal
) (base merged-journal
)) ¶merged-journal
) (second merged-journal
)) ¶combines one or more messages into a batch message
returning the message. If one or both of the messages is already a
batch message then the constituent messages are produced.
batch-message
) (two batch-message
)) ¶base-message
) (batch batch-message
)) ¶base-message
) (two base-message
)) ¶batch-message
) (message base-message
)) ¶batch-message
)) ¶automatically generated reader method
batch-message
)) ¶automatically generated writer method
base-message
)) ¶automatically generated reader method
base-message
)) ¶automatically generated writer method
base-journal
)) ¶automatically generated reader method
base-journal
)) ¶automatically generated writer method
base-message
)) ¶automatically generated reader method
batch-message
)) ¶base-message
)) ¶automatically generated writer method
sprintf-message
)) ¶automatically generated reader method
simple-message
)) ¶automatically generated reader method
structured-message
)) ¶automatically generated reader method
data
.
sprintf-message
)) ¶automatically generated writer method
simple-message
)) ¶automatically generated writer method
structured-message
)) ¶automatically generated writer method
data
.
base-message
)) ¶automatically generated reader method
base-journal
)) ¶automatically generated reader method
name
.
base-journal
)) ¶automatically generated writer method
name
.
Sends the message to a logger at level
’notice’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
merged-journal
)) ¶automatically generated reader method
stream-journal
)) ¶automatically generated reader method
merged-journal
)) ¶automatically generated writer method
stream-journal
)) ¶automatically generated writer method
returns the name of a priority level
implements a greater than or equal to comparison
for priority objects, as well as comparisons between numbers
priority objects.
should produce a formatted string with data for
human consumption in logging output. This should only include the
message’s string form and payload content, other preparation of the
message, including metadata should be handled by ’format-message’
structured-message
)) ¶simple-message
)) ¶sprintf-message
)) ¶fundamental mesage sending method.
merged-journal
) (msg base-message
)) ¶batch-message
)) ¶base-journal
) (msg base-message
)) ¶stream-journal
) (msg base-message
)) ¶base-journal
)) ¶automatically generated reader method
base-journal
)) ¶automatically generated writer method
Sends the message to a logger at level
’trace’. This functionality is provided as a generic method to make
it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
Sends the message to a logger at level
’warning’. This functionality is provided as a generic method to
make it possible to extend or override for some logging
implementations. The default implementation wraps ’log’.
a basic implementation of a journal logger, that
can be used as the super-class of most or all journal
implementations. Generally subclasses only need to implement
send-message
grip.level:priority
grip.level:+info+
:threshold
common-lisp
.
grip.message:format-config
(make-instance (quote grip.message:basic-formatter))
:format
basic message is a complete implementation of the
message protocol, and is the primary form for all messages. To log
arbitrary types, either convert them to a base-message subclass by
implementing ’export-message’ method, or implement ’export-message’
or ’make-message’ as well as ’send-message’. In most cases,
’send-message’ implementations should generally rely on the
’format-message’, ’resolve-output’ and ’loggable-p’ methods.
boolean
t
:when
local-time:timestamp
(local-time:now)
This slot is read-only.
grip.level:priority
grip.level:+trace+
:level
a holder for configuration, composed by the journal implementation to allow pluggable message formatting.
(quote (:year #\/ (:month 2) #\/ (:day 2) #\ (:hour 2) #\: (:min 2) #\: (:sec 2)))
:timestamp
batch message provides an implementation of
messages that holds a group of message objects rather than a single
message.
(make-array 2 :adjustable t :fill-pointer 0)
the basic formater class serves as the root class
for all formater implementations and provides a simple ’plain’
formating output.
a journal implementation that dispatches messages to more than one output for every message sent
(make-array 0 :element-type (quote grip.logger:base-journal) :adjustable t :fill-pointer 0)
defines a log level or priority to be associated with messages
integer
:value
This slot is read-only.
Simple messages just wrap a single string.
string
""
:payload
a simple logger that writes to a specific stream
stream
*standard-output*
:output-target
Structured messages are those which wrap alist, plist, hash-maps.
:payload
Returns true if the message object implements has an applicable message implementation.
sprintf-message
)) ¶automatically generated reader method
args
.
sprintf-message
)) ¶automatically generated writer method
args
.
sprintf-message
)) ¶automatically generated reader method
sprintf-message
)) ¶automatically generated writer method
Jump to: | (
A C D E F G I L M N O P R S T W |
---|
Jump to: | (
A C D E F G I L M N O P R S T W |
---|
Jump to: | *
+
A B C D F L N O S T V |
---|
Jump to: | *
+
A B C D F L N O S T V |
---|
Jump to: | B C F G L M P S |
---|
Jump to: | B C F G L M P S |
---|