Next: Introduction, Previous: (dir), Up: (dir) [Contents][Index]
This is the common-doc Reference Manual, version 0.2, generated automatically by Declt version 3.0 "Montgomery Scott" on Tue Dec 22 13:09:45 2020 GMT+0.
• Introduction | What common-doc is all about | |
• Systems | The systems documentation | |
• Modules | The modules documentation | |
• Files | The files documentation | |
• Packages | The packages documentation | |
• Definitions | The symbols documentation | |
• Indexes | Concepts, functions, variables and data types |
A framework for representing and manipulating documents as CLOS objects.
See the documentation.
Copyright (c) 2014-2015 Fernando Borretti
Licensed under the MIT License.
Next: Modules, Previous: Introduction, Up: Top [Contents][Index]
The main system appears first, followed by any subsystem dependency.
• The common-doc system |
Fernando Borretti <eudoxiahp@gmail.com>
Fernando Borretti <eudoxiahp@gmail.com>
(:git "git@github.com:commondoc/common-doc.git")
MIT
A framework for representing and manipulating documents as CLOS objects.
# CommonDoc
[](https://travis-ci.org/CommonDoc/common-doc)
[](https://coveralls.io/r/CommonDoc/common-doc?branch=master)
[](http://quickdocs.org/common-doc/)
A framework for representing and manipulating documents as CLOS objects.
See the [documentation](http://commondoc.github.io/docs/overview.html).
# Libraries
* [CommonHTML](https://github.com/CommonDoc/common-html) [](https://travis-ci.org/CommonDoc/common-html)
* [VerTeX](https://github.com/CommonDoc/vertex) [](https://travis-ci.org/CommonDoc/vertex)
* [Codex](https://github.com/CommonDoc/codex) [](https://travis-ci.org/CommonDoc/codex)
* [ParenML](https://github.com/CommonDoc/parenml) [](https://travis-ci.org/CommonDoc/parenml)
* [Thorn](https://github.com/CommonDoc/thorn) [](https://travis-ci.org/CommonDoc/thorn)
# License
Copyright (c) 2014-2015 Fernando Borretti
Licensed under the MIT License.
0.2
common-doc.asd (file)
src (module)
Modules are listed depth-first from the system components tree.
• The common-doc/src module | ||
• The common-doc/src/operations module |
Next: The common-doc/src/operations module, Previous: Modules, Up: Modules [Contents][Index]
common-doc (system)
src/
Previous: The common-doc/src module, Up: Modules [Contents][Index]
util.lisp (file)
src (module)
src/operations/
Files are sorted by type and then listed depth-first from the systems components trees.
• Lisp files |
Next: The common-doc/src/packages․lisp file, Previous: Lisp files, Up: Lisp files [Contents][Index]
common-doc.asd
common-doc (system)
Next: The common-doc/src/define․lisp file, Previous: The common-doc․asd file, Up: Lisp files [Contents][Index]
src (module)
src/packages.lisp
Next: The common-doc/src/error․lisp file, Previous: The common-doc/src/packages․lisp file, Up: Lisp files [Contents][Index]
packages.lisp (file)
src (module)
src/define.lisp
Next: The common-doc/src/file․lisp file, Previous: The common-doc/src/define․lisp file, Up: Lisp files [Contents][Index]
define.lisp (file)
src (module)
src/error.lisp
Next: The common-doc/src/classes․lisp file, Previous: The common-doc/src/error․lisp file, Up: Lisp files [Contents][Index]
error.lisp (file)
src (module)
src/file.lisp
Next: The common-doc/src/metadata․lisp file, Previous: The common-doc/src/file․lisp file, Up: Lisp files [Contents][Index]
file.lisp (file)
src (module)
src/classes.lisp
Next: The common-doc/src/constructors․lisp file, Previous: The common-doc/src/classes․lisp file, Up: Lisp files [Contents][Index]
classes.lisp (file)
src (module)
src/metadata.lisp
Next: The common-doc/src/macros․lisp file, Previous: The common-doc/src/metadata․lisp file, Up: Lisp files [Contents][Index]
metadata.lisp (file)
src (module)
src/constructors.lisp
construct (function)
Next: The common-doc/src/format․lisp file, Previous: The common-doc/src/constructors․lisp file, Up: Lisp files [Contents][Index]
constructors.lisp (file)
src (module)
src/macros.lisp
Next: The common-doc/src/util․lisp file, Previous: The common-doc/src/macros․lisp file, Up: Lisp files [Contents][Index]
macros.lisp (file)
src (module)
src/format.lisp
Next: The common-doc/src/operations/traverse․lisp file, Previous: The common-doc/src/format․lisp file, Up: Lisp files [Contents][Index]
format.lisp (file)
src (module)
src/util.lisp
string-to-slug (function)
Next: The common-doc/src/operations/figures․lisp file, Previous: The common-doc/src/util․lisp file, Up: Lisp files [Contents][Index]
operations (module)
src/operations/traverse.lisp
Next: The common-doc/src/operations/tables․lisp file, Previous: The common-doc/src/operations/traverse․lisp file, Up: Lisp files [Contents][Index]
traverse.lisp (file)
operations (module)
src/operations/figures.lisp
Next: The common-doc/src/operations/links․lisp file, Previous: The common-doc/src/operations/figures․lisp file, Up: Lisp files [Contents][Index]
figures.lisp (file)
operations (module)
src/operations/tables.lisp
collect-tables (function)
Next: The common-doc/src/operations/text․lisp file, Previous: The common-doc/src/operations/tables․lisp file, Up: Lisp files [Contents][Index]
tables.lisp (file)
operations (module)
src/operations/links.lisp
collect-external-links (function)
Next: The common-doc/src/operations/unique-ref․lisp file, Previous: The common-doc/src/operations/links․lisp file, Up: Lisp files [Contents][Index]
links.lisp (file)
operations (module)
src/operations/text.lisp
collect-all-text (function)
Next: The common-doc/src/operations/toc․lisp file, Previous: The common-doc/src/operations/text․lisp file, Up: Lisp files [Contents][Index]
text.lisp (file)
operations (module)
src/operations/unique-ref.lisp
fill-unique-refs (function)
Next: The common-doc/src/operations/equality․lisp file, Previous: The common-doc/src/operations/unique-ref․lisp file, Up: Lisp files [Contents][Index]
unique-ref.lisp (file)
operations (module)
src/operations/toc.lisp
table-of-contents (function)
Next: The common-doc/src/print․lisp file, Previous: The common-doc/src/operations/toc․lisp file, Up: Lisp files [Contents][Index]
toc.lisp (file)
operations (module)
src/operations/equality.lisp
Previous: The common-doc/src/operations/equality․lisp file, Up: Lisp files [Contents][Index]
operations (module)
src (module)
src/print.lisp
Next: Definitions, Previous: Files, Up: Top [Contents][Index]
Packages are listed by definition order.
Next: The common-doc․file package, Previous: Packages, Up: Packages [Contents][Index]
CommonDoc input/output formats.
packages.lisp (file)
Next: The common-doc․error package, Previous: The common-doc․format package, Up: Packages [Contents][Index]
File-related operations for CommonDoc.
packages.lisp (file)
common-lisp
Next: The common-doc․macro package, Previous: The common-doc․file package, Up: Packages [Contents][Index]
CommonDoc errors.
packages.lisp (file)
common-lisp
Next: The common-doc․util package, Previous: The common-doc․error package, Up: Packages [Contents][Index]
CommonDoc macros.
packages.lisp (file)
common-lisp
Next: The common-doc package, Previous: The common-doc․macro package, Up: Packages [Contents][Index]
CommonDoc utilities.
packages.lisp (file)
string-to-slug (function)
Next: The common-doc․ops package, Previous: The common-doc․util package, Up: Packages [Contents][Index]
CommonDoc classes and and accessors.
packages.lisp (file)
Previous: The common-doc package, Up: Packages [Contents][Index]
Common operations on CommonDoc documents.
packages.lisp (file)
Definitions are sorted by export status, category, package, and then by lexicographic order.
• Exported definitions | ||
• Internal definitions |
Next: Internal definitions, Previous: Definitions, Up: Definitions [Contents][Index]
• Exported special variables | ||
• Exported macros | ||
• Exported functions | ||
• Exported generic functions | ||
• Exported conditions | ||
• Exported classes |
Next: Exported macros, Previous: Exported definitions, Up: Exported definitions [Contents][Index]
The directory all resources with relative paths are based from. This is intended to be bound by a @c(let) by specific input formats.
file.lisp (file)
Next: Exported functions, Previous: Exported special variables, Up: Exported definitions [Contents][Index]
Define a CommonDoc node.
define.lisp (file)
Iterate over the keys and values of a node’s metadata.
metadata.lisp (file)
Execute @cl:param(body) in each @cl:param(node) of the document.
traverse.lisp (file)
Next: Exported generic functions, Previous: Exported macros, Up: Exported definitions [Contents][Index]
Take a pathname or namestring. If it’s absolute, return it, otherwise, merge it with @c(*base-directory*).
file.lisp (file)
Return all the text from a node or document.
text.lisp (file)
Return a list of external links in the document.
links.lisp (file)
Return a list of figures in the document.
figures.lisp (file)
Return a list of images in the document.
figures.lisp (file)
Return a list of tables in the document.
tables.lisp (file)
Write the tree structure of the document tree to a stream.
print.lisp (file)
Write the tree structure of the document tree to a string.
print.lisp (file)
Recur through a document, giving unique reference IDs to each section.
unique-ref.lisp (file)
Find a node class by its tag name.
define.lisp (file)
Return a node class’ special slots.
define.lisp (file)
Return a node class’ tag name.
define.lisp (file)
Find the value corresponding to @cl:param(key) in the node’s metadata. If not found, return @c(NIL).
metadata.lisp (file)
(setf get-meta) (function)
metadata.lisp (file)
get-meta (function)
Create a block quote node from its children.
constructors.lisp (file)
Create a bold node from its children.
constructors.lisp (file)
Create a cell from its children.
constructors.lisp (file)
Create an inline code node from its children.
constructors.lisp (file)
Create a code block node from its children and language.
constructors.lisp (file)
Create a content node from its children.
constructors.lisp (file)
Create a definition list item.
constructors.lisp (file)
Create a definition list.
constructors.lisp (file)
Create a document.
constructors.lisp (file)
Create a document link from document and node references and its children.
constructors.lisp (file)
Create a figure.
constructors.lisp (file)
Create an image.
constructors.lisp (file)
Create an inline quote node from its children.
constructors.lisp (file)
Create an italicized node from its children.
constructors.lisp (file)
Create a list item.
constructors.lisp (file)
Create a metadata table from a list of pairs. If the list is empty, return an empty metadata table.
metadata.lisp (file)
Create an ordered list.
constructors.lisp (file)
Create a paragraph node from its children.
constructors.lisp (file)
Create a row from a list of cells.
constructors.lisp (file)
Create a section from its title and children.
constructors.lisp (file)
Create an striked out node from its children.
constructors.lisp (file)
Create a subscripted node from its children.
constructors.lisp (file)
Create a superscripted node from its children.
constructors.lisp (file)
Create a table from a list of rows.
constructors.lisp (file)
Create a text node from the contents of a string.
constructors.lisp (file)
Create an underlined node from its children.
constructors.lisp (file)
Create an unordered list.
constructors.lisp (file)
Create a web link.
constructors.lisp (file)
If a pathname is inside @c(*base-directory*), return a relative pathname. Otherwise, return the pathname unchanged.
file.lisp (file)
Take a string, usually the name of a section, and create something that is more similar to an identifier, i.e. no spaces, same case, etc.
util.lisp (file)
Extract a tree of document links representing the table of contents of a document. All the sections in the document must have references, so you should call fill-unique-refs first.
toc.lisp (file)
Next: Exported conditions, Previous: Exported functions, Up: Exported definitions [Contents][Index]
The cells in the row.
classes.lisp (file)
The document’s children nodes.
classes.lisp (file)
The list of @c(definition) instances.
classes.lisp (file)
The list of @c(list-item) instances.
classes.lisp (file)
The list of @c(list-item) instances.
classes.lisp (file)
The node’s children.
classes.lisp (file)
The date and time when the document was
created. By default, this is the date and time at instance
creation.
classes.lisp (file)
The creator of the document.
classes.lisp (file)
Defines the term.
classes.lisp (file)
A description of the document.
classes.lisp (file)
A description of the image.
classes.lisp (file)
A plain text description of the image.
classes.lisp (file)
A reference ID for the linked document.
If @c(NIL), the link is only to a section within the document.
classes.lisp (file)
Dump a CommonDoc document into a stream.
format.lisp (file)
format.lisp (file)
format.lisp (file)
Replace a macro node with a primitive node.
macros.lisp (file)
Define the metadata macro, and return an empty text node.
The default macroexpansion: Do nothing.
Recursively expand all macros in ‘node‘.
macros.lisp (file)
Expand the macros in a document.
Expand the macros in a node with children.
Expand the macros in a definition.
Expand the macros in a base list.
The default macroexpansion.
The row footer.
classes.lisp (file)
The row header.
classes.lisp (file)
The figure’s image.
classes.lisp (file)
A list of strings, each being a keyword for the document.
classes.lisp (file)
An @link[uri=http://www.ietf.org/rfc/rfc4646.txt](RFC4646) string denoting the language the document is written in.
classes.lisp (file)
The language of the code block’s contents.
classes.lisp (file)
Node metadata.
classes.lisp (file)
The name of the macro.
macros.lisp (file)
error.lisp (file)
Recursively check whether two nodes are equal.
equality.lisp (file)
A reference ID for the linked node.
classes.lisp (file)
Use this method to make node equality more specific.
equality.lisp (file)
By default, return true.
Parse an input into a CommonDoc document.
format.lisp (file)
The document’s publisher.
classes.lisp (file)
A reference string to uniquely identify the document within a certain context.
classes.lisp (file)
A unique string identifying the node.
classes.lisp (file)
Information on the document’s copyright.
classes.lisp (file)
The list of rows in a table.
classes.lisp (file)
The source where the image is stored.
classes.lisp (file)
The subject the document deals with.
classes.lisp (file)
The definition term.
classes.lisp (file)
The node’s text.
classes.lisp (file)
The document’s title.
classes.lisp (file)
The section title.
classes.lisp (file)
Apply a side-effectful function recursively to every element
in the document. Depth-first. Doesn’t apply the function to the document
itself.
traverse.lisp (file)
The URI of the external resource.
classes.lisp (file)
The document version.
classes.lisp (file)
Next: Exported classes, Previous: Exported generic functions, Up: Exported definitions [Contents][Index]
The base class of all CommonDoc errors.
error.lisp (file)
simple-error (condition)
macro-error (condition)
The base class of all macro-related errors.
error.lisp (file)
common-doc-error (condition)
no-macro-expander (condition)
Signaled when a macro node has no @c(expand-macro) method.
error.lisp (file)
macro-error (condition)
The node that couldn’t be expanded.
:node
node (generic function)
(setf node) (generic function)
Previous: Exported conditions, Up: Exported definitions [Contents][Index]
The base class of all lists.
classes.lisp (file)
document-node (class)
The base class of all quotes.
classes.lisp (file)
content-node (class)
A block quote.
classes.lisp (file)
base-quote (class)
Text in this element is bold.
classes.lisp (file)
markup (class)
A cell in a table.
classes.lisp (file)
content-node (class)
Text in this element is monospaced or otherwise marked as code or computer output.
classes.lisp (file)
markup (class)
A block of code.
classes.lisp (file)
content-node (class)
The language of the code block’s contents.
(or null string)
:language
language (generic function)
(setf language) (generic function)
A node with children. This is the base class of all nodes
that have a @c(children) slot (Except @c(document), since this class inherits
from @c(document-node)) and can also be used as a way to represent a generic
grouping of elements. This is useful when building a CommonDoc document by
parsing some input language.
classes.lisp (file)
document-node (class)
The node’s children.
(trivial-types:proper-list common-doc:document-node)
:children
children (generic function)
(setf children) (generic function)
A metadata macro.
macros.lisp (file)
macro-node (class)
The macro’s name.
string
:name
meta-macro-name (generic function)
An item in a definition list.
classes.lisp (file)
document-node (class)
The definition term.
(trivial-types:proper-list common-doc:document-node)
:term
term (generic function)
(setf term) (generic function)
Defines the term.
(trivial-types:proper-list common-doc:document-node)
:definition
definition (generic function)
(setf definition) (generic function)
A list of definitions.
classes.lisp (file)
base-list (class)
The list of @c(definition) instances.
(trivial-types:proper-list common-doc:definition)
:children
children (generic function)
(setf children) (generic function)
A document.
Metadata is mostly based on
@link[uri=https://en.wikipedia.org/wiki/Dublin_Core](Dublin Core) and the
@link[uri=https://en.wikipedia.org/wiki/OpenDocument_technical_specification#Metadata](OpenDocument)
format.
classes.lisp (file)
standard-object (class)
The document’s children nodes.
(trivial-types:proper-list common-doc:document-node)
:children
children (generic function)
(setf children) (generic function)
The document’s title.
string
:title
title (generic function)
(setf title) (generic function)
The creator of the document.
string
:creator
creator (generic function)
(setf creator) (generic function)
The document’s publisher.
string
:publisher
publisher (generic function)
(setf publisher) (generic function)
The subject the document deals with.
string
:subject
subject (generic function)
(setf subject) (generic function)
A description of the document.
string
:description
description (generic function)
(setf description) (generic function)
A list of strings, each being a keyword for the document.
(trivial-types:proper-list string)
:keywords
keywords (generic function)
(setf keywords) (generic function)
A reference string to uniquely identify the document within a certain context.
string
:reference
reference (generic function)
(setf reference) (generic function)
An @link[uri=http://www.ietf.org/rfc/rfc4646.txt](RFC4646) string denoting the language the document is written in.
string
:language
language (generic function)
(setf language) (generic function)
Information on the document’s copyright.
string
:rights
rights (generic function)
(setf rights) (generic function)
The document version.
string
:version
version (generic function)
(setf version) (generic function)
The date and time when the document was
created. By default, this is the date and time at instance
creation.
local-time:timestamp
:created-on
(local-time:now)
created-on (generic function)
(setf created-on) (generic function)
A data format that can be parsed into a CommonDoc document, or that a document can be formatted to.
format.lisp (file)
standard-object (class)
A link to a section of this document, to another document and
optionally a section within that document. See also the @c(reference) slot in
the @c(document) class.
classes.lisp (file)
link (class)
A reference ID for the linked document.
If @c(NIL), the link is only to a section within the document.
(or null string)
:document-reference
document-reference (generic function)
(setf document-reference) (generic function)
A reference ID for the linked node.
(or null string)
:node-reference
node-reference (generic function)
(setf node-reference) (generic function)
The base class of all document classes.
classes.lisp (file)
standard-object (class)
Node metadata.
(or null hash-table)
:metadata
metadata (generic function)
(setf metadata) (generic function)
A unique string identifying the node.
(or null string)
:reference
reference (generic function)
(setf reference) (generic function)
A figure, an image plus an annotation.
classes.lisp (file)
document-node (class)
The figure’s image.
common-doc:image
:image
image (generic function)
(setf image) (generic function)
A description of the image.
(trivial-types:proper-list common-doc:document-node)
:description
description (generic function)
(setf description) (generic function)
An image.
classes.lisp (file)
document-node (class)
The source where the image is stored.
string
:source
source (generic function)
(setf source) (generic function)
A plain text description of the image.
(or null string)
:description
description (generic function)
(setf description) (generic function)
A quote that occurs inside a paragraph in the document.
classes.lisp (file)
base-quote (class)
Text in this element is italicized.
classes.lisp (file)
markup (class)
The base class for all links, internal and external.
classes.lisp (file)
content-node (class)
The item in a non-definition list.
classes.lisp (file)
content-node (class)
A macro to be expanded.
macros.lisp (file)
content-node (class)
define-meta-macro (class)
The name of the macro.
string
:name
name (generic function)
(setf name) (generic function)
The superclass of all inline markup elements.
classes.lisp (file)
content-node (class)
A list where the elements are ordered.
classes.lisp (file)
base-list (class)
The list of @c(list-item) instances.
(trivial-types:proper-list common-doc:list-item)
:children
children (generic function)
(setf children) (generic function)
A paragraph.
classes.lisp (file)
content-node (class)
A row in a table.
classes.lisp (file)
document-node (class)
The row header.
(trivial-types:proper-list common-doc:document-node)
:header
header (generic function)
(setf header) (generic function)
The row footer.
(trivial-types:proper-list common-doc:document-node)
:footer
footer (generic function)
(setf footer) (generic function)
The cells in the row.
(trivial-types:proper-list common-doc:cell)
:cells
cells (generic function)
(setf cells) (generic function)
Represents a section in the document. Unlike HTML, where a
section is just another element, sections in CommonDoc contain their contents.
classes.lisp (file)
content-node (class)
The section title.
(trivial-types:proper-list common-doc:document-node)
:title
title (generic function)
(setf title) (generic function)
Text in this element is striked out.
classes.lisp (file)
markup (class)
Text in this element is subscripted relative to containing elements.
classes.lisp (file)
markup (class)
Text in this element is superscripted relative to containing elements.
classes.lisp (file)
markup (class)
A table.
classes.lisp (file)
document-node (class)
The list of rows in a table.
(trivial-types:proper-list common-doc:row)
:rows
rows (generic function)
(setf rows) (generic function)
A node representing a bare string of text.
classes.lisp (file)
document-node (class)
The node’s text.
string
:text
text (generic function)
(setf text) (generic function)
Text in this element is underlined.
classes.lisp (file)
markup (class)
A list where the elements are unordered.
classes.lisp (file)
base-list (class)
The list of @c(list-item) instances.
(trivial-types:proper-list common-doc:list-item)
:children
children (generic function)
(setf children) (generic function)
An external link.
classes.lisp (file)
link (class)
The URI of the external resource.
quri.uri:uri
:uri
uri (generic function)
(setf uri) (generic function)
Previous: Exported definitions, Up: Definitions [Contents][Index]
• Internal special variables | ||
• Internal functions | ||
• Internal generic functions |
Next: Internal functions, Previous: Internal definitions, Up: Internal definitions [Contents][Index]
A hash table of metadata macros to their definition.
macros.lisp (file)
define.lisp (file)
A hash table from tag names to node classes.
define.lisp (file)
Next: Internal generic functions, Previous: Internal special variables, Up: Internal definitions [Contents][Index]
macros.lisp (file)
Instantiate a class with children and metadata.
constructors.lisp (file)
toc.lisp (file)
Remove all nodes deeper than max-depth.
toc.lisp (file)
Check whether two hash tables are equal.
equality.lisp (file)
Check whether two hash tables have the same keys.
equality.lisp (file)
equality.lisp (file)
Remove unnecessary nesting, ie: (((A))) => (A).
toc.lisp (file)
Previous: Internal functions, Up: Internal definitions [Contents][Index]
The macro’s name.
macros.lisp (file)
Recursively check for equality in the children of a node.
equality.lisp (file)
Check whether two nodes have the same metadata.
equality.lisp (file)
Extract a string with all the text inside a node.
text.lisp (file)
Extract text from a document.
Extract text from a section.
Extract text from a table.
Extract text from a row of cells.
Extract the description from a figure.
Extract the description from an image.
Extract text from a definition.
Extract text from a text node.
Extract text from a list of nodes.
Extract text from a content node.
Extract text from a content node.
A function that traverses a document tree looking for section nodes.
toc.lisp (file)
Previous: Definitions, Up: Top [Contents][Index]
• Concept index | ||
• Function index | ||
• Variable index | ||
• Data type index |
Next: Function index, Previous: Indexes, Up: Indexes [Contents][Index]
Jump to: | C F L M |
---|
Jump to: | C F L M |
---|
Next: Variable index, Previous: Concept index, Up: Indexes [Contents][Index]
Jump to: | %
(
A C D E F G H I K L M N P R S T U V W |
---|
Jump to: | %
(
A C D E F G H I K L M N P R S T U V W |
---|
Next: Data type index, Previous: Function index, Up: Indexes [Contents][Index]
Jump to: | *
C D F H I K L M N P R S T U V |
---|
Jump to: | *
C D F H I K L M N P R S T U V |
---|
Previous: Variable index, Up: Indexes [Contents][Index]
Jump to: | B C D F I L M N O P R S T U W |
---|
Jump to: | B C D F I L M N O P R S T U W |
---|