]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/sd_bus_message_append_strv.xml
tree-wide: drop license boilerplate
[thirdparty/systemd.git] / man / sd_bus_message_append_strv.xml
1 <?xml version='1.0'?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4
5 <!--
6 SPDX-License-Identifier: LGPL-2.1+
7
8 This file is part of systemd.
9
10 Copyright 2014 Zbigniew Jędrzejewski-Szmek
11 -->
12
13 <refentry id="sd_bus_message_append_strv"
14 xmlns:xi="http://www.w3.org/2001/XInclude">
15
16 <refentryinfo>
17 <title>sd_bus_message_append_strv</title>
18 <productname>systemd</productname>
19
20 <authorgroup>
21 <author>
22 <contrib>A monkey with a typewriter</contrib>
23 <firstname>Zbigniew</firstname>
24 <surname>Jędrzejewski-Szmek</surname>
25 <email>zbyszek@in.waw.pl</email>
26 </author>
27 </authorgroup>
28 </refentryinfo>
29
30 <refmeta>
31 <refentrytitle>sd_bus_message_append_strv</refentrytitle>
32 <manvolnum>3</manvolnum>
33 </refmeta>
34
35 <refnamediv>
36 <refname>sd_bus_message_append_strv</refname>
37
38 <refpurpose>Attach an array of strings to a message</refpurpose>
39 </refnamediv>
40
41 <refsynopsisdiv>
42 <funcsynopsis>
43 <funcsynopsisinfo>#include &lt;systemd/sd-bus.h&gt;</funcsynopsisinfo>
44
45 <funcprototype>
46 <funcdef>int sd_bus_message_append_strv</funcdef>
47 <paramdef>sd_bus_message *<parameter>m</parameter></paramdef>
48 <paramdef>char **<parameter>l</parameter></paramdef>
49 </funcprototype>
50 </funcsynopsis>
51 </refsynopsisdiv>
52
53 <refsect1>
54 <title>Description</title>
55
56 <para>The <function>sd_bus_message_append</function> function can be
57 used to append an array of strings to message
58 <parameter>m</parameter>. The parameter <parameter>l</parameter>
59 shall point to a <constant>NULL</constant>-terminated array of pointers
60 to <constant>NUL</constant>-terminated strings. Each string must
61 satisfy the same constraints as described for the
62 <literal>s</literal> type in
63 <citerefentry><refentrytitle>sd_bus_message_append_basic</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
64 </para>
65
66 <para>The memory pointed at by <parameter>p</parameter> and the
67 contents of the strings themselves are copied into the memory area
68 containing the message and may be changed after this call. Note
69 that the signature of <parameter>l</parameter> parameter is to be
70 treated as <type>const char *const *</type>, and the contents
71 will not be modified.</para>
72 </refsect1>
73
74 <refsect1>
75 <title>Return Value</title>
76
77 <para>On success, this call returns 0 or a positive integer. On
78 failure, a negative errno-style error code is returned.</para>
79 </refsect1>
80
81 <xi:include href="sd_bus_message_append_basic.xml" xpointer="errors" />
82
83 <refsect1>
84 <title>Notes</title>
85
86 <para>The <function>sd_bus_append_append_strv()</function> function
87 described here is available as a shared library, which can be
88 compiled and linked to with the
89 <constant>libsystemd</constant> <citerefentry project='die-net'><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
90 file.</para>
91 </refsect1>
92
93 <refsect1>
94 <title>See Also</title>
95
96 <para>
97 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
98 <citerefentry><refentrytitle>sd-bus</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
99 <citerefentry><refentrytitle>sd_bus_message_append</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
100 <citerefentry><refentrytitle>sd_bus_message_append_array</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
101 <ulink url="http://dbus.freedesktop.org/doc/dbus-specification.html">The D-Bus specification</ulink>
102 </para>
103 </refsect1>
104
105 </refentry>