This is the cl-kyoto-cabinet Reference Manual, version 0.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 05:04:44 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
cl-kyoto-cabinet
Lisp Interface to Kyoto Cabinet DBM (http://fallabs.com/kyotocabinet/)
Kevin Raison <last name @ chatsubo dot net>
New BSD
0.1
cffi
(system)., at least version "0.10.3"
cl-kyoto-cabinet-package.lisp
(file).
kyoto-cabinet-ffi.lisp
(file).
kyoto-cabinet.lisp
(file).
kyoto-cabinet-dbm.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
cl-kyoto-cabinet/cl-kyoto-cabinet.asd
cl-kyoto-cabinet/cl-kyoto-cabinet-package.lisp
cl-kyoto-cabinet/kyoto-cabinet-ffi.lisp
cl-kyoto-cabinet/kyoto-cabinet.lisp
cl-kyoto-cabinet/kyoto-cabinet-dbm.lisp
cl-kyoto-cabinet/cl-kyoto-cabinet.asd
cl-kyoto-cabinet
(system).
cl-kyoto-cabinet/cl-kyoto-cabinet-package.lisp
cl-kyoto-cabinet
(system).
cl-kyoto-cabinet/kyoto-cabinet-ffi.lisp
cl-kyoto-cabinet-package.lisp
(file).
cl-kyoto-cabinet
(system).
kccurdb
(function).
kccurdel
(function).
kccurget
(function).
kccurgetkey
(function).
kccurgetvalue
(function).
kccurjump
(function).
kccurjumpkey
(function).
kccurremove
(function).
kccurstep
(function).
kcdbadd
(function).
kcdbappend
(function).
kcdbbegintran
(function).
kcdbclear
(function).
kcdbclose
(function).
kcdbcount
(function).
kcdbcursor
(function).
kcdbdel
(function).
kcdbecode
(function).
kcdbemsg
(function).
kcdbendtran
(function).
kcdbget
(function).
kcdbnew
(function).
kcdbopen
(function).
kcdbremove
(function).
kcdbset
(function).
kcfree
(function).
kcmalloc
(function).
%var-accessor-kcversion
(function).
(setf %var-accessor-kcversion)
(function).
%var-accessor-kcvisnop
(function).
(setf %var-accessor-kcvisnop)
(function).
%var-accessor-kcvisremove
(function).
(setf %var-accessor-kcvisremove)
(function).
defanonenum
(macro).
kcatof
(function).
kcatoi
(function).
kcatoix
(function).
kcchkinf
(function).
kcchknan
(function).
kccuraccept
(function).
kccurecode
(function).
kccuremsg
(function).
kccursetvalue
(function).
kcdbaccept
(function).
kcdbbegintrantry
(function).
kcdbcas
(function).
kcdbcopy
(function).
kcdbdumpsnap
(function).
kcdbgetbuf
(function).
kcdbincrdouble
(function).
kcdbincrint
(function).
kcdbiterate
(function).
kcdbloadsnap
(function).
kcdbpath
(function).
kcdbsize
(function).
kcdbstatus
(function).
kcdbsync
(function).
kcecodename
(function).
kchashfnv
(function).
kchashmurmur
(function).
kcinf
(function).
kcnan
(function).
kctime
(function).
kcversion
(symbol macro).
kcvisnop
(symbol macro).
kcvisremove
(symbol macro).
swig-lispify
(function).
cl-kyoto-cabinet/kyoto-cabinet.lisp
cl-kyoto-cabinet-package.lisp
(file).
kyoto-cabinet-ffi.lisp
(file).
cl-kyoto-cabinet
(system).
*in-transaction-p*
(special variable).
dbm-begin
(generic function).
dbm-cache
(generic function).
dbm-clear
(generic function).
dbm-close
(generic function).
dbm-commit
(generic function).
dbm-delete
(generic function).
dbm-file-size
(generic function).
dbm-get
(generic function).
dbm-num-records
(generic function).
dbm-open
(generic function).
dbm-optimize
(generic function).
dbm-put
(generic function).
dbm-remove
(generic function).
dbm-rollback
(generic function).
dbm-xmsize
(generic function).
iter-close
(generic function).
iter-first
(generic function).
iter-go-to
(generic function).
iter-item
(generic function).
iter-key
(generic function).
iter-last
(generic function).
iter-next
(generic function).
iter-open
(generic function).
iter-prev
(generic function).
iter-put
(generic function).
iter-remove
(generic function).
iter-value
(generic function).
kc-dbm
(class).
set-comparator
(generic function).
with-database
(macro).
with-iterator
(macro).
with-transaction
(macro).
check-open-mode
(function).
convert-from-lisp
(generic function).
convert-to-lisp
(generic function).
copy-foreign-value
(function).
dbm-error
(condition).
dbm-file-namestring
(generic function).
error-code-of
(reader method).
error-msg-of
(reader method).
get-int32->octets
(function).
get-int32->string
(function).
get-octets->octets
(function).
get-octets->string
(function).
get-pointer
(function).
get-pointer->pointer
(function).
get-something
(function).
get-string->octets
(function).
get-string->string
(function).
int32
(type).
int64
(type).
iter-iterate
(generic function).
kc-iterator
(class).
make-octet-vector
(function).
maybe-raise-error
(generic function).
octet
(type).
ptr-of
(reader method).
ptr-of
(reader method).
(setf ptr-of)
(writer method).
(setf ptr-of)
(writer method).
put-int32->octets
(function).
put-int32->string
(function).
put-method-for
(generic function).
put-octets->octets
(function).
put-pointer->pointer
(function).
put-string->octets
(function).
put-string->string
(function).
raise-error
(generic function).
rem-int32->value
(function).
rem-octets->value
(function).
rem-pointer->value
(function).
rem-string->value
(function).
text
(reader method).
with-string-value
(macro).
cl-kyoto-cabinet/kyoto-cabinet-dbm.lisp
cl-kyoto-cabinet-package.lisp
(file).
kyoto-cabinet.lisp
(file).
kyoto-cabinet-ffi.lisp
(file).
cl-kyoto-cabinet
(system).
dbm-begin
(method).
dbm-clear
(method).
dbm-close
(method).
dbm-commit
(method).
dbm-delete
(method).
dbm-get
(method).
dbm-get
(method).
dbm-get
(method).
dbm-get-fast
(function).
dbm-num-records
(method).
dbm-open
(method).
dbm-put
(method).
dbm-put
(method).
dbm-put
(method).
dbm-put
(method).
dbm-put
(method).
dbm-put-fast
(function).
dbm-remove
(method).
dbm-remove
(method).
dbm-remove
(method).
dbm-remove-fast
(function).
dbm-rollback
(method).
initialize-instance
(method).
initialize-instance
(method).
iter-close
(method).
iter-first
(method).
iter-go-to
(method).
iter-go-to
(method).
iter-go-to
(method).
iter-go-to-fast
(method).
iter-item
(method).
iter-item-fast
(method).
iter-key
(method).
iter-key-fast
(method).
iter-next
(method).
iter-open
(method).
iter-remove
(method).
iter-value
(method).
iter-value-fast
(method).
maybe-raise-error
(method).
maybe-raise-error
(method).
maybe-raise-error-with-ecode
(function).
raise-error
(method).
raise-error
(method).
Packages are listed by definition order.
kyoto-cabinet-ffi
CFFI interface to Kyoto Cabinet functions. The original C function names are preserved.
cffi
.
common-lisp
.
kccurdb
(function).
kccurdel
(function).
kccurget
(function).
kccurgetkey
(function).
kccurgetvalue
(function).
kccurjump
(function).
kccurjumpkey
(function).
kccurremove
(function).
kccurstep
(function).
kcdbadd
(function).
kcdbappend
(function).
kcdbbegintran
(function).
kcdbclear
(function).
kcdbclose
(function).
kcdbcount
(function).
kcdbcursor
(function).
kcdbdel
(function).
kcdbecode
(function).
kcdbemsg
(function).
kcdbendtran
(function).
kcdbget
(function).
kcdbnew
(function).
kcdbopen
(function).
kcdbremove
(function).
kcdbset
(function).
kcfree
(function).
kcmalloc
(function).
%var-accessor-kcversion
(function).
(setf %var-accessor-kcversion)
(function).
%var-accessor-kcvisnop
(function).
(setf %var-accessor-kcvisnop)
(function).
%var-accessor-kcvisremove
(function).
(setf %var-accessor-kcvisremove)
(function).
defanonenum
(macro).
kcatof
(function).
kcatoi
(function).
kcatoix
(function).
kcchkinf
(function).
kcchknan
(function).
kccuraccept
(function).
kccurecode
(function).
kccuremsg
(function).
kccursetvalue
(function).
kcdbaccept
(function).
kcdbbegintrantry
(function).
kcdbcas
(function).
kcdbcopy
(function).
kcdbdumpsnap
(function).
kcdbgetbuf
(function).
kcdbincrdouble
(function).
kcdbincrint
(function).
kcdbiterate
(function).
kcdbloadsnap
(function).
kcdbpath
(function).
kcdbsize
(function).
kcdbstatus
(function).
kcdbsync
(function).
kcecodename
(function).
kchashfnv
(function).
kchashmurmur
(function).
kcinf
(function).
kcnan
(function).
kctime
(function).
kcversion
(symbol macro).
kcvisnop
(symbol macro).
kcvisremove
(symbol macro).
swig-lispify
(function).
kyoto-cabinet
A Lisp-style abstract interface to Kyoto
Cabinet. The original C function names are not preserved (see
the :kyoto-cabinet-ffi package for functions that do preserve the
nomenclature).
kc
cffi
.
common-lisp
.
kyoto-cabinet-ffi
.
*in-transaction-p*
(special variable).
dbm-begin
(generic function).
dbm-cache
(generic function).
dbm-clear
(generic function).
dbm-close
(generic function).
dbm-commit
(generic function).
dbm-delete
(generic function).
dbm-file-size
(generic function).
dbm-get
(generic function).
dbm-get-fast
(function).
dbm-num-records
(generic function).
dbm-open
(generic function).
dbm-optimize
(generic function).
dbm-put
(generic function).
dbm-put-fast
(function).
dbm-remove
(generic function).
dbm-remove-fast
(function).
dbm-rollback
(generic function).
dbm-xmsize
(generic function).
iter-close
(generic function).
iter-first
(generic function).
iter-go-to
(generic function).
iter-go-to-fast
(generic function).
iter-item
(generic function).
iter-item-fast
(generic function).
iter-key
(generic function).
iter-key-fast
(generic function).
iter-last
(generic function).
iter-next
(generic function).
iter-open
(generic function).
iter-prev
(generic function).
iter-put
(generic function).
iter-remove
(generic function).
iter-value
(generic function).
iter-value-fast
(generic function).
kc-dbm
(class).
set-comparator
(generic function).
with-database
(macro).
with-iterator
(macro).
with-transaction
(macro).
check-open-mode
(function).
convert-from-lisp
(generic function).
convert-to-lisp
(generic function).
copy-foreign-value
(function).
dbm-error
(condition).
dbm-file-namestring
(generic function).
error-code-of
(generic reader).
error-msg-of
(generic reader).
get-int32->octets
(function).
get-int32->string
(function).
get-octets->octets
(function).
get-octets->string
(function).
get-pointer
(function).
get-pointer->pointer
(function).
get-something
(function).
get-string->octets
(function).
get-string->string
(function).
int32
(type).
int64
(type).
iter-iterate
(generic function).
kc-iterator
(class).
make-octet-vector
(function).
maybe-raise-error
(generic function).
maybe-raise-error-with-ecode
(function).
octet
(type).
ptr-of
(generic reader).
(setf ptr-of)
(generic writer).
put-int32->octets
(function).
put-int32->string
(function).
put-method-for
(generic function).
put-octets->octets
(function).
put-pointer->pointer
(function).
put-string->octets
(function).
put-string->string
(function).
raise-error
(generic function).
rem-int32->value
(function).
rem-octets->value
(function).
rem-pointer->value
(function).
rem-string->value
(function).
text
(generic reader).
with-string-value
(macro).
Definitions are sorted by export status, category, package, and then by lexicographic order.
Bound when in a transaction.
Evaluates BODY with VAR bound to an open database.
Arguments:
- var (symbol): The binding for the new database object.
- filespec (filespec): The database file.
- type (symbol): A symbol that names a TC database class.
Rest:
- mode (symbols): :READ :WRITE :CREATE :TRUNCATE
:NOLOCK :NOBLOCK and :TSYNC
See the TC documentation for the meaning of the mode arguments.
Evaluates BODY on with VAR bound to a new, open iterator on DB.
Evaluates BODY in the context of a transaction on DB. If no transaction is in progress, a new one is started. If a transaction is already in progress, BODY is evaluated in its context. If an error occurs, the transaction will rollback, otherwise it will commit.
Begins a transaction with DB.
Sets the caching parameters of DB. These are
described in the TC documentation.
The keyword arguments for B+ tree databases are:
- :LEAF : The number of leaf nodes to cache. Defaults to 1024.
- :NON-LEAF : The number of non-leaf nodes to cache. Defaults to 512.
The keyword arguments for hash databases are:
- :RECORDS : The number of records to cache. Defaults to 0.
Removes all records from DB.
Closes an open KC database.
Arguments:
- db (object): A KC dbm object.
Returns:
- T on success, or NIL otherwise.
Commits a transaction with DB.
Deletes a KC database. If open, implicitly closes
it first.
Arguments:
- db (object): A KC dbm object.
Returns:
- NIL .
Returns the size of the DB file in bytes.
Returns the value under KEY in DB. Type may be one
of :STRING or :OCTETS , depending on how the value is to be
treated. :STRING indicates that the value should be converted to a
Lisp string, while :OCTETS indicates that the byte vector should be
returned.
Returns the number of records in DB.
Opens a new, or existing KC database.
Arguments:
- db (object): A KC dbm object.
- filespec (string): A pathname designator for the database file.
Rest:
- mode (list symbol): A list of mode keywords used when opening the
file. The modes are :KCOWRITER :KCOREADER :KCOCREATE :KCOTRUNCATE
:KCOAUTOTRAN :KCOAUTOSYNC :KCONOLOCK :KCOTRYLOCK :KCONOREPAIR
which correspond to those described in the KC specification.
Returns:
- The KC dbm object, now open.
Sets the DB optimization parameters on an open
database. These are described in the TC documentation.
The keyword arguments for B+ tree databases are:
- :LEAF (fixnum) : Sets the number of leaf nodes.
- :NON-LEAF (fixnum) : Sets the number of non-leaf nodes.
- :BUCKET-SIZE (fixnum) : Sets the bucket
- :REC-ALIGN (fixnum) : A power of 2 indicating record alignment.
- :FREE-POOL (fixnum): A power of 2 indicating the size of the free
record pool.
- :OPTS (list symbol): A list of keywords indicating optional database
parameters.
The keyword arguments for hash databases are:
:BUCKET-SIZE :REC-ALIGN :FREE-POOL and :OPTS , as above.
In both cases the :OPTS value is a list of one or more of
- :LARGE : Use a 64-bit bucket array to allow datbases > 2Gb.
- :DEFLATE : Use deflate compression.
- :BZIP : Use bzip compression.
- :TCBS : Use tcbs compression.
- :DEFAULTS : Use the current settings.
For example:
;;; (dbm-optimize db :leaf 512 :non-leaf 256 :bucket-size 100000000 ;;; :rec-align 4 :free-pool 10 :opts ’(:large :deflate))
Inserts KEY and VALUE into DB. MODE varies with DB
class.
Arguments:
- db (object): A KC database object.
- key (object): A key under which to insert.
- value (object): A value to insert under key.
Key:
- :mode (symbol): A symbol designating one of the KC insertion modes:
replace, keep, concat, etc.
Valid modes for B+ tree databases are:
- :REPLACE : If a record with the same key exists in the database, it
is overwritten.
- :KEEP : If a record with the same key exists in the database, this
function has no effect.
- :CONCAT : Concatenates a value at the end of the existing record in
the database. If there is no corresponding record, a new record is
created.
Valid modes for hash databases are:
:REPLACE , :KEEP and :CONCAT , as above.
Removes the value under KEY in DB. If REMOVE-DUPS
is T, duplicate values will be removed from a B+ tree database.
Rolls back a transaction with DB.
Sets the DB extra mapped memory to SIZE bytes.
Closes ITERATOR. Only effective for B+ tree databases.
kc-iterator
)) ¶Moves ITERATOR to the first record and returns T,
or NIL if the database is empty. Only effective for B+ tree
databases.
kc-iterator
)) ¶Moves ITERATOR to the record at KEY. Only effective for B+ tree databases.
kc-iterator
) (key vector
)) ¶kc-iterator
) (key integer
)) ¶kc-iterator
) (key string
)) ¶kc-iterator
) key-ptr key-len) ¶Returns the current item in the iterator. ** DOES NOT advance the cursor **
kc-iterator
) &key key-type value-type) ¶kc-iterator
)) ¶Returns current key at the ITERATOR position. Type
may be one of :STRING or :OCTETS , depending on how the value is to be
treated. :STRING indicates that the value should be converted to a
Lisp string, while :OCTETS indicates that the byte vector should be
returned.
kc-iterator
) &optional type) ¶kc-iterator
) &optional type) ¶Moves ITERATOR to the last record and returns T, or
NIL if the database is empty. Only effective for B+ tree databases.
Moves ITERATOR to the next record and returns T, or NIL if already at the last record.
kc-iterator
)) ¶Opens an iterator on DB.
Arguments:
- db (object): A KC dbm object.
Returns:
- A TC iterator object.
Moves ITERATOR to the previous record and returns
T, or NIL if already at the first record. Only effective for B+ tree
databases.
Inserts VALUE around ITERATOR. Mode may be one
of :CURRENT , :BEFORE or :AFTER . Only effective for B+ tree
databases.
Removed the record at the ITERATOR position and advances ITERATOR, if possible. Only effective for B+ tree databases.
kc-iterator
)) ¶Returns the current value at ITERATOR. Type may be
one of :STRING or :OCTETS , depending on how the value is to be
treated. :STRING indicates that the value should be converted to a
Lisp string, while :OCTETS indicates that the byte vector should be
returned.
kc-iterator
) &optional type) ¶kc-iterator
) &optional type) ¶Sets the DB comparator function to that given by symbol FN.
kc-iterator
) &key) ¶Converts anonymous enums to defconstants.
Helper macro for managing string values.
Checks the list MODE for valid and consistent database opening arguments.
Returns a value from DB under KEY using FN where the key is a 32-bit integer and the value an octet vector.
Returns a value from DB under KEY using FN where the key is a 32-but integer and the value a string.
Returns a value from DB under KEY using FN where the key and value are octet vectors.
Returns a value from DB under KEY using FN where the key is a vector of octets and value is a string.
Returns a value from DB under KEY using FN where the key and value are cffi pointers.
Returns a value from DB under KEY using FN where the key is a string and the value an octet vector. Note that for the key we allocate a foreign string that is not null-terminated.
Returns a value from DB under KEY using FN where the key and value are strings.
Inserts VALUE into DB under KEY using FN where the key is a 32-bit integer and the value is an octet vector.
Inserts VALUE into DB under KEY using FN where the key is a 32-bit integer and the value is a string.
Inserts VALUE into DB under KEY using FN where the key and value are octet vectors.
Inserts VALUE into DB under KEY using FN where the key and value are cffi pointers.
Inserts VALUE into DB under KEY using FN where the key is a string and the value an octet vector. Note that for the key we allocate a foreign string that is not null-terminated.
Inserts VALUE into DB under KEY using FN where the key and value are strings.
Removes value from DB under KEY where the key is a 32-bit integer.
Removes value from DB under KEY where the key is a octet vector
Removes value from DB under KEY where the key is a cffi pointer
Removes value from DB under KEY where the key is a string.
Returns the name of the DB file.
Iterates through all records and calls function fn for each record.
Arguments:
- db (object): A KC dbm object.
- fn (function): A callback function
Returns:
- Boolean representing true for success or false for failure.
Checks the DB handle for any error reported by TC
and raises a {define-condition dbm-error} if one has occurred by
calling {defun raise-error} .
kc-iterator
) &optional message &rest message-arguments) ¶kc-iterator
)) ¶kc-iterator
)) ¶A KC pointer.
ptr
.
Raises a {define-condition dbm-error} with
MESSAGE. MESSAGE may be a format template, in which case the rest of
the arguments are taken to be format arguments for that template. The
error code and TC error message are automatically obtained from the DB
handle.
kc-iterator
) &optional message &rest message-arguments) ¶error
.
The error code provided by KC.
(quote nil)
:error-code
This slot is read-only.
The error message provided by KC.
(quote nil)
:error-msg
This slot is read-only.
A KC database iterator, the superclass of both B+ tree cursors and hash iterators.
A KC pointer.
:ptr
Jump to: | %
(
C D E F G I K M P R S T W |
---|
Jump to: | %
(
C D E F G I K M P R S T W |
---|
Jump to: | *
E K P S T |
---|
Jump to: | *
E K P S T |
---|
Jump to: | C D F I K O P S T |
---|
Jump to: | C D F I K O P S T |
---|