~ubuntu-branches/ubuntu/trusty/systemd/trusty

« back to all changes in this revision

Viewing changes to man/sd_journal_get_catalog.3

Tags: upstream-202
ImportĀ upstreamĀ versionĀ 202

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
'\" t
2
 
.\"     Title: sd_journal_get_catalog
3
 
.\"    Author: Lennart Poettering <lennart@poettering.net>
4
 
.\" Generator: DocBook XSL Stylesheets v1.77.1 <http://docbook.sf.net/>
5
 
.\"      Date: 03/07/2013
6
 
.\"    Manual: sd_journal_get_catalog
7
 
.\"    Source: systemd
8
 
.\"  Language: English
9
 
.\"
10
 
.TH "SD_JOURNAL_GET_CATAL" "3" "" "systemd" "sd_journal_get_catalog"
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
 
sd_journal_get_catalog, sd_journal_get_catalog_for_message_id \- Retrieve message catalog entry
32
 
.SH "SYNOPSIS"
33
 
.sp
34
 
.ft B
35
 
.nf
36
 
#include <systemd/sd\-journal\&.h>
37
 
.fi
38
 
.ft
39
 
.HP \w'int\ sd_journal_get_catalog('u
40
 
.BI "int sd_journal_get_catalog(sd_journal*\ " "j" ", const\ char**\ " "ret" ");"
41
 
.HP \w'int\ sd_journal_get_catalog_for_message_id('u
42
 
.BI "int sd_journal_get_catalog_for_message_id(sd_id128_t\ " "id" ", const\ char**\ " "ret" ");"
43
 
.SH "DESCRIPTION"
44
 
.PP
45
 
\fBsd_journal_get_catalog()\fR
46
 
retrieves a message catalog entry for the current journal entry\&. This will look up an entry in the message catalog by using the
47
 
MESSAGE_ID=
48
 
field of the current journal entry\&. Before returning the entry all journal field names in the catalog entry text enclosed in "@" will be replaced by the respective field values of the current entry\&. If a field name referenced in the message catalog entry does not exist it the current journal entry the "@" will be removed but the field name otherwise left untouched\&.
49
 
.PP
50
 
\fBsd_journal_get_catalog_for_message_id()\fR
51
 
works similar to
52
 
\fBsd_journal_get_catalog()\fR
53
 
but the entry is looked up by the specified message ID (no open journal context is necessary for this), and no field substitution is done\&.
54
 
.PP
55
 
For more information about the journal message catalog please refer to the
56
 
\m[blue]\fBJournal Message Catalogs\fR\m[]\&\s-2\u[1]\d\s+2
57
 
documentation page\&.
58
 
.SH "RETURN VALUE"
59
 
.PP
60
 
\fBsd_journal_get_catalog()\fR
61
 
and
62
 
\fBsd_journal_get_catalog_for_message_id()\fR
63
 
return 0 on success or a negative errno\-style error code\&. If no matching message catalog entry is found \-ENOENT is returned\&.
64
 
.SH "NOTES"
65
 
.PP
66
 
The
67
 
\fBsd_journal_get_catalog()\fR
68
 
and
69
 
\fBsd_journal_get_catalog_for_message_id()\fR
70
 
interfaces are available as shared library, which can be compiled and linked to with the
71
 
libsystemd\-journal
72
 
\fBpkg-config\fR(1)
73
 
file\&.
74
 
.SH "SEE ALSO"
75
 
.PP
76
 
 
77
 
\fBsystemd\fR(1),
78
 
\fBsystemd.journal-fields\fR(7),
79
 
\fBsd-journal\fR(3),
80
 
\fBsd_journal_open\fR(3),
81
 
\fBsd_journal_next\fR(3),
82
 
\fBsd_journal_get_data\fR(3)
83
 
.SH "NOTES"
84
 
.IP " 1." 4
85
 
Journal Message Catalogs
86
 
.RS 4
87
 
\%http://www.freedesktop.org/wiki/Software/systemd/catalog
88
 
.RE