~ubuntu-branches/ubuntu/trusty/mtbl/trusty-proposed

« back to all changes in this revision

Viewing changes to man/mtbl.7

  • Committer: Package Import Robot
  • Author(s): Robert S. Edmonds
  • Date: 2014-02-03 13:49:21 UTC
  • mfrom: (1.1.3)
  • Revision ID: package-import@ubuntu.com-20140203134921-qx8q4ehadtih5rkd
Tags: 0.5-1
* New upstream release.
  - Fix detection of big endian architectures. (Closes: #737123).
  - Avoid crashing when the MTBL file is too small to include the complete
    MTBL trailer. (Closes: #716628).
* Use the pre-built manpage documentation rather than re-building the
  documentation at package build time. This avoids including potentially
  architecture dependent content in /usr/share in the -dev package when
  packages are built on different architectures on different days, due to
  the inclusion of today's date in the built man pages. (Closes: #736340).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
'\" t
 
2
.\"     Title: mtbl
 
3
.\"    Author: [FIXME: author] [see http://docbook.sf.net/el/author]
 
4
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
 
5
.\"      Date: 01/31/2014
 
6
.\"    Manual: \ \&
 
7
.\"    Source: \ \&
 
8
.\"  Language: English
 
9
.\"
 
10
.TH "MTBL" "7" "01/31/2014" "\ \&" "\ \&"
 
11
.\" -----------------------------------------------------------------
 
12
.\" * Define some portability stuff
 
13
.\" -----------------------------------------------------------------
 
14
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
15
.\" http://bugs.debian.org/507673
 
16
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
 
17
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
18
.ie \n(.g .ds Aq \(aq
 
19
.el       .ds Aq '
 
20
.\" -----------------------------------------------------------------
 
21
.\" * set default formatting
 
22
.\" -----------------------------------------------------------------
 
23
.\" disable hyphenation
 
24
.nh
 
25
.\" disable justification (adjust text to left margin only)
 
26
.ad l
 
27
.\" -----------------------------------------------------------------
 
28
.\" * MAIN CONTENT STARTS HERE *
 
29
.\" -----------------------------------------------------------------
 
30
.SH "NAME"
 
31
mtbl \- immutable sorted string library
 
32
.SH "SYNOPSIS"
 
33
.sp
 
34
\fB#include <mtbl\&.h>\fR
 
35
.sp
 
36
\fBgcc [\fR\fB\fIflags\fR\fR\fB] \fR\fB\fIfiles\fR\fR\fB \-lmtbl [\fR\fB\fIlibraries\fR\fR\fB]\fR
 
37
.SH "DESCRIPTION"
 
38
.sp
 
39
The mtbl library provides interfaces for creating, searching, and merging Sorted String Table (SSTable) files in the \fIMTBL\fR format, which provide an immutable mapping of keys to values\&. Sorted String Tables are compact and provide fast random access to keys and key ranges\&. Keys and values are arbitrary byte arrays, and MTBL SSTables may not contain duplicate keys\&.
 
40
.sp
 
41
The six main interfaces provided by the mtbl library are:
 
42
.PP
 
43
\fBmtbl_iter\fR(3)
 
44
.RS 4
 
45
Iterator objects provide a consistent interface for iterating over the key\-value entries returned by other interfaces\&.
 
46
.RE
 
47
.PP
 
48
\fBmtbl_source\fR(3)
 
49
.RS 4
 
50
Source objects provide functions for obtaining iterators from an underlying data source\&. The
 
51
\fBmtbl_reader\fR
 
52
and
 
53
\fBmtbl_merger\fR
 
54
interfaces provide functions for obtaining references to a source object\&. The source methods return an
 
55
\fBmtbl_iter\fR
 
56
object\&.
 
57
.RE
 
58
.PP
 
59
\fBmtbl_reader\fR(3)
 
60
.RS 4
 
61
Reader objects provide read\-only access to
 
62
\fIMTBL\fR
 
63
files\&.
 
64
.RE
 
65
.PP
 
66
\fBmtbl_writer\fR(3)
 
67
.RS 4
 
68
Writer objects initialize a new
 
69
\fIMTBL\fR
 
70
file from a sequence of key\-value entries provided by the caller\&. Keys must be in sorted order based on lexicographical byte value, and keys may not be duplicated\&.
 
71
.RE
 
72
.PP
 
73
\fBmtbl_merger\fR(3)
 
74
.RS 4
 
75
Merger objects receive multiple sequences of key\-value entries from one or more
 
76
\fBmtbl_source\fR
 
77
objects and combine them into a single, sorted sequence\&. The combined, merged output sequence is provided via the
 
78
\fBmtbl_source\fR
 
79
interface\&.
 
80
.RE
 
81
.PP
 
82
\fBmtbl_sorter\fR(3)
 
83
.RS 4
 
84
Sorter objects receive a sequence of key\-value entries provided by the caller and return them in sorted order\&. The caller must provide a callback function to merge values in the case of entries with duplicate keys\&. The sorted output sequence may be retrieved via the
 
85
\fBmtbl_iter\fR
 
86
interface or be dumped to an
 
87
\fBmtbl_writer\fR
 
88
object\&.
 
89
.RE
 
90
.PP
 
91
\fBmtbl_fileset\fR(3)
 
92
.RS 4
 
93
Fileset objects automatically maintain an
 
94
\fBmtbl_source\fR
 
95
built on top of the
 
96
\fBmtbl_merger\fR
 
97
and
 
98
\fBmtbl_reader\fR
 
99
interfaces\&. The set of underlying
 
100
\fBmtbl_reader\fR
 
101
objects is kept synchronized with a "setfile" on disk listing
 
102
\fIMTBL\fR
 
103
files\&.
 
104
.RE
 
105
.sp
 
106
Additionally, several utility interfaces are provided:
 
107
.PP
 
108
\fBmtbl_crc32c\fR(3)
 
109
.RS 4
 
110
Calculates the CRC32C checksum of a byte array\&.
 
111
.RE
 
112
.PP
 
113
\fBmtbl_fixed\fR(3)
 
114
.RS 4
 
115
Functions for fixed\-width encoding and decoding of 32 and 64 bit integers\&.
 
116
.RE
 
117
.PP
 
118
\fBmtbl_varint\fR(3)
 
119
.RS 4
 
120
Functions for varint encoding and decoding of 32 and 64 bit integers\&.
 
121
.RE