Imported Upstream version 0.11.1
Andreas Henriksson
11 years ago
4 | 4 | |
5 | 5 | ACLOCAL_AMFLAGS=-I m4 ${ACLOCAL_FLAGS} |
6 | 6 | |
7 | DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc | |
7 | DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-introspection | |
8 | 8 | |
9 | 9 | # Extra clean files so that maintainer-clean removes *everything* |
10 | 10 | MAINTAINERCLEANFILES = aclocal.m4 compile config.guess config.sub configure depcomp install-sh ltmain.sh Makefile.in missing config.h.in |
38 | 38 | $(srcdir)/Makefile.in $(srcdir)/config.h.in \ |
39 | 39 | $(srcdir)/gupnp-av-1.0-uninstalled.pc.in \ |
40 | 40 | $(srcdir)/gupnp-av-1.0.pc.in $(top_srcdir)/configure AUTHORS \ |
41 | COPYING ChangeLog INSTALL NEWS build-aux/config.guess \ | |
42 | build-aux/config.sub build-aux/depcomp build-aux/install-sh \ | |
43 | build-aux/ltmain.sh build-aux/missing | |
41 | COPYING ChangeLog INSTALL NEWS build-aux/compile \ | |
42 | build-aux/config.guess build-aux/config.sub build-aux/depcomp \ | |
43 | build-aux/install-sh build-aux/ltmain.sh build-aux/missing | |
44 | 44 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 |
45 | 45 | am__aclocal_m4_deps = $(top_srcdir)/m4/gtk-doc.m4 \ |
46 | 46 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
47 | 47 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
48 | 48 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
49 | $(top_srcdir)/configure.ac | |
49 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
50 | 50 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
51 | 51 | $(ACLOCAL_M4) |
52 | 52 | am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ |
287 | 287 | pkgconfig_DATA = gupnp-av-1.0.pc |
288 | 288 | pkgconfigdir = $(libdir)/pkgconfig |
289 | 289 | ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS} |
290 | DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc | |
290 | DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-introspection | |
291 | 291 | |
292 | 292 | # Extra clean files so that maintainer-clean removes *everything* |
293 | 293 | MAINTAINERCLEANFILES = aclocal.m4 compile config.guess config.sub configure depcomp install-sh ltmain.sh Makefile.in missing config.h.in |
0 | 0.11.1 | |
1 | ====== | |
2 | ||
3 | Changes since 0.11.0: | |
4 | - Add m4 vapigen detection macro. | |
5 | - Fix introspection install dirs. | |
6 | - Fix objectUpdateID setter. | |
7 | - Add a FeatureList parser. | |
8 | - Add some XML fragment getters for DIDLLiteObject. | |
9 | - Lower G-I requirements. | |
10 | - Enable introspection during distcheck. | |
11 | - Undeprecate single-value _{get|set}_creator methods. | |
12 | ||
13 | Bugs fixed in this release: | |
14 | - https://bugzilla.gnome.org/show_bug.cgi?id=685963 | |
15 | - https://bugzilla.gnome.org/show_bug.cgi?id=686464 | |
16 | ||
17 | All contributors to this release: | |
18 | ||
19 | Jens Georg <mail@jensge.org> | |
20 | Regis Merlino <regis.merlino@intel.com> | |
21 | Christophe Guiraud <christophe.guiraud@intel.com> | |
22 | ||
0 | 23 | 0.11.0 |
1 | 24 | ====== |
2 | 25 | |
16 | 39 | Andreas Henriksson <andreas@fatal.se> |
17 | 40 | Christophe Guiraud <christophe.guiraud@intel.com> |
18 | 41 | |
19 | Bug fixes in this release: | |
42 | Bug fixed in this release: | |
20 | 43 | - https://bugzilla.gnome.org/show_bug.cgi?id=684297 |
21 | 44 | - https://bugzilla.gnome.org/show_bug.cgi?id=685477 |
22 | 45 |
1204 | 1204 | fi[]dnl |
1205 | 1205 | ])# PKG_CHECK_MODULES |
1206 | 1206 | |
1207 | dnl vala.m4 | |
1208 | dnl | |
1209 | dnl Copyright 2010 Marc-Andre Lureau | |
1210 | dnl Copyright 2011 Rodney Dawes <dobey.pwns@gmail.com> | |
1211 | dnl | |
1212 | dnl This library is free software; you can redistribute it and/or | |
1213 | dnl modify it under the terms of the GNU Lesser General Public | |
1214 | dnl License as published by the Free Software Foundation; either | |
1215 | dnl version 2.1 of the License, or (at your option) any later version. | |
1216 | dnl | |
1217 | dnl This library is distributed in the hope that it will be useful, | |
1218 | dnl but WITHOUT ANY WARRANTY; without even the implied warranty of | |
1219 | dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
1220 | dnl Lesser General Public License for more details. | |
1221 | dnl | |
1222 | dnl You should have received a copy of the GNU Lesser General Public | |
1223 | dnl License along with this library; if not, write to the Free Software | |
1224 | dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA | |
1225 | ||
1226 | # _VALA_CHECK_COMPILE_WITH_ARGS(ARGS, [ACTION-IF-TRUE], | |
1227 | # [ACTION-IF-FALSE]) | |
1228 | # -------------------------------------- | |
1229 | # Check that Vala compile with ARGS. | |
1230 | # | |
1231 | AC_DEFUN([_VALA_CHECK_COMPILE_WITH_ARGS], | |
1232 | [AC_REQUIRE([AM_PROG_VALAC])[]dnl | |
1233 | ||
1234 | cat <<_ACEOF >conftest.vala | |
1235 | void main(){} | |
1236 | _ACEOF | |
1237 | ||
1238 | AS_IF([vala_error=`$VALAC $1 -q -o conftest$ac_exeext conftest.vala 2>&1`], | |
1239 | [$2], [$3]) | |
1240 | ]) | |
1241 | ||
1242 | ])# _VALA_CHECK_COMPILE_WITH_ARGS | |
1243 | ||
1244 | # VALA_CHECK_PACKAGES(PKGS, [ACTION-IF-FOUND], | |
1245 | # [ACTION-IF-NOT-FOUND]) | |
1246 | # -------------------------------------- | |
1247 | # Check that PKGS Vala bindings are installed and usable. | |
1248 | # | |
1249 | AC_DEFUN([VALA_CHECK_PACKAGES], | |
1250 | [ | |
1251 | unset vala_pkgs | |
1252 | unset vala_bindings | |
1253 | ac_save_ifs="$IFS"; unset IFS | |
1254 | for vala_pkg in $(echo "$1"); do | |
1255 | vala_pkgs="${vala_pkgs:+$vala_pkgs }--pkg $vala_pkg" | |
1256 | vala_bindings="${vala_bindings:+$vala_bindings }$vala_pkg" | |
1257 | done | |
1258 | IFS="$ac_save_ifs" | |
1259 | AC_MSG_CHECKING([for $vala_bindings vala bindings]) | |
1260 | _VALA_CHECK_COMPILE_WITH_ARGS([$vala_pkgs], | |
1261 | [vala_pkg_exists=yes], | |
1262 | [vala_pkg_exists=no]) | |
1263 | ||
1264 | AS_IF([test x${vala_pkg_exists} = xno],[ | |
1265 | ifelse([$3], , [AC_MSG_ERROR([]dnl | |
1266 | [Package requirements were not met: $1 | |
1267 | ||
1268 | $vala_error | |
1269 | ||
1270 | Consider adjusting the XDG_DATA_DIRS environment variable if you | |
1271 | installed bindings in a non-standard prefix. | |
1272 | ])], | |
1273 | [AC_MSG_RESULT([no]) | |
1274 | $3])],[ | |
1275 | AC_MSG_RESULT([yes]) | |
1276 | ifelse([$2], , :, [$2])[]dnl | |
1277 | ]) | |
1278 | ||
1279 | ])# VALA_CHECK_PACKAGES | |
1280 | ||
1281 | ||
1282 | # Check for Vala bindings for a package, as well as the pkg-config | |
1283 | # CFLAGS and LIBS for the package. The arguments here work the | |
1284 | # same as those for PKG_CHECK_MODULES, which is called internally. | |
1285 | # As a result, the _CFLAGS, _LIBS, and _VALAFLAGS variables will | |
1286 | # all be declared, rather than only _VALAFLAGS. | |
1287 | # | |
1288 | # VALA_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], | |
1289 | # [ACTION-IF-NOT-FOUND]) | |
1290 | # -------------------------------------------------------------- | |
1291 | AC_DEFUN([VALA_CHECK_MODULES], | |
1292 | [ | |
1293 | AC_REQUIRE([AM_PROG_VALAC])dnl | |
1294 | AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl | |
1295 | AC_REQUIRE([_VALA_CHECK_COMPILE_WITH_ARGS])dnl | |
1296 | AC_ARG_VAR([$1][_VALAFLAGS], [Vala compiler flags for $1])dnl | |
1297 | ||
1298 | VALA_MODULES="`echo '$2' | sed -e 's/ [[=<>]]\+ [[0-9.]]\+//g'`" | |
1299 | for MODULE in $VALA_MODULES; do | |
1300 | $1[]_VALAFLAGS="$[]$1[]_VALAFLAGS --pkg $MODULE" | |
1301 | done | |
1302 | ||
1303 | PKG_CHECK_MODULES([$1], [$2], [$3], [$4]) | |
1304 | ||
1305 | pkg_failed=no | |
1306 | AC_MSG_CHECKING([for $1 vala modules]) | |
1307 | ||
1308 | _VALA_CHECK_COMPILE_WITH_ARGS([$1][_VALAFLAGS], | |
1309 | [pkg_failed=yes], | |
1310 | [pkg_failed=no]) | |
1311 | ||
1312 | if test $pkg_failed = yes; then | |
1313 | AC_MSG_RESULT([no]) | |
1314 | m4_default([$4], [AC_MSG_ERROR( | |
1315 | [Package requirements ($2) were not met.])dnl | |
1316 | ]) | |
1317 | else | |
1318 | AC_MSG_RESULT([yes]) | |
1319 | m4_default([$3], [:]) | |
1320 | fi[]dnl | |
1321 | ]) | |
1322 | ||
1323 | # Check whether the Vala API Generator exists in `PATH'. If it is found, | |
1324 | # the variable VAPIGEN is set. Optionally a minimum release number of the | |
1325 | # generator can be requested. | |
1326 | # | |
1327 | # VALA_PROG_VAPIGEN([MINIMUM-VERSION]) | |
1328 | # ------------------------------------ | |
1329 | AC_DEFUN([VALA_PROG_VAPIGEN], | |
1330 | [AC_PATH_PROG([VAPIGEN], [vapigen], []) | |
1331 | AS_IF([test -z "$VAPIGEN"], | |
1332 | [AC_MSG_WARN([No Vala API Generator found. You will not be able to generate .vapi files.])], | |
1333 | [AS_IF([test -n "$1"], | |
1334 | [AC_MSG_CHECKING([$VAPIGEN is at least version $1]) | |
1335 | am__vapigen_version=`$VAPIGEN --version | sed 's/Vala API Generator *//'` | |
1336 | AS_VERSION_COMPARE([$1], ["$am__vapigen_version"], | |
1337 | [AC_MSG_RESULT([yes])], | |
1338 | [AC_MSG_RESULT([yes])], | |
1339 | [AC_MSG_RESULT([no]) | |
1340 | AC_MSG_ERROR([Vala API Generator $1 not found.])])])]) | |
1341 | ]) | |
1342 | ||
1343 | 1207 | m4_include([m4/gtk-doc.m4]) |
1344 | 1208 | m4_include([m4/introspection.m4]) |
1345 | 1209 | m4_include([m4/libtool.m4]) |
1347 | 1211 | m4_include([m4/ltsugar.m4]) |
1348 | 1212 | m4_include([m4/ltversion.m4]) |
1349 | 1213 | m4_include([m4/lt~obsolete.m4]) |
1214 | m4_include([m4/vapigen.m4]) |
0 | #! /bin/sh | |
1 | # Wrapper for compilers which do not understand '-c -o'. | |
2 | ||
3 | scriptversion=2012-01-04.17; # UTC | |
4 | ||
5 | # Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009, 2010, 2012 Free | |
6 | # Software Foundation, Inc. | |
7 | # Written by Tom Tromey <tromey@cygnus.com>. | |
8 | # | |
9 | # This program is free software; you can redistribute it and/or modify | |
10 | # it under the terms of the GNU General Public License as published by | |
11 | # the Free Software Foundation; either version 2, or (at your option) | |
12 | # any later version. | |
13 | # | |
14 | # This program is distributed in the hope that it will be useful, | |
15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | # GNU General Public License for more details. | |
18 | # | |
19 | # You should have received a copy of the GNU General Public License | |
20 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
21 | ||
22 | # As a special exception to the GNU General Public License, if you | |
23 | # distribute this file as part of a program that contains a | |
24 | # configuration script generated by Autoconf, you may include it under | |
25 | # the same distribution terms that you use for the rest of that program. | |
26 | ||
27 | # This file is maintained in Automake, please report | |
28 | # bugs to <bug-automake@gnu.org> or send patches to | |
29 | # <automake-patches@gnu.org>. | |
30 | ||
31 | nl=' | |
32 | ' | |
33 | ||
34 | # We need space, tab and new line, in precisely that order. Quoting is | |
35 | # there to prevent tools from complaining about whitespace usage. | |
36 | IFS=" "" $nl" | |
37 | ||
38 | file_conv= | |
39 | ||
40 | # func_file_conv build_file lazy | |
41 | # Convert a $build file to $host form and store it in $file | |
42 | # Currently only supports Windows hosts. If the determined conversion | |
43 | # type is listed in (the comma separated) LAZY, no conversion will | |
44 | # take place. | |
45 | func_file_conv () | |
46 | { | |
47 | file=$1 | |
48 | case $file in | |
49 | / | /[!/]*) # absolute file, and not a UNC file | |
50 | if test -z "$file_conv"; then | |
51 | # lazily determine how to convert abs files | |
52 | case `uname -s` in | |
53 | MINGW*) | |
54 | file_conv=mingw | |
55 | ;; | |
56 | CYGWIN*) | |
57 | file_conv=cygwin | |
58 | ;; | |
59 | *) | |
60 | file_conv=wine | |
61 | ;; | |
62 | esac | |
63 | fi | |
64 | case $file_conv/,$2, in | |
65 | *,$file_conv,*) | |
66 | ;; | |
67 | mingw/*) | |
68 | file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` | |
69 | ;; | |
70 | cygwin/*) | |
71 | file=`cygpath -m "$file" || echo "$file"` | |
72 | ;; | |
73 | wine/*) | |
74 | file=`winepath -w "$file" || echo "$file"` | |
75 | ;; | |
76 | esac | |
77 | ;; | |
78 | esac | |
79 | } | |
80 | ||
81 | # func_cl_wrapper cl arg... | |
82 | # Adjust compile command to suit cl | |
83 | func_cl_wrapper () | |
84 | { | |
85 | # Assume a capable shell | |
86 | lib_path= | |
87 | shared=: | |
88 | linker_opts= | |
89 | for arg | |
90 | do | |
91 | if test -n "$eat"; then | |
92 | eat= | |
93 | else | |
94 | case $1 in | |
95 | -o) | |
96 | # configure might choose to run compile as 'compile cc -o foo foo.c'. | |
97 | eat=1 | |
98 | case $2 in | |
99 | *.o | *.[oO][bB][jJ]) | |
100 | func_file_conv "$2" | |
101 | set x "$@" -Fo"$file" | |
102 | shift | |
103 | ;; | |
104 | *) | |
105 | func_file_conv "$2" | |
106 | set x "$@" -Fe"$file" | |
107 | shift | |
108 | ;; | |
109 | esac | |
110 | ;; | |
111 | -I*) | |
112 | func_file_conv "${1#-I}" mingw | |
113 | set x "$@" -I"$file" | |
114 | shift | |
115 | ;; | |
116 | -l*) | |
117 | lib=${1#-l} | |
118 | found=no | |
119 | save_IFS=$IFS | |
120 | IFS=';' | |
121 | for dir in $lib_path $LIB | |
122 | do | |
123 | IFS=$save_IFS | |
124 | if $shared && test -f "$dir/$lib.dll.lib"; then | |
125 | found=yes | |
126 | set x "$@" "$dir/$lib.dll.lib" | |
127 | break | |
128 | fi | |
129 | if test -f "$dir/$lib.lib"; then | |
130 | found=yes | |
131 | set x "$@" "$dir/$lib.lib" | |
132 | break | |
133 | fi | |
134 | done | |
135 | IFS=$save_IFS | |
136 | ||
137 | test "$found" != yes && set x "$@" "$lib.lib" | |
138 | shift | |
139 | ;; | |
140 | -L*) | |
141 | func_file_conv "${1#-L}" | |
142 | if test -z "$lib_path"; then | |
143 | lib_path=$file | |
144 | else | |
145 | lib_path="$lib_path;$file" | |
146 | fi | |
147 | linker_opts="$linker_opts -LIBPATH:$file" | |
148 | ;; | |
149 | -static) | |
150 | shared=false | |
151 | ;; | |
152 | -Wl,*) | |
153 | arg=${1#-Wl,} | |
154 | save_ifs="$IFS"; IFS=',' | |
155 | for flag in $arg; do | |
156 | IFS="$save_ifs" | |
157 | linker_opts="$linker_opts $flag" | |
158 | done | |
159 | IFS="$save_ifs" | |
160 | ;; | |
161 | -Xlinker) | |
162 | eat=1 | |
163 | linker_opts="$linker_opts $2" | |
164 | ;; | |
165 | -*) | |
166 | set x "$@" "$1" | |
167 | shift | |
168 | ;; | |
169 | *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) | |
170 | func_file_conv "$1" | |
171 | set x "$@" -Tp"$file" | |
172 | shift | |
173 | ;; | |
174 | *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) | |
175 | func_file_conv "$1" mingw | |
176 | set x "$@" "$file" | |
177 | shift | |
178 | ;; | |
179 | *) | |
180 | set x "$@" "$1" | |
181 | shift | |
182 | ;; | |
183 | esac | |
184 | fi | |
185 | shift | |
186 | done | |
187 | if test -n "$linker_opts"; then | |
188 | linker_opts="-link$linker_opts" | |
189 | fi | |
190 | exec "$@" $linker_opts | |
191 | exit 1 | |
192 | } | |
193 | ||
194 | eat= | |
195 | ||
196 | case $1 in | |
197 | '') | |
198 | echo "$0: No command. Try '$0 --help' for more information." 1>&2 | |
199 | exit 1; | |
200 | ;; | |
201 | -h | --h*) | |
202 | cat <<\EOF | |
203 | Usage: compile [--help] [--version] PROGRAM [ARGS] | |
204 | ||
205 | Wrapper for compilers which do not understand '-c -o'. | |
206 | Remove '-o dest.o' from ARGS, run PROGRAM with the remaining | |
207 | arguments, and rename the output as expected. | |
208 | ||
209 | If you are trying to build a whole package this is not the | |
210 | right script to run: please start by reading the file 'INSTALL'. | |
211 | ||
212 | Report bugs to <bug-automake@gnu.org>. | |
213 | EOF | |
214 | exit $? | |
215 | ;; | |
216 | -v | --v*) | |
217 | echo "compile $scriptversion" | |
218 | exit $? | |
219 | ;; | |
220 | cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) | |
221 | func_cl_wrapper "$@" # Doesn't return... | |
222 | ;; | |
223 | esac | |
224 | ||
225 | ofile= | |
226 | cfile= | |
227 | ||
228 | for arg | |
229 | do | |
230 | if test -n "$eat"; then | |
231 | eat= | |
232 | else | |
233 | case $1 in | |
234 | -o) | |
235 | # configure might choose to run compile as 'compile cc -o foo foo.c'. | |
236 | # So we strip '-o arg' only if arg is an object. | |
237 | eat=1 | |
238 | case $2 in | |
239 | *.o | *.obj) | |
240 | ofile=$2 | |
241 | ;; | |
242 | *) | |
243 | set x "$@" -o "$2" | |
244 | shift | |
245 | ;; | |
246 | esac | |
247 | ;; | |
248 | *.c) | |
249 | cfile=$1 | |
250 | set x "$@" "$1" | |
251 | shift | |
252 | ;; | |
253 | *) | |
254 | set x "$@" "$1" | |
255 | shift | |
256 | ;; | |
257 | esac | |
258 | fi | |
259 | shift | |
260 | done | |
261 | ||
262 | if test -z "$ofile" || test -z "$cfile"; then | |
263 | # If no '-o' option was seen then we might have been invoked from a | |
264 | # pattern rule where we don't need one. That is ok -- this is a | |
265 | # normal compilation that the losing compiler can handle. If no | |
266 | # '.c' file was seen then we are probably linking. That is also | |
267 | # ok. | |
268 | exec "$@" | |
269 | fi | |
270 | ||
271 | # Name of file we expect compiler to create. | |
272 | cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` | |
273 | ||
274 | # Create the lock directory. | |
275 | # Note: use '[/\\:.-]' here to ensure that we don't use the same name | |
276 | # that we are using for the .o file. Also, base the name on the expected | |
277 | # object file name, since that is what matters with a parallel build. | |
278 | lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d | |
279 | while true; do | |
280 | if mkdir "$lockdir" >/dev/null 2>&1; then | |
281 | break | |
282 | fi | |
283 | sleep 1 | |
284 | done | |
285 | # FIXME: race condition here if user kills between mkdir and trap. | |
286 | trap "rmdir '$lockdir'; exit 1" 1 2 15 | |
287 | ||
288 | # Run the compile. | |
289 | "$@" | |
290 | ret=$? | |
291 | ||
292 | if test -f "$cofile"; then | |
293 | test "$cofile" = "$ofile" || mv "$cofile" "$ofile" | |
294 | elif test -f "${cofile}bj"; then | |
295 | test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" | |
296 | fi | |
297 | ||
298 | rmdir "$lockdir" | |
299 | exit $ret | |
300 | ||
301 | # Local Variables: | |
302 | # mode: shell-script | |
303 | # sh-indentation: 2 | |
304 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
305 | # time-stamp-start: "scriptversion=" | |
306 | # time-stamp-format: "%:y-%02m-%02d.%02H" | |
307 | # time-stamp-time-zone: "UTC" | |
308 | # time-stamp-end: "; # UTC" | |
309 | # End: |
0 | 0 | #! /bin/sh |
1 | 1 | # Guess values for system-dependent variables and create Makefiles. |
2 | # Generated by GNU Autoconf 2.68 for gupnp-av 0.11.0. | |
2 | # Generated by GNU Autoconf 2.68 for gupnp-av 0.11.1. | |
3 | 3 | # |
4 | 4 | # Report bugs to <https://bugzilla.gnome.org/enter_bug.cgi?product=GUPnP>. |
5 | 5 | # |
630 | 630 | # Identity of this package. |
631 | 631 | PACKAGE_NAME='gupnp-av' |
632 | 632 | PACKAGE_TARNAME='gupnp-av' |
633 | PACKAGE_VERSION='0.11.0' | |
634 | PACKAGE_STRING='gupnp-av 0.11.0' | |
633 | PACKAGE_VERSION='0.11.1' | |
634 | PACKAGE_STRING='gupnp-av 0.11.1' | |
635 | 635 | PACKAGE_BUGREPORT='https://bugzilla.gnome.org/enter_bug.cgi?product=GUPnP' |
636 | 636 | PACKAGE_URL='http://www.gupnp.org/' |
637 | 637 | |
1402 | 1402 | # Omit some internal or obsolete options to make the list less imposing. |
1403 | 1403 | # This message is too long to be a string in the A/UX 3.1 sh. |
1404 | 1404 | cat <<_ACEOF |
1405 | \`configure' configures gupnp-av 0.11.0 to adapt to many kinds of systems. | |
1405 | \`configure' configures gupnp-av 0.11.1 to adapt to many kinds of systems. | |
1406 | 1406 | |
1407 | 1407 | Usage: $0 [OPTION]... [VAR=VALUE]... |
1408 | 1408 | |
1472 | 1472 | |
1473 | 1473 | if test -n "$ac_init_help"; then |
1474 | 1474 | case $ac_init_help in |
1475 | short | recursive ) echo "Configuration of gupnp-av 0.11.0:";; | |
1475 | short | recursive ) echo "Configuration of gupnp-av 0.11.1:";; | |
1476 | 1476 | esac |
1477 | 1477 | cat <<\_ACEOF |
1478 | 1478 | |
1596 | 1596 | test -n "$ac_init_help" && exit $ac_status |
1597 | 1597 | if $ac_init_version; then |
1598 | 1598 | cat <<\_ACEOF |
1599 | gupnp-av configure 0.11.0 | |
1599 | gupnp-av configure 0.11.1 | |
1600 | 1600 | generated by GNU Autoconf 2.68 |
1601 | 1601 | |
1602 | 1602 | Copyright (C) 2010 Free Software Foundation, Inc. |
1874 | 1874 | This file contains any messages produced by compilers while |
1875 | 1875 | running configure, to aid debugging if configure makes a mistake. |
1876 | 1876 | |
1877 | It was created by gupnp-av $as_me 0.11.0, which was | |
1877 | It was created by gupnp-av $as_me 0.11.1, which was | |
1878 | 1878 | generated by GNU Autoconf 2.68. Invocation command line was |
1879 | 1879 | |
1880 | 1880 | $ $0 $@ |
2698 | 2698 | |
2699 | 2699 | # Define the identity of the package. |
2700 | 2700 | PACKAGE='gupnp-av' |
2701 | VERSION='0.11.0' | |
2701 | VERSION='0.11.1' | |
2702 | 2702 | |
2703 | 2703 | |
2704 | 2704 | cat >>confdefs.h <<_ACEOF |
12213 | 12213 | as_fn_error $? "gobject-introspection-1.0 is not installed" "$LINENO" 5 |
12214 | 12214 | fi |
12215 | 12215 | if test -n "$PKG_CONFIG" && \ |
12216 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gobject-introspection-1.0 >= 1.33.4\""; } >&5 | |
12217 | ($PKG_CONFIG --exists --print-errors "gobject-introspection-1.0 >= 1.33.4") 2>&5 | |
12216 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gobject-introspection-1.0 >= 0.9.5\""; } >&5 | |
12217 | ($PKG_CONFIG --exists --print-errors "gobject-introspection-1.0 >= 0.9.5") 2>&5 | |
12218 | 12218 | ac_status=$? |
12219 | 12219 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12220 | 12220 | test $ac_status = 0; }; then |
12221 | 12221 | found_introspection=yes |
12222 | 12222 | else |
12223 | as_fn_error $? "You need to have gobject-introspection >= 1.33.4 installed to build gupnp-av" "$LINENO" 5 | |
12223 | as_fn_error $? "You need to have gobject-introspection >= 0.9.5 installed to build gupnp-av" "$LINENO" 5 | |
12224 | 12224 | fi |
12225 | 12225 | ;; #( |
12226 | 12226 | auto) : |
12227 | 12227 | if test -n "$PKG_CONFIG" && \ |
12228 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gobject-introspection-1.0 >= 1.33.4\""; } >&5 | |
12229 | ($PKG_CONFIG --exists --print-errors "gobject-introspection-1.0 >= 1.33.4") 2>&5 | |
12228 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gobject-introspection-1.0 >= 0.9.5\""; } >&5 | |
12229 | ($PKG_CONFIG --exists --print-errors "gobject-introspection-1.0 >= 0.9.5") 2>&5 | |
12230 | 12230 | ac_status=$? |
12231 | 12231 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12232 | 12232 | test $ac_status = 0; }; then |
13247 | 13247 | # report actual input values of CONFIG_FILES etc. instead of their |
13248 | 13248 | # values after options handling. |
13249 | 13249 | ac_log=" |
13250 | This file was extended by gupnp-av $as_me 0.11.0, which was | |
13250 | This file was extended by gupnp-av $as_me 0.11.1, which was | |
13251 | 13251 | generated by GNU Autoconf 2.68. Invocation command line was |
13252 | 13252 | |
13253 | 13253 | CONFIG_FILES = $CONFIG_FILES |
13314 | 13314 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
13315 | 13315 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
13316 | 13316 | ac_cs_version="\\ |
13317 | gupnp-av config.status 0.11.0 | |
13317 | gupnp-av config.status 0.11.1 | |
13318 | 13318 | configured by $0, generated by GNU Autoconf 2.68, |
13319 | 13319 | with options \\"\$ac_cs_config\\" |
13320 | 13320 |
0 | 0 | AC_PREREQ([2.63]) |
1 | 1 | AC_INIT([gupnp-av], |
2 | [0.11.0], | |
2 | [0.11.1], | |
3 | 3 | [https://bugzilla.gnome.org/enter_bug.cgi?product=GUPnP], |
4 | 4 | [gupnp-av], |
5 | 5 | [http://www.gupnp.org/]) |
38 | 38 | CFLAGS="$CFLAGS -g -Wall" |
39 | 39 | fi |
40 | 40 | |
41 | GOBJECT_INTROSPECTION_CHECK([1.33.4]) | |
41 | GOBJECT_INTROSPECTION_CHECK([0.9.5]) | |
42 | 42 | |
43 | 43 | # vapigen |
44 | 44 | AS_IF([test "x$found_introspection" = "xyes"], |
46 | 46 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
47 | 47 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
48 | 48 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
49 | $(top_srcdir)/configure.ac | |
49 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
50 | 50 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
51 | 51 | $(ACLOCAL_M4) |
52 | 52 | mkinstalldirs = $(install_sh) -d |
58 | 58 | <xi:include href="xml/gupnp-last-change-parser.xml"/> |
59 | 59 | <xi:include href="xml/gupnp-search-criteria-parser.xml"/> |
60 | 60 | <xi:include href="xml/gupnp-protocol-info.xml"/> |
61 | <xi:include href="xml/gupnp-feature.xml"/> | |
62 | <xi:include href="xml/gupnp-feature-list-parser.xml"/> | |
61 | 63 | |
62 | 64 | </chapter> |
63 | 65 |
337 | 337 | </SECTION> |
338 | 338 | |
339 | 339 | <SECTION> |
340 | <FILE>gupnp-feature</FILE> | |
341 | <TITLE>GUPnPFeature</TITLE> | |
342 | GUPnPFeature | |
343 | gupnp_feature_get_name | |
344 | gupnp_feature_get_version | |
345 | gupnp_feature_get_object_ids | |
346 | <SUBSECTION Standard> | |
347 | GUPnPFeatureClass | |
348 | GUPNP_TYPE_FEATURE | |
349 | GUPNP_FEATURE | |
350 | GUPNP_FEATURE_CLASS | |
351 | GUPNP_IS_FEATURE_PARSER | |
352 | GUPNP_IS_FEATURE_PARSER_CLASS | |
353 | GUPNP_FEATURE_GET_CLASS | |
354 | <SUBSECTION Private> | |
355 | GUPnPFeaturePrivate | |
356 | gupnp_feature_get_type | |
357 | </SECTION> | |
358 | ||
359 | <SECTION> | |
360 | <FILE>gupnp-feature-list-parser</FILE> | |
361 | <TITLE>GUPnPFeatureListParser</TITLE> | |
362 | GUPnPFeatureListParser | |
363 | gupnp_feature_list_parser_new | |
364 | gupnp_feature_list_parser_parse_text | |
365 | <SUBSECTION Standard> | |
366 | GUPnPFeatureListParserClass | |
367 | GUPNP_TYPE_FEATURE_LIST_PARSER | |
368 | GUPNP_FEATURE_LIST_PARSER | |
369 | GUPNP_FEATURE_LIST_PARSER_CLASS | |
370 | GUPNP_IS_FEATURE_LIST_PARSER_PARSER | |
371 | GUPNP_IS_FEATURE_LIST_PARSER_PARSER_CLASS | |
372 | GUPNP_FEATURE_LIST_PARSER_GET_CLASS | |
373 | <SUBSECTION Private> | |
374 | gupnp_feature_list_parser_get_type | |
375 | </SECTION> | |
376 | ||
377 | <SECTION> | |
340 | 378 | <FILE>gupnp-av-error</FILE> |
341 | 379 | <TITLE>Error codes</TITLE> |
342 | 380 | GUPNP_PROTOCOL_ERROR |
11 | 11 | gupnp_last_change_parser_get_type |
12 | 12 | gupnp_search_criteria_parser_get_type |
13 | 13 | gupnp_search_criteria_op_get_type |
14 | gupnp_feature_get_type | |
15 | gupnp_feature_list_parser_get_type |
460 | 460 | <div class="refsect2"> |
461 | 461 | <a name="gupnp-didl-lite-object-get-creator"></a><h3>gupnp_didl_lite_object_get_creator ()</h3> |
462 | 462 | <pre class="programlisting">const <span class="returnvalue">char</span> * gupnp_didl_lite_object_get_creator (<em class="parameter"><code><a class="link" href="GUPnPDIDLLiteObject.html" title="GUPnPDIDLLiteObject"><span class="type">GUPnPDIDLLiteObject</span></a> *object</code></em>);</pre> |
463 | <div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"> | |
464 | <h3 class="title">Warning</h3> | |
465 | <p><code class="literal">gupnp_didl_lite_object_get_creator</code> has been deprecated since version 0.5.3 and should not be used in newly-written code. Use <a class="link" href="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-creators" title="gupnp_didl_lite_object_get_creators ()"><span class="type">gupnp_didl_lite_object_get_creators</span></a> instead.</p> | |
466 | </div> | |
467 | 463 | <p> |
468 | 464 | Get the creator of the <em class="parameter"><code>object</code></em>. |
469 | 465 | </p> |
1060 | 1056 | <a name="gupnp-didl-lite-object-set-creator"></a><h3>gupnp_didl_lite_object_set_creator ()</h3> |
1061 | 1057 | <pre class="programlisting"><span class="returnvalue">void</span> gupnp_didl_lite_object_set_creator (<em class="parameter"><code><a class="link" href="GUPnPDIDLLiteObject.html" title="GUPnPDIDLLiteObject"><span class="type">GUPnPDIDLLiteObject</span></a> *object</code></em>, |
1062 | 1058 | <em class="parameter"><code>const <span class="type">char</span> *creator</code></em>);</pre> |
1063 | <div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"> | |
1064 | <h3 class="title">Warning</h3> | |
1065 | <p><code class="literal">gupnp_didl_lite_object_set_creator</code> has been deprecated since version 0.5.3 and should not be used in newly-written code. Use <a class="link" href="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-add-creator" title="gupnp_didl_lite_object_add_creator ()"><span class="type">gupnp_didl_lite_object_add_creator</span></a> instead.</p> | |
1066 | </div> | |
1067 | 1059 | <p> |
1068 | 1060 | Set the creator of the <em class="parameter"><code>object</code></em> to <em class="parameter"><code>creator</code></em>. |
1069 | 1061 | </p> |
1446 | 1438 | <div class="refsect2"> |
1447 | 1439 | <a name="GUPnPDIDLLiteObject--creator"></a><h3>The <code class="literal">"creator"</code> property</h3> |
1448 | 1440 | <pre class="programlisting"> "creator" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre> |
1449 | <div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"> | |
1450 | <h3 class="title">Warning</h3> | |
1451 | <p><code class="literal">GUPnPDIDLLiteObject:creator</code> has been deprecated since version 0.5.3 and should not be used in newly-written code. Use <a class="link" href="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-creators" title="gupnp_didl_lite_object_get_creators ()"><span class="type">gupnp_didl_lite_object_get_creators</span></a> and | |
1452 | <a class="link" href="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-add-creator" title="gupnp_didl_lite_object_add_creator ()"><span class="type">gupnp_didl_lite_object_add_creator</span></a> instead since unlike this | |
1453 | property, they are capable of dealing with multiple creator nodes.</p> | |
1454 | </div> | |
1455 | 1441 | <p> |
1456 | 1442 | The creator of this object. |
1457 | 1443 | </p> |
0 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
1 | <html> | |
2 | <head> | |
3 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
4 | <title>GUPnPFeature</title> | |
5 | <meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> | |
6 | <link rel="home" href="index.html" title="GUPnP A/V Reference Manual"> | |
7 | <link rel="up" href="ch01.html" title="GUPnP A/V"> | |
8 | <link rel="prev" href="GUPnPProtocolInfo.html" title="GUPnPProtocolInfo"> | |
9 | <link rel="next" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"> | |
10 | <meta name="generator" content="GTK-Doc V1.18.1 (XML mode)"> | |
11 | <link rel="stylesheet" href="style.css" type="text/css"> | |
12 | </head> | |
13 | <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> | |
14 | <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"> | |
15 | <tr valign="middle"> | |
16 | <td><a accesskey="p" href="GUPnPProtocolInfo.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> | |
17 | <td><a accesskey="u" href="ch01.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td> | |
18 | <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> | |
19 | <th width="100%" align="center">GUPnP A/V Reference Manual</th> | |
20 | <td><a accesskey="n" href="GUPnPFeatureListParser.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> | |
21 | </tr> | |
22 | <tr><td colspan="5" class="shortcuts"> | |
23 | <a href="#GUPnPFeature.synopsis" class="shortcut">Top</a> | |
24 | | | |
25 | <a href="#GUPnPFeature.description" class="shortcut">Description</a> | |
26 | | | |
27 | <a href="#GUPnPFeature.object-hierarchy" class="shortcut">Object Hierarchy</a> | |
28 | | | |
29 | <a href="#GUPnPFeature.properties" class="shortcut">Properties</a> | |
30 | </td></tr> | |
31 | </table> | |
32 | <div class="refentry"> | |
33 | <a name="GUPnPFeature"></a><div class="titlepage"></div> | |
34 | <div class="refnamediv"><table width="100%"><tr> | |
35 | <td valign="top"> | |
36 | <h2><span class="refentrytitle"><a name="GUPnPFeature.top_of_page"></a>GUPnPFeature</span></h2> | |
37 | <p>GUPnPFeature — ContentDirectory feature</p> | |
38 | </td> | |
39 | <td valign="top" align="right"></td> | |
40 | </tr></table></div> | |
41 | <div class="refsynopsisdiv"> | |
42 | <a name="GUPnPFeature.synopsis"></a><h2>Synopsis</h2> | |
43 | <pre class="synopsis"> <a class="link" href="GUPnPFeature.html#GUPnPFeature-struct" title="GUPnPFeature">GUPnPFeature</a>; | |
44 | const <span class="returnvalue">char</span> * <a class="link" href="GUPnPFeature.html#gupnp-feature-get-name" title="gupnp_feature_get_name ()">gupnp_feature_get_name</a> (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>); | |
45 | const <span class="returnvalue">char</span> * <a class="link" href="GUPnPFeature.html#gupnp-feature-get-version" title="gupnp_feature_get_version ()">gupnp_feature_get_version</a> (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>); | |
46 | const <span class="returnvalue">char</span> * <a class="link" href="GUPnPFeature.html#gupnp-feature-get-object-ids" title="gupnp_feature_get_object_ids ()">gupnp_feature_get_object_ids</a> (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>); | |
47 | </pre> | |
48 | </div> | |
49 | <div class="refsect1"> | |
50 | <a name="GUPnPFeature.object-hierarchy"></a><h2>Object Hierarchy</h2> | |
51 | <pre class="synopsis"> | |
52 | <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a> | |
53 | +----GUPnPFeature | |
54 | </pre> | |
55 | </div> | |
56 | <div class="refsect1"> | |
57 | <a name="GUPnPFeature.properties"></a><h2>Properties</h2> | |
58 | <pre class="synopsis"> | |
59 | "<a class="link" href="GUPnPFeature.html#GUPnPFeature--name" title='The "name" property'>name</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only | |
60 | "<a class="link" href="GUPnPFeature.html#GUPnPFeature--object-ids" title='The "object-ids" property'>object-ids</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only | |
61 | "<a class="link" href="GUPnPFeature.html#GUPnPFeature--version" title='The "version" property'>version</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only | |
62 | </pre> | |
63 | </div> | |
64 | <div class="refsect1"> | |
65 | <a name="GUPnPFeature.description"></a><h2>Description</h2> | |
66 | <p> | |
67 | <a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> respresent a Feature element. | |
68 | </p> | |
69 | </div> | |
70 | <div class="refsect1"> | |
71 | <a name="GUPnPFeature.details"></a><h2>Details</h2> | |
72 | <div class="refsect2"> | |
73 | <a name="GUPnPFeature-struct"></a><h3>GUPnPFeature</h3> | |
74 | <pre class="programlisting">typedef struct _GUPnPFeature GUPnPFeature;</pre> | |
75 | </div> | |
76 | <hr> | |
77 | <div class="refsect2"> | |
78 | <a name="gupnp-feature-get-name"></a><h3>gupnp_feature_get_name ()</h3> | |
79 | <pre class="programlisting">const <span class="returnvalue">char</span> * gupnp_feature_get_name (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>);</pre> | |
80 | <p> | |
81 | Get the name of the <em class="parameter"><code>feature</code></em>. | |
82 | </p> | |
83 | <div class="variablelist"><table border="0"> | |
84 | <col align="left" valign="top"> | |
85 | <tbody> | |
86 | <tr> | |
87 | <td><p><span class="term"><em class="parameter"><code>feature</code></em> :</span></p></td> | |
88 | <td><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a></td> | |
89 | </tr> | |
90 | <tr> | |
91 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> | |
92 | <td>The name of the <em class="parameter"><code>feature</code></em>.</td> | |
93 | </tr> | |
94 | </tbody> | |
95 | </table></div> | |
96 | </div> | |
97 | <hr> | |
98 | <div class="refsect2"> | |
99 | <a name="gupnp-feature-get-version"></a><h3>gupnp_feature_get_version ()</h3> | |
100 | <pre class="programlisting">const <span class="returnvalue">char</span> * gupnp_feature_get_version (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>);</pre> | |
101 | <p> | |
102 | Get the version of the <em class="parameter"><code>feature</code></em>. | |
103 | </p> | |
104 | <div class="variablelist"><table border="0"> | |
105 | <col align="left" valign="top"> | |
106 | <tbody> | |
107 | <tr> | |
108 | <td><p><span class="term"><em class="parameter"><code>feature</code></em> :</span></p></td> | |
109 | <td><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a></td> | |
110 | </tr> | |
111 | <tr> | |
112 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> | |
113 | <td>The version of the <em class="parameter"><code>feature</code></em>.</td> | |
114 | </tr> | |
115 | </tbody> | |
116 | </table></div> | |
117 | </div> | |
118 | <hr> | |
119 | <div class="refsect2"> | |
120 | <a name="gupnp-feature-get-object-ids"></a><h3>gupnp_feature_get_object_ids ()</h3> | |
121 | <pre class="programlisting">const <span class="returnvalue">char</span> * gupnp_feature_get_object_ids (<em class="parameter"><code><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a> *feature</code></em>);</pre> | |
122 | <p> | |
123 | Get the object IDs related to the <em class="parameter"><code>feature</code></em>. | |
124 | </p> | |
125 | <div class="variablelist"><table border="0"> | |
126 | <col align="left" valign="top"> | |
127 | <tbody> | |
128 | <tr> | |
129 | <td><p><span class="term"><em class="parameter"><code>feature</code></em> :</span></p></td> | |
130 | <td><a class="link" href="GUPnPFeature.html" title="GUPnPFeature"><span class="type">GUPnPFeature</span></a></td> | |
131 | </tr> | |
132 | <tr> | |
133 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> | |
134 | <td>The object IDs related to the <em class="parameter"><code>feature</code></em>.</td> | |
135 | </tr> | |
136 | </tbody> | |
137 | </table></div> | |
138 | </div> | |
139 | </div> | |
140 | <div class="refsect1"> | |
141 | <a name="GUPnPFeature.property-details"></a><h2>Property Details</h2> | |
142 | <div class="refsect2"> | |
143 | <a name="GUPnPFeature--name"></a><h3>The <code class="literal">"name"</code> property</h3> | |
144 | <pre class="programlisting"> "name" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre> | |
145 | <p> | |
146 | The name of this feature. | |
147 | </p> | |
148 | <p>Default value: NULL</p> | |
149 | </div> | |
150 | <hr> | |
151 | <div class="refsect2"> | |
152 | <a name="GUPnPFeature--object-ids"></a><h3>The <code class="literal">"object-ids"</code> property</h3> | |
153 | <pre class="programlisting"> "object-ids" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre> | |
154 | <p> | |
155 | The object IDs related to this feature. | |
156 | </p> | |
157 | <p>Default value: NULL</p> | |
158 | </div> | |
159 | <hr> | |
160 | <div class="refsect2"> | |
161 | <a name="GUPnPFeature--version"></a><h3>The <code class="literal">"version"</code> property</h3> | |
162 | <pre class="programlisting"> "version" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre> | |
163 | <p> | |
164 | The version of this feature. | |
165 | </p> | |
166 | <p>Default value: NULL</p> | |
167 | </div> | |
168 | </div> | |
169 | </div> | |
170 | <div class="footer"> | |
171 | <hr> | |
172 | Generated by GTK-Doc V1.18.1</div> | |
173 | </body> | |
174 | </html>⏎ |
0 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
1 | <html> | |
2 | <head> | |
3 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
4 | <title>GUPnPFeatureListParser</title> | |
5 | <meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> | |
6 | <link rel="home" href="index.html" title="GUPnP A/V Reference Manual"> | |
7 | <link rel="up" href="ch01.html" title="GUPnP A/V"> | |
8 | <link rel="prev" href="GUPnPFeature.html" title="GUPnPFeature"> | |
9 | <link rel="next" href="ch02.html" title="Error Codes"> | |
10 | <meta name="generator" content="GTK-Doc V1.18.1 (XML mode)"> | |
11 | <link rel="stylesheet" href="style.css" type="text/css"> | |
12 | </head> | |
13 | <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> | |
14 | <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"> | |
15 | <tr valign="middle"> | |
16 | <td><a accesskey="p" href="GUPnPFeature.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> | |
17 | <td><a accesskey="u" href="ch01.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td> | |
18 | <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> | |
19 | <th width="100%" align="center">GUPnP A/V Reference Manual</th> | |
20 | <td><a accesskey="n" href="ch02.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> | |
21 | </tr> | |
22 | <tr><td colspan="5" class="shortcuts"> | |
23 | <a href="#GUPnPFeatureListParser.synopsis" class="shortcut">Top</a> | |
24 | | | |
25 | <a href="#GUPnPFeatureListParser.description" class="shortcut">Description</a> | |
26 | | | |
27 | <a href="#GUPnPFeatureListParser.object-hierarchy" class="shortcut">Object Hierarchy</a> | |
28 | </td></tr> | |
29 | </table> | |
30 | <div class="refentry"> | |
31 | <a name="GUPnPFeatureListParser"></a><div class="titlepage"></div> | |
32 | <div class="refnamediv"><table width="100%"><tr> | |
33 | <td valign="top"> | |
34 | <h2><span class="refentrytitle"><a name="GUPnPFeatureListParser.top_of_page"></a>GUPnPFeatureListParser</span></h2> | |
35 | <p>GUPnPFeatureListParser — FeatureList state variable XML parser</p> | |
36 | </td> | |
37 | <td valign="top" align="right"></td> | |
38 | </tr></table></div> | |
39 | <div class="refsynopsisdiv"> | |
40 | <a name="GUPnPFeatureListParser.synopsis"></a><h2>Synopsis</h2> | |
41 | <pre class="synopsis"> <a class="link" href="GUPnPFeatureListParser.html#GUPnPFeatureListParser-struct" title="GUPnPFeatureListParser">GUPnPFeatureListParser</a>; | |
42 | <a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="returnvalue">GUPnPFeatureListParser</span></a> * <a class="link" href="GUPnPFeatureListParser.html#gupnp-feature-list-parser-new" title="gupnp_feature_list_parser_new ()">gupnp_feature_list_parser_new</a> (<em class="parameter"><code><span class="type">void</span></code></em>); | |
43 | <a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> * <a class="link" href="GUPnPFeatureListParser.html#gupnp-feature-list-parser-parse-text" title="gupnp_feature_list_parser_parse_text ()">gupnp_feature_list_parser_parse_text</a> | |
44 | (<em class="parameter"><code><a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="type">GUPnPFeatureListParser</span></a> *parser</code></em>, | |
45 | <em class="parameter"><code>const <span class="type">char</span> *text</code></em>, | |
46 | <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>); | |
47 | </pre> | |
48 | </div> | |
49 | <div class="refsect1"> | |
50 | <a name="GUPnPFeatureListParser.object-hierarchy"></a><h2>Object Hierarchy</h2> | |
51 | <pre class="synopsis"> | |
52 | <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a> | |
53 | +----GUPnPFeatureListParser | |
54 | </pre> | |
55 | </div> | |
56 | <div class="refsect1"> | |
57 | <a name="GUPnPFeatureListParser.description"></a><h2>Description</h2> | |
58 | <p> | |
59 | <a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="type">GUPnPFeatureListParser</span></a> parses XML strings from ContentDirectory | |
60 | FeatureList state variable. | |
61 | </p> | |
62 | </div> | |
63 | <div class="refsect1"> | |
64 | <a name="GUPnPFeatureListParser.details"></a><h2>Details</h2> | |
65 | <div class="refsect2"> | |
66 | <a name="GUPnPFeatureListParser-struct"></a><h3>GUPnPFeatureListParser</h3> | |
67 | <pre class="programlisting">typedef struct _GUPnPFeatureListParser GUPnPFeatureListParser;</pre> | |
68 | </div> | |
69 | <hr> | |
70 | <div class="refsect2"> | |
71 | <a name="gupnp-feature-list-parser-new"></a><h3>gupnp_feature_list_parser_new ()</h3> | |
72 | <pre class="programlisting"><a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="returnvalue">GUPnPFeatureListParser</span></a> * gupnp_feature_list_parser_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre> | |
73 | <div class="variablelist"><table border="0"> | |
74 | <col align="left" valign="top"> | |
75 | <tbody><tr> | |
76 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> | |
77 | <td>A new <a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="type">GUPnPFeatureListParser</span></a> object.</td> | |
78 | </tr></tbody> | |
79 | </table></div> | |
80 | </div> | |
81 | <hr> | |
82 | <div class="refsect2"> | |
83 | <a name="gupnp-feature-list-parser-parse-text"></a><h3>gupnp_feature_list_parser_parse_text ()</h3> | |
84 | <pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> * gupnp_feature_list_parser_parse_text | |
85 | (<em class="parameter"><code><a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="type">GUPnPFeatureListParser</span></a> *parser</code></em>, | |
86 | <em class="parameter"><code>const <span class="type">char</span> *text</code></em>, | |
87 | <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> | |
88 | <p> | |
89 | Parses <em class="parameter"><code>text</code></em> and returns the list of available features. | |
90 | If an error occured <em class="parameter"><code>error</code></em> will be set. | |
91 | </p> | |
92 | <div class="variablelist"><table border="0"> | |
93 | <col align="left" valign="top"> | |
94 | <tbody> | |
95 | <tr> | |
96 | <td><p><span class="term"><em class="parameter"><code>parser</code></em> :</span></p></td> | |
97 | <td>A <a class="link" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"><span class="type">GUPnPFeatureListParser</span></a> | |
98 | </td> | |
99 | </tr> | |
100 | <tr> | |
101 | <td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td> | |
102 | <td>The feature list string to be parsed</td> | |
103 | </tr> | |
104 | <tr> | |
105 | <td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td> | |
106 | <td>The location where to store the error information if any, or NULL</td> | |
107 | </tr> | |
108 | <tr> | |
109 | <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> | |
110 | <td>The list of | |
111 | features or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if an error occured. <span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> GUPnPFeature]</span> | |
112 | </td> | |
113 | </tr> | |
114 | </tbody> | |
115 | </table></div> | |
116 | </div> | |
117 | </div> | |
118 | </div> | |
119 | <div class="footer"> | |
120 | <hr> | |
121 | Generated by GTK-Doc V1.18.1</div> | |
122 | </body> | |
123 | </html>⏎ |
6 | 6 | <link rel="home" href="index.html" title="GUPnP A/V Reference Manual"> |
7 | 7 | <link rel="up" href="ch01.html" title="GUPnP A/V"> |
8 | 8 | <link rel="prev" href="GUPnPSearchCriteriaParser.html" title="GUPnPSearchCriteriaParser"> |
9 | <link rel="next" href="ch02.html" title="Error Codes"> | |
9 | <link rel="next" href="GUPnPFeature.html" title="GUPnPFeature"> | |
10 | 10 | <meta name="generator" content="GTK-Doc V1.18.1 (XML mode)"> |
11 | 11 | <link rel="stylesheet" href="style.css" type="text/css"> |
12 | 12 | </head> |
17 | 17 | <td><a accesskey="u" href="ch01.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td> |
18 | 18 | <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> |
19 | 19 | <th width="100%" align="center">GUPnP A/V Reference Manual</th> |
20 | <td><a accesskey="n" href="ch02.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> | |
20 | <td><a accesskey="n" href="GUPnPFeature.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> | |
21 | 21 | </tr> |
22 | 22 | <tr><td colspan="5" class="shortcuts"> |
23 | 23 | <a href="#GUPnPProtocolInfo.synopsis" class="shortcut">Top</a> |
20 | 20 | </tr></table> |
21 | 21 | <div class="chapter"> |
22 | 22 | <div class="titlepage"><div><div><h2 class="title"> |
23 | <a name="id349940"></a>GUPnP A/V</h2></div></div></div> | |
23 | <a name="id461135"></a>GUPnP A/V</h2></div></div></div> | |
24 | 24 | <div class="toc"><dl> |
25 | 25 | <dt> |
26 | 26 | <span class="refentrytitle"><a href="GUPnPDIDLLiteParser.html">GUPnPDIDLLiteParser</a></span><span class="refpurpose"> — A/V DIDL-Lite XML parser</span> |
55 | 55 | <dt> |
56 | 56 | <span class="refentrytitle"><a href="GUPnPProtocolInfo.html">GUPnPProtocolInfo</a></span><span class="refpurpose"> — UPnP AV ProtocolInfo</span> |
57 | 57 | </dt> |
58 | <dt> | |
59 | <span class="refentrytitle"><a href="GUPnPFeature.html">GUPnPFeature</a></span><span class="refpurpose"> — ContentDirectory feature</span> | |
60 | </dt> | |
61 | <dt> | |
62 | <span class="refentrytitle"><a href="GUPnPFeatureListParser.html">GUPnPFeatureListParser</a></span><span class="refpurpose"> — FeatureList state variable XML parser</span> | |
63 | </dt> | |
58 | 64 | </dl></div> |
59 | 65 | </div> |
60 | 66 | <div class="footer"> |
5 | 5 | <meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> |
6 | 6 | <link rel="home" href="index.html" title="GUPnP A/V Reference Manual"> |
7 | 7 | <link rel="up" href="index.html" title="GUPnP A/V Reference Manual"> |
8 | <link rel="prev" href="GUPnPProtocolInfo.html" title="GUPnPProtocolInfo"> | |
8 | <link rel="prev" href="GUPnPFeatureListParser.html" title="GUPnPFeatureListParser"> | |
9 | 9 | <link rel="next" href="gupnp-av-Error-codes.html" title="Error codes"> |
10 | 10 | <meta name="generator" content="GTK-Doc V1.18.1 (XML mode)"> |
11 | 11 | <link rel="stylesheet" href="style.css" type="text/css"> |
12 | 12 | </head> |
13 | 13 | <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> |
14 | 14 | <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle"> |
15 | <td><a accesskey="p" href="GUPnPProtocolInfo.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> | |
15 | <td><a accesskey="p" href="GUPnPFeatureListParser.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> | |
16 | 16 | <td> </td> |
17 | 17 | <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> |
18 | 18 | <th width="100%" align="center">GUPnP A/V Reference Manual</th> |
20 | 20 | </tr></table> |
21 | 21 | <div class="chapter"> |
22 | 22 | <div class="titlepage"><div><div><h2 class="title"> |
23 | <a name="id375947"></a>Error Codes</h2></div></div></div> | |
23 | <a name="id429914"></a>Error Codes</h2></div></div></div> | |
24 | 24 | <div class="toc"><dl><dt> |
25 | 25 | <span class="refentrytitle"><a href="gupnp-av-Error-codes.html">Error codes</a></span><span class="refpurpose"> — Error domains and codes.</span> |
26 | 26 | </dt></dl></div> |
13 | 13 | <sub name="GUPnPLastChangeParser" link="GUPnPLastChangeParser.html"/> |
14 | 14 | <sub name="GUPnPSearchCriteriaParser" link="GUPnPSearchCriteriaParser.html"/> |
15 | 15 | <sub name="GUPnPProtocolInfo" link="GUPnPProtocolInfo.html"/> |
16 | <sub name="GUPnPFeature" link="GUPnPFeature.html"/> | |
17 | <sub name="GUPnPFeatureListParser" link="GUPnPFeatureListParser.html"/> | |
16 | 18 | </sub> |
17 | 19 | <sub name="Error Codes" link="ch02.html"> |
18 | 20 | <sub name="Error codes" link="gupnp-av-Error-codes.html"/> |
37 | 39 | <keyword type="function" name="gupnp_didl_lite_object_get_parent_id ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-parent-id"/> |
38 | 40 | <keyword type="function" name="gupnp_didl_lite_object_get_restricted ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-restricted"/> |
39 | 41 | <keyword type="function" name="gupnp_didl_lite_object_get_title ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-title"/> |
40 | <keyword type="function" name="gupnp_didl_lite_object_get_creator ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-creator" deprecated="0.5.3: Use #gupnp_didl_lite_object_get_creators instead."/> | |
42 | <keyword type="function" name="gupnp_didl_lite_object_get_creator ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-creator"/> | |
41 | 43 | <keyword type="function" name="gupnp_didl_lite_object_get_artist ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-artist" deprecated="0.5.3: Use #gupnp_didl_lite_object_get_artists instead."/> |
42 | 44 | <keyword type="function" name="gupnp_didl_lite_object_get_author ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-author" deprecated="0.5.3: Use #gupnp_didl_lite_object_get_authors instead."/> |
43 | 45 | <keyword type="function" name="gupnp_didl_lite_object_get_creators ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-get-creators"/> |
62 | 64 | <keyword type="function" name="gupnp_didl_lite_object_set_parent_id ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-parent-id"/> |
63 | 65 | <keyword type="function" name="gupnp_didl_lite_object_set_restricted ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-restricted"/> |
64 | 66 | <keyword type="function" name="gupnp_didl_lite_object_set_title ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-title"/> |
65 | <keyword type="function" name="gupnp_didl_lite_object_set_creator ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-creator" deprecated="0.5.3: Use #gupnp_didl_lite_object_add_creator instead."/> | |
67 | <keyword type="function" name="gupnp_didl_lite_object_set_creator ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-creator"/> | |
66 | 68 | <keyword type="function" name="gupnp_didl_lite_object_set_artist ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-artist" deprecated="0.5.3: Use #gupnp_didl_lite_object_add_artist instead."/> |
67 | 69 | <keyword type="function" name="gupnp_didl_lite_object_set_author ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-set-author" deprecated="0.5.3: Use #gupnp_didl_lite_object_add_author instead."/> |
68 | 70 | <keyword type="function" name="gupnp_didl_lite_object_add_creator ()" link="GUPnPDIDLLiteObject.html#gupnp-didl-lite-object-add-creator"/> |
249 | 251 | <keyword type="property" name="The "network" property" link="GUPnPProtocolInfo.html#GUPnPProtocolInfo--network"/> |
250 | 252 | <keyword type="property" name="The "play-speeds" property" link="GUPnPProtocolInfo.html#GUPnPProtocolInfo--play-speeds"/> |
251 | 253 | <keyword type="property" name="The "protocol" property" link="GUPnPProtocolInfo.html#GUPnPProtocolInfo--protocol"/> |
254 | <keyword type="struct" name="GUPnPFeature" link="GUPnPFeature.html#GUPnPFeature-struct"/> | |
255 | <keyword type="function" name="gupnp_feature_get_name ()" link="GUPnPFeature.html#gupnp-feature-get-name"/> | |
256 | <keyword type="function" name="gupnp_feature_get_version ()" link="GUPnPFeature.html#gupnp-feature-get-version"/> | |
257 | <keyword type="function" name="gupnp_feature_get_object_ids ()" link="GUPnPFeature.html#gupnp-feature-get-object-ids"/> | |
258 | <keyword type="property" name="The "name" property" link="GUPnPFeature.html#GUPnPFeature--name"/> | |
259 | <keyword type="property" name="The "object-ids" property" link="GUPnPFeature.html#GUPnPFeature--object-ids"/> | |
260 | <keyword type="property" name="The "version" property" link="GUPnPFeature.html#GUPnPFeature--version"/> | |
261 | <keyword type="struct" name="GUPnPFeatureListParser" link="GUPnPFeatureListParser.html#GUPnPFeatureListParser-struct"/> | |
262 | <keyword type="function" name="gupnp_feature_list_parser_new ()" link="GUPnPFeatureListParser.html#gupnp-feature-list-parser-new"/> | |
263 | <keyword type="function" name="gupnp_feature_list_parser_parse_text ()" link="GUPnPFeatureListParser.html#gupnp-feature-list-parser-parse-text"/> | |
252 | 264 | <keyword type="macro" name="GUPNP_PROTOCOL_ERROR" link="gupnp-av-Error-codes.html#GUPNP-PROTOCOL-ERROR:CAPS"/> |
253 | 265 | <keyword type="macro" name="GUPNP_SEARCH_CRITERIA_PARSER_ERROR" link="gupnp-av-Error-codes.html#GUPNP-SEARCH-CRITERIA-PARSER-ERROR:CAPS"/> |
254 | 266 | <keyword type="enum" name="enum GUPnPProtocolError" link="gupnp-av-Error-codes.html#GUPnPProtocolError"/> |
13 | 13 | <div class="titlepage"> |
14 | 14 | <div> |
15 | 15 | <div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">GUPnP A/V Reference Manual</p></th></tr></table></div> |
16 | <div><p class="releaseinfo">Version 0.11.0 | |
16 | <div><p class="releaseinfo">Version 0.11.1 | |
17 | 17 | </p></div> |
18 | 18 | <div><p class="copyright">Copyright © 2007,2008 OpenedHand LTD</p></div> |
19 | 19 | <div><p class="copyright">Copyright © 2007,2008 Zeeshan Ali <zeenix@gmail.com></p></div> |
20 | 20 | <div><p class="copyright">Copyright © 2009,2010 Nokia Corporation</p></div> |
21 | 21 | <div><div class="legalnotice"> |
22 | <a name="id347432"></a><p> | |
22 | <a name="id433224"></a><p> | |
23 | 23 | Permission is granted to copy, distribute and/or modify this |
24 | 24 | document under the terms of the <em class="citetitle">GNU Free |
25 | 25 | Documentation License</em>, Version 1.1 or any later |
79 | 79 | <dt> |
80 | 80 | <span class="refentrytitle"><a href="GUPnPProtocolInfo.html">GUPnPProtocolInfo</a></span><span class="refpurpose"> — UPnP AV ProtocolInfo</span> |
81 | 81 | </dt> |
82 | <dt> | |
83 | <span class="refentrytitle"><a href="GUPnPFeature.html">GUPnPFeature</a></span><span class="refpurpose"> — ContentDirectory feature</span> | |
84 | </dt> | |
85 | <dt> | |
86 | <span class="refentrytitle"><a href="GUPnPFeatureListParser.html">GUPnPFeatureListParser</a></span><span class="refpurpose"> — FeatureList state variable XML parser</span> | |
87 | </dt> | |
82 | 88 | </dl></dd> |
83 | 89 | <dt><span class="chapter"><a href="ch02.html">Error Codes</a></span></dt> |
84 | 90 | <dd><dl><dt> |
336 | 336 | <ANCHOR id="GUPnPProtocolInfo--network" href="gupnp-av/GUPnPProtocolInfo.html#GUPnPProtocolInfo--network"> |
337 | 337 | <ANCHOR id="GUPnPProtocolInfo--play-speeds" href="gupnp-av/GUPnPProtocolInfo.html#GUPnPProtocolInfo--play-speeds"> |
338 | 338 | <ANCHOR id="GUPnPProtocolInfo--protocol" href="gupnp-av/GUPnPProtocolInfo.html#GUPnPProtocolInfo--protocol"> |
339 | <ANCHOR id="GUPnPFeature" href="gupnp-av/GUPnPFeature.html"> | |
340 | <ANCHOR id="GUPnPFeature.synopsis" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.synopsis"> | |
341 | <ANCHOR id="GUPnPFeature.object-hierarchy" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.object-hierarchy"> | |
342 | <ANCHOR id="GUPnPFeature.properties" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.properties"> | |
343 | <ANCHOR id="GUPnPFeature.description" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.description"> | |
344 | <ANCHOR id="GUPnPFeature.details" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.details"> | |
345 | <ANCHOR id="GUPnPFeature-struct" href="gupnp-av/GUPnPFeature.html#GUPnPFeature-struct"> | |
346 | <ANCHOR id="gupnp-feature-get-name" href="gupnp-av/GUPnPFeature.html#gupnp-feature-get-name"> | |
347 | <ANCHOR id="gupnp-feature-get-version" href="gupnp-av/GUPnPFeature.html#gupnp-feature-get-version"> | |
348 | <ANCHOR id="gupnp-feature-get-object-ids" href="gupnp-av/GUPnPFeature.html#gupnp-feature-get-object-ids"> | |
349 | <ANCHOR id="GUPnPFeature.property-details" href="gupnp-av/GUPnPFeature.html#GUPnPFeature.property-details"> | |
350 | <ANCHOR id="GUPnPFeature--name" href="gupnp-av/GUPnPFeature.html#GUPnPFeature--name"> | |
351 | <ANCHOR id="GUPnPFeature--object-ids" href="gupnp-av/GUPnPFeature.html#GUPnPFeature--object-ids"> | |
352 | <ANCHOR id="GUPnPFeature--version" href="gupnp-av/GUPnPFeature.html#GUPnPFeature--version"> | |
353 | <ANCHOR id="GUPnPFeatureListParser" href="gupnp-av/GUPnPFeatureListParser.html"> | |
354 | <ANCHOR id="GUPnPFeatureListParser.synopsis" href="gupnp-av/GUPnPFeatureListParser.html#GUPnPFeatureListParser.synopsis"> | |
355 | <ANCHOR id="GUPnPFeatureListParser.object-hierarchy" href="gupnp-av/GUPnPFeatureListParser.html#GUPnPFeatureListParser.object-hierarchy"> | |
356 | <ANCHOR id="GUPnPFeatureListParser.description" href="gupnp-av/GUPnPFeatureListParser.html#GUPnPFeatureListParser.description"> | |
357 | <ANCHOR id="GUPnPFeatureListParser.details" href="gupnp-av/GUPnPFeatureListParser.html#GUPnPFeatureListParser.details"> | |
358 | <ANCHOR id="GUPnPFeatureListParser-struct" href="gupnp-av/GUPnPFeatureListParser.html#GUPnPFeatureListParser-struct"> | |
359 | <ANCHOR id="gupnp-feature-list-parser-new" href="gupnp-av/GUPnPFeatureListParser.html#gupnp-feature-list-parser-new"> | |
360 | <ANCHOR id="gupnp-feature-list-parser-parse-text" href="gupnp-av/GUPnPFeatureListParser.html#gupnp-feature-list-parser-parse-text"> | |
339 | 361 | <ANCHOR id="gupnp-av-Error-codes" href="gupnp-av/gupnp-av-Error-codes.html"> |
340 | 362 | <ANCHOR id="gupnp-av-Error-codes.synopsis" href="gupnp-av/gupnp-av-Error-codes.html#gupnp-av-Error-codes.synopsis"> |
341 | 363 | <ANCHOR id="gupnp-av-Error-codes.description" href="gupnp-av/gupnp-av-Error-codes.html#gupnp-av-Error-codes.description"> |
26 | 26 | gupnp-protocol-info.h \ |
27 | 27 | gupnp-search-criteria-parser.h \ |
28 | 28 | gupnp-last-change-parser.h \ |
29 | gupnp-feature.h \ | |
30 | gupnp-feature-list-parser.h \ | |
29 | 31 | gupnp-dlna.h \ |
30 | 32 | gupnp-av-error.h \ |
31 | 33 | gupnp-av.h |
60 | 62 | gupnp-protocol-info.c \ |
61 | 63 | gupnp-search-criteria-parser.c \ |
62 | 64 | gupnp-last-change-parser.c \ |
65 | gupnp-feature.c \ | |
66 | gupnp-feature-list-parser.c \ | |
63 | 67 | gupnp-dlna.c \ |
64 | 68 | gupnp-av-error.c \ |
65 | 69 | xml-util.c \ |
93 | 97 | $(top_srcdir)/libgupnp-av/gupnp-protocol-info.c \ |
94 | 98 | $(top_srcdir)/libgupnp-av/gupnp-search-criteria-parser.c \ |
95 | 99 | $(top_srcdir)/libgupnp-av/gupnp-last-change-parser.c \ |
100 | $(top_srcdir)/libgupnp-av/gupnp-feature.c \ | |
101 | $(top_srcdir)/libgupnp-av/gupnp-feature-list-parser.c \ | |
96 | 102 | $(top_srcdir)/libgupnp-av/gupnp-dlna.c \ |
97 | 103 | $(top_srcdir)/libgupnp-av/gupnp-av-error.c |
98 | 104 | |
105 | 111 | GUPnPAV_1_0_gir_FILES = $(introspection_sources) |
106 | 112 | INTROSPECTION_GIRS += GUPnPAV-1.0.gir |
107 | 113 | |
108 | girdir = $(INTROSPECTION_GIRDIR) | |
114 | girdir = $(datadir)/gir-1.0 | |
109 | 115 | gir_DATA = $(INTROSPECTION_GIRS) |
110 | 116 | |
111 | typelibdir = $(INTROSPECTION_TYPELIBDIR) | |
117 | typelibdir = $(libdir)/girepository-1.0 | |
112 | 118 | typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib) |
113 | 119 | endif |
114 | 120 |
44 | 44 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
45 | 45 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
46 | 46 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
47 | $(top_srcdir)/configure.ac | |
47 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
48 | 48 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
49 | 49 | $(ACLOCAL_M4) |
50 | 50 | mkinstalldirs = $(install_sh) -d |
90 | 90 | gupnp-didl-lite-resource.lo gupnp-didl-lite-descriptor.lo \ |
91 | 91 | gupnp-didl-lite-contributor.lo gupnp-didl-lite-writer.lo \ |
92 | 92 | gupnp-protocol-info.lo gupnp-search-criteria-parser.lo \ |
93 | gupnp-last-change-parser.lo gupnp-dlna.lo gupnp-av-error.lo \ | |
93 | gupnp-last-change-parser.lo gupnp-feature.lo \ | |
94 | gupnp-feature-list-parser.lo gupnp-dlna.lo gupnp-av-error.lo \ | |
94 | 95 | xml-util.lo gvalue-util.lo $(am__objects_1) |
95 | 96 | libgupnp_av_1_0_la_OBJECTS = $(am_libgupnp_av_1_0_la_OBJECTS) |
96 | 97 | AM_V_lt = $(am__v_lt_@AM_V@) |
295 | 296 | gupnp-protocol-info.h \ |
296 | 297 | gupnp-search-criteria-parser.h \ |
297 | 298 | gupnp-last-change-parser.h \ |
299 | gupnp-feature.h \ | |
300 | gupnp-feature-list-parser.h \ | |
298 | 301 | gupnp-dlna.h \ |
299 | 302 | gupnp-av-error.h \ |
300 | 303 | gupnp-av.h |
318 | 321 | gupnp-protocol-info.c \ |
319 | 322 | gupnp-search-criteria-parser.c \ |
320 | 323 | gupnp-last-change-parser.c \ |
324 | gupnp-feature.c \ | |
325 | gupnp-feature-list-parser.c \ | |
321 | 326 | gupnp-dlna.c \ |
322 | 327 | gupnp-av-error.c \ |
323 | 328 | xml-util.c \ |
346 | 351 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-protocol-info.c \ |
347 | 352 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-search-criteria-parser.c \ |
348 | 353 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-last-change-parser.c \ |
354 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-feature.c \ | |
355 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-feature-list-parser.c \ | |
349 | 356 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-dlna.c \ |
350 | 357 | @HAVE_INTROSPECTION_TRUE@ $(top_srcdir)/libgupnp-av/gupnp-av-error.c |
351 | 358 | |
355 | 362 | @HAVE_INTROSPECTION_TRUE@GUPnPAV_1_0_gir_NAMESPACE = GUPnPAV |
356 | 363 | @HAVE_INTROSPECTION_TRUE@GUPnPAV_1_0_gir_SCANNERFLAGS = --identifier-prefix=GUPnP --symbol-prefix=gupnp --pkg-export=gupnp-av-1.0 |
357 | 364 | @HAVE_INTROSPECTION_TRUE@GUPnPAV_1_0_gir_FILES = $(introspection_sources) |
358 | @HAVE_INTROSPECTION_TRUE@girdir = $(INTROSPECTION_GIRDIR) | |
365 | @HAVE_INTROSPECTION_TRUE@girdir = $(datadir)/gir-1.0 | |
359 | 366 | @HAVE_INTROSPECTION_TRUE@gir_DATA = $(INTROSPECTION_GIRS) |
360 | @HAVE_INTROSPECTION_TRUE@typelibdir = $(INTROSPECTION_TYPELIBDIR) | |
367 | @HAVE_INTROSPECTION_TRUE@typelibdir = $(libdir)/girepository-1.0 | |
361 | 368 | @HAVE_INTROSPECTION_TRUE@typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib) |
362 | 369 | CLEANFILES = $(BUILT_SOURCES) $(gir_DATA) $(typelib_DATA) |
363 | 370 | DISTCLEANFILES = $(BUILT_SOURCES) |
449 | 456 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-didl-lite-resource.Plo@am__quote@ |
450 | 457 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-didl-lite-writer.Plo@am__quote@ |
451 | 458 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-dlna.Plo@am__quote@ |
459 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-feature-list-parser.Plo@am__quote@ | |
460 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-feature.Plo@am__quote@ | |
452 | 461 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-last-change-parser.Plo@am__quote@ |
453 | 462 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-protocol-info.Plo@am__quote@ |
454 | 463 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gupnp-search-criteria-parser.Plo@am__quote@ |
31 | 31 | #include "gupnp-protocol-info.h" |
32 | 32 | #include "gupnp-search-criteria-parser.h" |
33 | 33 | #include "gupnp-last-change-parser.h" |
34 | #include "gupnp-feature.h" | |
35 | #include "gupnp-feature-list-parser.h" | |
34 | 36 | #include "gupnp-dlna.h" |
35 | 37 |
568 | 568 | * |
569 | 569 | * The creator of this object. |
570 | 570 | * |
571 | * Deprecated: 0.5.3: Use #gupnp_didl_lite_object_get_creators and | |
572 | * #gupnp_didl_lite_object_add_creator instead since unlike this | |
573 | * property, they are capable of dealing with multiple creator nodes. | |
574 | 571 | **/ |
575 | 572 | g_object_class_install_property |
576 | 573 | (object_class, |
841 | 838 | g_list_free (contributors); |
842 | 839 | |
843 | 840 | return ret; |
841 | } | |
842 | ||
843 | static char * | |
844 | get_contributors_xml_string_by_name (GUPnPDIDLLiteObject *object, | |
845 | const char *name) | |
846 | { | |
847 | GList *contributors = NULL; | |
848 | char *ret = NULL; | |
849 | GList *l; | |
850 | xmlBuffer *buffer; | |
851 | ||
852 | contributors = gupnp_didl_lite_object_get_properties (object, name); | |
853 | if (contributors == NULL) | |
854 | return NULL; | |
855 | ||
856 | buffer = xmlBufferCreate (); | |
857 | ||
858 | for (l = contributors; l; l = l->next) { | |
859 | xmlNode *node; | |
860 | ||
861 | node = (xmlNode *) l->data; | |
862 | if (!node->children) | |
863 | continue; | |
864 | ||
865 | xmlNodeDump (buffer, | |
866 | object->priv->xml_doc->doc, | |
867 | node, | |
868 | 0, | |
869 | 0); | |
870 | } | |
871 | ||
872 | ret = g_strndup ((char *) xmlBufferContent (buffer), | |
873 | xmlBufferLength (buffer)); | |
874 | xmlBufferFree (buffer); | |
875 | ||
876 | g_list_free (contributors); | |
877 | ||
878 | return ret; | |
879 | } | |
880 | ||
881 | static void | |
882 | unset_contributors_by_name (GUPnPDIDLLiteObject *object, const char *name) | |
883 | { | |
884 | GList *contributors = NULL; | |
885 | GList *l; | |
886 | ||
887 | contributors = gupnp_didl_lite_object_get_properties (object, name); | |
888 | if (contributors == NULL) | |
889 | return; | |
890 | ||
891 | for (l = contributors; l; l = l->next) { | |
892 | xmlNode *node; | |
893 | ||
894 | node = (xmlNode *) l->data; | |
895 | if (!node->children) | |
896 | continue; | |
897 | ||
898 | xmlUnlinkNode (node); | |
899 | xmlFreeNode (node); | |
900 | } | |
901 | ||
902 | g_list_free (contributors); | |
903 | ||
904 | return; | |
844 | 905 | } |
845 | 906 | |
846 | 907 | /** |
1084 | 1145 | * Get the creator of the @object. |
1085 | 1146 | * |
1086 | 1147 | * Return value: The creator of the @object, or %NULL. |
1087 | * | |
1088 | * Deprecated: 0.5.3: Use #gupnp_didl_lite_object_get_creators instead. | |
1089 | 1148 | **/ |
1090 | 1149 | const char * |
1091 | 1150 | gupnp_didl_lite_object_get_creator (GUPnPDIDLLiteObject *object) |
1659 | 1718 | * @creator: The creator |
1660 | 1719 | * |
1661 | 1720 | * Set the creator of the @object to @creator. |
1662 | * | |
1663 | * Deprecated: 0.5.3: Use #gupnp_didl_lite_object_add_creator instead. | |
1664 | 1721 | **/ |
1665 | 1722 | void |
1666 | 1723 | gupnp_didl_lite_object_set_creator (GUPnPDIDLLiteObject *object, |
2024 | 2081 | xml_util_set_child (object->priv->xml_node, |
2025 | 2082 | object->priv->upnp_ns, |
2026 | 2083 | object->priv->xml_doc->doc, |
2027 | "class", | |
2084 | "objectUpdateID", | |
2028 | 2085 | str); |
2029 | 2086 | g_free (str); |
2030 | 2087 | |
2096 | 2153 | return gupnp_didl_lite_descriptor_new_from_xml (desc_node, |
2097 | 2154 | object->priv->xml_doc); |
2098 | 2155 | } |
2156 | ||
2157 | /** | |
2158 | * gupnp_didl_lite_object_get_title_xml_string: | |
2159 | * @object: A #GUPnPDIDLLiteObject | |
2160 | * | |
2161 | * Creates a string representation of the DIDL-Lite XML fragment related to the | |
2162 | * object title. | |
2163 | * | |
2164 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2165 | **/ | |
2166 | char * | |
2167 | gupnp_didl_lite_object_get_title_xml_string (GUPnPDIDLLiteObject *object) | |
2168 | { | |
2169 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2170 | ||
2171 | return xml_util_get_child_string (object->priv->xml_node, | |
2172 | object->priv->xml_doc->doc, | |
2173 | "title"); | |
2174 | } | |
2175 | ||
2176 | /** | |
2177 | * gupnp_didl_lite_object_get_date_xml_string: | |
2178 | * @object: A #GUPnPDIDLLiteObject | |
2179 | * | |
2180 | * Creates a string representation of the DIDL-Lite XML fragment related to the | |
2181 | * object date. | |
2182 | * | |
2183 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2184 | **/ | |
2185 | char * | |
2186 | gupnp_didl_lite_object_get_date_xml_string (GUPnPDIDLLiteObject *object) | |
2187 | { | |
2188 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2189 | ||
2190 | return xml_util_get_child_string (object->priv->xml_node, | |
2191 | object->priv->xml_doc->doc, | |
2192 | "date"); | |
2193 | } | |
2194 | ||
2195 | /** | |
2196 | * gupnp_didl_lite_object_get_upnp_class_xml_string: | |
2197 | * @object: A #GUPnPDIDLLiteObject | |
2198 | * | |
2199 | * Creates a string representation of the DIDL-Lite XML fragment related to the | |
2200 | * object UPnP class. | |
2201 | * | |
2202 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2203 | **/ | |
2204 | char * | |
2205 | gupnp_didl_lite_object_get_upnp_class_xml_string (GUPnPDIDLLiteObject *object) | |
2206 | { | |
2207 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2208 | ||
2209 | return xml_util_get_child_string (object->priv->xml_node, | |
2210 | object->priv->xml_doc->doc, | |
2211 | "class"); | |
2212 | } | |
2213 | ||
2214 | /** | |
2215 | * gupnp_didl_lite_object_get_album_xml_string: | |
2216 | * @object: A #GUPnPDIDLLiteObject | |
2217 | * | |
2218 | * Creates a string representation of the DIDL-Lite XML fragment related to the | |
2219 | * object album. | |
2220 | * | |
2221 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2222 | **/ | |
2223 | char * | |
2224 | gupnp_didl_lite_object_get_album_xml_string (GUPnPDIDLLiteObject *object) | |
2225 | { | |
2226 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2227 | ||
2228 | return xml_util_get_child_string (object->priv->xml_node, | |
2229 | object->priv->xml_doc->doc, | |
2230 | "album"); | |
2231 | } | |
2232 | ||
2233 | /** | |
2234 | * gupnp_didl_lite_object_get_track_number_xml_string: | |
2235 | * @object: A #GUPnPDIDLLiteObject | |
2236 | * | |
2237 | * Creates a string representation of the DIDL-Lite XML fragment related to the | |
2238 | * object track number. | |
2239 | * | |
2240 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2241 | **/ | |
2242 | char * | |
2243 | gupnp_didl_lite_object_get_track_number_xml_string (GUPnPDIDLLiteObject *object) | |
2244 | { | |
2245 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2246 | ||
2247 | return xml_util_get_child_string (object->priv->xml_node, | |
2248 | object->priv->xml_doc->doc, | |
2249 | "originalTrackNumber"); | |
2250 | } | |
2251 | ||
2252 | /** | |
2253 | * gupnp_didl_lite_object_get_artists_xml_string: | |
2254 | * @object: A #GUPnPDIDLLiteObject | |
2255 | * | |
2256 | * Creates a string representation of the DIDL-Lite XML fragments related to the | |
2257 | * object artists. | |
2258 | * | |
2259 | * Return value: A DIDL-Lite XML fragment string, or %NULL. #g_free after usage. | |
2260 | **/ | |
2261 | char * | |
2262 | gupnp_didl_lite_object_get_artists_xml_string (GUPnPDIDLLiteObject *object) | |
2263 | { | |
2264 | g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), NULL); | |
2265 | ||
2266 | return get_contributors_xml_string_by_name (object, "artist"); | |
2267 | } | |
2268 | ||
2269 | /** | |
2270 | * gupnp_didl_lite_object_unset_artists: | |
2271 | * @object: #GUPnPDIDLLiteObject | |
2272 | * | |
2273 | * Unset the artists properties of the @object. | |
2274 | **/ | |
2275 | void | |
2276 | gupnp_didl_lite_object_unset_artists (GUPnPDIDLLiteObject *object) | |
2277 | { | |
2278 | g_return_if_fail (object != NULL); | |
2279 | g_return_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object)); | |
2280 | ||
2281 | unset_contributors_by_name (object, "artist"); | |
2282 | ||
2283 | g_object_notify (G_OBJECT (object), "artist"); | |
2284 | } |
111 | 111 | const char * |
112 | 112 | gupnp_didl_lite_object_get_title (GUPnPDIDLLiteObject *object); |
113 | 113 | |
114 | const char * | |
115 | gupnp_didl_lite_object_get_creator (GUPnPDIDLLiteObject *object); | |
116 | ||
114 | 117 | #ifndef GUPNP_DISABLE_DEPRECATED |
115 | const char * | |
116 | gupnp_didl_lite_object_get_creator (GUPnPDIDLLiteObject *object); | |
117 | ||
118 | 118 | const char * |
119 | 119 | gupnp_didl_lite_object_get_artist (GUPnPDIDLLiteObject *object); |
120 | 120 | |
201 | 201 | gupnp_didl_lite_object_set_title (GUPnPDIDLLiteObject *object, |
202 | 202 | const char *title); |
203 | 203 | |
204 | #ifndef GUPNP_DISABLE_DEPRECATED | |
205 | 204 | void |
206 | 205 | gupnp_didl_lite_object_set_creator (GUPnPDIDLLiteObject *object, |
207 | 206 | const char *creator); |
208 | 207 | |
208 | #ifndef GUPNP_DISABLE_DEPRECATED | |
209 | 209 | void |
210 | 210 | gupnp_didl_lite_object_set_artist (GUPnPDIDLLiteObject *object, |
211 | 211 | const char *artist); |
242 | 242 | const char *album_art); |
243 | 243 | |
244 | 244 | void |
245 | gupnp_didl_lite_object_set_description (GUPnPDIDLLiteObject *object, | |
246 | const char *description); | |
247 | ||
248 | void | |
249 | gupnp_didl_lite_object_set_date (GUPnPDIDLLiteObject *object, | |
250 | const char *date); | |
245 | gupnp_didl_lite_object_set_description (GUPnPDIDLLiteObject *object, | |
246 | const char *description); | |
247 | ||
248 | void | |
249 | gupnp_didl_lite_object_set_date (GUPnPDIDLLiteObject *object, | |
250 | const char *date); | |
251 | 251 | |
252 | 252 | void |
253 | 253 | gupnp_didl_lite_object_set_track_number (GUPnPDIDLLiteObject *object, |
264 | 264 | void |
265 | 265 | gupnp_didl_lite_object_unset_update_id (GUPnPDIDLLiteObject *object); |
266 | 266 | |
267 | char * | |
268 | gupnp_didl_lite_object_get_title_xml_string | |
269 | (GUPnPDIDLLiteObject *object); | |
270 | ||
271 | char * | |
272 | gupnp_didl_lite_object_get_date_xml_string | |
273 | (GUPnPDIDLLiteObject *object); | |
274 | ||
275 | char * | |
276 | gupnp_didl_lite_object_get_upnp_class_xml_string | |
277 | (GUPnPDIDLLiteObject *object); | |
278 | ||
279 | char * | |
280 | gupnp_didl_lite_object_get_album_xml_string | |
281 | (GUPnPDIDLLiteObject *object); | |
282 | ||
283 | char * | |
284 | gupnp_didl_lite_object_get_track_number_xml_string | |
285 | (GUPnPDIDLLiteObject *object); | |
286 | ||
287 | char * | |
288 | gupnp_didl_lite_object_get_artists_xml_string | |
289 | (GUPnPDIDLLiteObject *object); | |
290 | ||
291 | void | |
292 | gupnp_didl_lite_object_unset_artists (GUPnPDIDLLiteObject *object); | |
293 | ||
267 | 294 | G_END_DECLS |
268 | 295 | |
269 | 296 | #endif /* __GUPNP_DIDL_LITE_OBJECT_H__ */ |
0 | /* | |
1 | * Copyright (C) 2012 Intel Corporation. | |
2 | * | |
3 | * Authors: Regis Merlino <regis.merlino@intel.com> | |
4 | * | |
5 | * This library is free software; you can redistribute it and/or | |
6 | * modify it under the terms of the GNU Library General Public | |
7 | * License as published by the Free Software Foundation; either | |
8 | * version 2 of the License, or (at your option) any later version. | |
9 | * | |
10 | * This library is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Library General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Library General Public | |
16 | * License along with this library; if not, write to the | |
17 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 | * Boston, MA 02110-1301, USA. | |
19 | */ | |
20 | ||
21 | /** | |
22 | * SECTION:gupnp-feature-list-parser | |
23 | * @short_description: FeatureList state variable XML parser | |
24 | * | |
25 | * #GUPnPFeatureListParser parses XML strings from ContentDirectory | |
26 | * FeatureList state variable. | |
27 | * | |
28 | */ | |
29 | ||
30 | #include <string.h> | |
31 | #include "gupnp-feature-list-parser.h" | |
32 | #include "gupnp-av.h" | |
33 | #include "xml-util.h" | |
34 | ||
35 | /* GUPnPFeatureListParser */ | |
36 | G_DEFINE_TYPE (GUPnPFeatureListParser, | |
37 | gupnp_feature_list_parser, | |
38 | G_TYPE_OBJECT); | |
39 | ||
40 | static void | |
41 | gupnp_feature_list_parser_init (GUPnPFeatureListParser *parser) | |
42 | { | |
43 | /* Nothing to do here */ | |
44 | } | |
45 | ||
46 | static void | |
47 | gupnp_feature_list_parser_finalize (GObject *object) | |
48 | { | |
49 | GObjectClass *object_class; | |
50 | ||
51 | object_class = G_OBJECT_CLASS (gupnp_feature_list_parser_parent_class); | |
52 | object_class->finalize (object); | |
53 | } | |
54 | ||
55 | static void | |
56 | gupnp_feature_list_parser_class_init (GUPnPFeatureListParserClass *klass) | |
57 | { | |
58 | GObjectClass *object_class; | |
59 | ||
60 | object_class = G_OBJECT_CLASS (klass); | |
61 | ||
62 | object_class->finalize = gupnp_feature_list_parser_finalize; | |
63 | } | |
64 | ||
65 | /** | |
66 | * gupnp_feature_list_parser_new: | |
67 | * | |
68 | * Return value: A new #GUPnPFeatureListParser object. | |
69 | **/ | |
70 | GUPnPFeatureListParser * | |
71 | gupnp_feature_list_parser_new (void) | |
72 | { | |
73 | return g_object_new (GUPNP_TYPE_FEATURE_LIST_PARSER, NULL); | |
74 | } | |
75 | ||
76 | static char * | |
77 | get_feature_object_ids (xmlNode *feature) | |
78 | { | |
79 | xmlNode *element; | |
80 | char *object_ids = NULL; | |
81 | const char *content; | |
82 | ||
83 | object_ids = (char *) g_malloc0(1); | |
84 | ||
85 | for (element = feature->children; element; element = element->next) { | |
86 | gsize new_size; | |
87 | ||
88 | if (g_ascii_strcasecmp ((char *) element->name, | |
89 | "objectIDs") == 0) { | |
90 | content = (const char *) xmlNodeGetContent (element); | |
91 | ||
92 | new_size = strlen (object_ids) + strlen (content) + 1; | |
93 | if (*object_ids) | |
94 | new_size++; | |
95 | ||
96 | object_ids = g_realloc (object_ids, new_size); | |
97 | ||
98 | if (*object_ids) | |
99 | strcat (object_ids, ","); | |
100 | strcat (object_ids, content); | |
101 | } | |
102 | } | |
103 | ||
104 | return object_ids; | |
105 | } | |
106 | ||
107 | /** | |
108 | * gupnp_feature_list_parser_parse_text: | |
109 | * @parser: A #GUPnPFeatureListParser | |
110 | * @text: The feature list string to be parsed | |
111 | * @error: The location where to store the error information if any, or NULL | |
112 | * | |
113 | * Parses @text and returns the list of available features. | |
114 | * If an error occured @error will be set. | |
115 | * | |
116 | * Return value: (transfer full) (element-type GUPnPFeature): The list of | |
117 | * features or %NULL if an error occured. | |
118 | **/ | |
119 | GList * | |
120 | gupnp_feature_list_parser_parse_text (GUPnPFeatureListParser *parser, | |
121 | const char *text, | |
122 | GError **error) | |
123 | { | |
124 | xmlDoc *doc; | |
125 | xmlNode *element; | |
126 | GList *feature_list = NULL; | |
127 | ||
128 | doc = xmlRecoverMemory (text, strlen (text)); | |
129 | if (doc == NULL) { | |
130 | g_set_error (error, | |
131 | GUPNP_XML_ERROR, | |
132 | GUPNP_XML_ERROR_PARSE, | |
133 | "Could not parse FeatureList XML:\n%s", text); | |
134 | ||
135 | return NULL; | |
136 | } | |
137 | ||
138 | /* Get a pointer to root element */ | |
139 | element = xml_util_get_element ((xmlNode *) doc, "Features", NULL); | |
140 | if (element == NULL) { | |
141 | g_set_error (error, | |
142 | GUPNP_XML_ERROR, | |
143 | GUPNP_XML_ERROR_NO_NODE, | |
144 | "No 'Features' node in the XML:\n%s", | |
145 | text); | |
146 | xmlFreeDoc (doc); | |
147 | ||
148 | return NULL; | |
149 | } | |
150 | ||
151 | for (element = element->children; element; element = element->next) { | |
152 | GUPnPFeature *feature; | |
153 | const char *name; | |
154 | const char *version; | |
155 | char *object_ids; | |
156 | ||
157 | if (g_ascii_strcasecmp ((char *) element->name, | |
158 | "Feature") == 0) { | |
159 | name = xml_util_get_attribute_content (element, "name"); | |
160 | version = xml_util_get_attribute_content (element, | |
161 | "version"); | |
162 | if (!name || !version) { | |
163 | g_set_error (error, | |
164 | GUPNP_XML_ERROR, | |
165 | GUPNP_XML_ERROR_INVALID_ATTRIBUTE, | |
166 | "Invalid attributes in 'Feature' " | |
167 | "node in the XML:\n%s", | |
168 | text); | |
169 | ||
170 | xmlFreeDoc (doc); | |
171 | if (feature_list) | |
172 | g_list_free_full (feature_list, | |
173 | g_object_unref); | |
174 | ||
175 | return NULL; | |
176 | } | |
177 | ||
178 | object_ids = get_feature_object_ids (element); | |
179 | ||
180 | feature = g_object_new (GUPNP_TYPE_FEATURE, | |
181 | "name", name, | |
182 | "version", version, | |
183 | "object-ids", object_ids, | |
184 | NULL); | |
185 | ||
186 | feature_list = g_list_append (feature_list, feature); | |
187 | ||
188 | g_free (object_ids); | |
189 | } | |
190 | } | |
191 | ||
192 | xmlFreeDoc (doc); | |
193 | ||
194 | return feature_list; | |
195 | } |
0 | /* | |
1 | * Copyright (C) 2012 Intel Corporation. | |
2 | * | |
3 | * Authors: Regis Merlino <regis.merlino@intel.com> | |
4 | * | |
5 | * This library is free software; you can redistribute it and/or | |
6 | * modify it under the terms of the GNU Library General Public | |
7 | * License as published by the Free Software Foundation; either | |
8 | * version 2 of the License, or (at your option) any later version. | |
9 | * | |
10 | * This library is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Library General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Library General Public | |
16 | * License along with this library; if not, write to the | |
17 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 | * Boston, MA 02110-1301, USA. | |
19 | */ | |
20 | ||
21 | #ifndef __GUPNP_FEATURE_LIST_PARSER_H_ | |
22 | #define __GUPNP_FEATURE_LIST_PARSER_H_ | |
23 | ||
24 | #include <glib-object.h> | |
25 | #include "gupnp-feature.h" | |
26 | ||
27 | G_BEGIN_DECLS | |
28 | ||
29 | GType | |
30 | gupnp_feature_list_parser_get_type (void) G_GNUC_CONST; | |
31 | ||
32 | #define GUPNP_TYPE_FEATURE_LIST_PARSER \ | |
33 | (gupnp_feature_list_parser_get_type ()) | |
34 | #define GUPNP_FEATURE_LIST_PARSER(obj) \ | |
35 | (G_TYPE_CHECK_INSTANCE_CAST ((obj), \ | |
36 | GUPNP_TYPE_FEATURE_LIST_PARSER, \ | |
37 | GUPnPFeatureListParser)) | |
38 | #define GUPNP_FEATURE_LIST_PARSER_CLASS(obj) \ | |
39 | (G_TYPE_CHECK_CLASS_CAST ((obj), \ | |
40 | GUPNP_TYPE_FEATURE_LIST_PARSER, \ | |
41 | GUPnPFeatureListParserClass)) | |
42 | #define GUPNP_IS_FEATURE_LIST_PARSER(obj) \ | |
43 | (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \ | |
44 | GUPNP_TYPE_FEATURE_LIST_PARSER)) | |
45 | #define GUPNP_IS_FEATURE_LIST_PARSER_CLASS(obj) \ | |
46 | (G_TYPE_CHECK_CLASS_TYPE ((obj), \ | |
47 | GUPNP_TYPE_FEATURE_LIST_PARSER)) | |
48 | #define GUPNP_FEATURE_LIST_PARSER_GET_CLASS(obj) \ | |
49 | (G_TYPE_INSTANCE_GET_CLASS ((obj), \ | |
50 | GUPNP_TYPE_FEATURE_LIST_PARSER, \ | |
51 | GUPnPFeatureListParserClass)) | |
52 | ||
53 | typedef struct { | |
54 | GObject parent; | |
55 | } GUPnPFeatureListParser; | |
56 | ||
57 | typedef struct { | |
58 | GObjectClass parent_class; | |
59 | } GUPnPFeatureListParserClass; | |
60 | ||
61 | GUPnPFeatureListParser * | |
62 | gupnp_feature_list_parser_new (void); | |
63 | ||
64 | GList * | |
65 | gupnp_feature_list_parser_parse_text (GUPnPFeatureListParser *parser, | |
66 | const char *text, | |
67 | GError **error); | |
68 | ||
69 | G_END_DECLS | |
70 | ||
71 | #endif /* __GUPNP_FEATURE_LIST_PARSER_H_ */ |
0 | /* | |
1 | * Copyright (C) 2012 Intel Corporation | |
2 | * | |
3 | * Authors: Regis Merlino <regis.merlino@intel.com> | |
4 | * | |
5 | * This library is free software; you can redistribute it and/or | |
6 | * modify it under the terms of the GNU Library General Public | |
7 | * License as published by the Free Software Foundation; either | |
8 | * version 2 of the License, or (at your option) any later version. | |
9 | * | |
10 | * This library is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Library General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Library General Public | |
16 | * License along with this library; if not, write to the | |
17 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 | * Boston, MA 02110-1301, USA. | |
19 | */ | |
20 | ||
21 | /** | |
22 | * SECTION:gupnp-feature | |
23 | * @short_description: ContentDirectory feature | |
24 | * | |
25 | * #GUPnPFeature respresent a Feature element. | |
26 | */ | |
27 | ||
28 | #include "gupnp-feature.h" | |
29 | ||
30 | G_DEFINE_TYPE (GUPnPFeature, | |
31 | gupnp_feature, | |
32 | G_TYPE_OBJECT); | |
33 | ||
34 | struct _GUPnPFeaturePrivate { | |
35 | char *name; | |
36 | char *version; | |
37 | char *object_ids; | |
38 | }; | |
39 | ||
40 | enum { | |
41 | PROP_0, | |
42 | PROP_NAME, | |
43 | PROP_VERSION, | |
44 | PROP_OBJECT_IDS | |
45 | }; | |
46 | ||
47 | static void | |
48 | gupnp_feature_init (GUPnPFeature *object) | |
49 | { | |
50 | object->priv = G_TYPE_INSTANCE_GET_PRIVATE (object, | |
51 | GUPNP_TYPE_FEATURE, | |
52 | GUPnPFeaturePrivate); | |
53 | } | |
54 | ||
55 | static void | |
56 | gupnp_feature_finalize (GObject *object) | |
57 | { | |
58 | GObjectClass *object_class; | |
59 | GUPnPFeaturePrivate *priv; | |
60 | ||
61 | priv = GUPNP_FEATURE (object)->priv; | |
62 | g_free (priv->name); | |
63 | g_free (priv->version); | |
64 | g_free (priv->object_ids); | |
65 | ||
66 | object_class = G_OBJECT_CLASS (gupnp_feature_parent_class); | |
67 | object_class->finalize (object); | |
68 | } | |
69 | ||
70 | static void | |
71 | gupnp_feature_get_property (GObject *object, | |
72 | guint property_id, | |
73 | GValue *value, | |
74 | GParamSpec *pspec) | |
75 | { | |
76 | GUPnPFeature *feature; | |
77 | ||
78 | feature = GUPNP_FEATURE (object); | |
79 | ||
80 | switch (property_id) { | |
81 | case PROP_NAME: | |
82 | g_value_set_string (value, gupnp_feature_get_name (feature)); | |
83 | break; | |
84 | case PROP_VERSION: | |
85 | g_value_set_string (value, gupnp_feature_get_version (feature)); | |
86 | break; | |
87 | case PROP_OBJECT_IDS: | |
88 | g_value_set_string (value, | |
89 | gupnp_feature_get_object_ids (feature)); | |
90 | break; | |
91 | default: | |
92 | G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); | |
93 | break; | |
94 | } | |
95 | } | |
96 | ||
97 | static void | |
98 | gupnp_feature_set_property (GObject *object, | |
99 | guint property_id, | |
100 | const GValue *value, | |
101 | GParamSpec *pspec) | |
102 | { | |
103 | GUPnPFeature *feature; | |
104 | ||
105 | feature = GUPNP_FEATURE (object); | |
106 | ||
107 | switch (property_id) { | |
108 | case PROP_NAME: | |
109 | feature->priv->name = g_value_dup_string (value); | |
110 | break; | |
111 | case PROP_VERSION: | |
112 | feature->priv->version = g_value_dup_string (value); | |
113 | break; | |
114 | case PROP_OBJECT_IDS: | |
115 | feature->priv->object_ids = g_value_dup_string (value); | |
116 | break; | |
117 | default: | |
118 | G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); | |
119 | break; | |
120 | } | |
121 | } | |
122 | ||
123 | static void | |
124 | gupnp_feature_class_init (GUPnPFeatureClass *klass) | |
125 | { | |
126 | GObjectClass *object_class; | |
127 | ||
128 | object_class = G_OBJECT_CLASS (klass); | |
129 | ||
130 | object_class->get_property = gupnp_feature_get_property; | |
131 | object_class->set_property = gupnp_feature_set_property; | |
132 | object_class->finalize = gupnp_feature_finalize; | |
133 | ||
134 | g_type_class_add_private (klass, sizeof (GUPnPFeaturePrivate)); | |
135 | ||
136 | /** | |
137 | * GUPnPFeature:name: | |
138 | * | |
139 | * The name of this feature. | |
140 | **/ | |
141 | g_object_class_install_property | |
142 | (object_class, | |
143 | PROP_NAME, | |
144 | g_param_spec_string ("name", | |
145 | "Name", | |
146 | "The name of this feature.", | |
147 | NULL, | |
148 | G_PARAM_READWRITE | | |
149 | G_PARAM_CONSTRUCT_ONLY | | |
150 | G_PARAM_STATIC_NAME | | |
151 | G_PARAM_STATIC_NICK | | |
152 | G_PARAM_STATIC_BLURB)); | |
153 | ||
154 | /** | |
155 | * GUPnPFeature:version: | |
156 | * | |
157 | * The version of this feature. | |
158 | **/ | |
159 | g_object_class_install_property | |
160 | (object_class, | |
161 | PROP_VERSION, | |
162 | g_param_spec_string ("version", | |
163 | "Version", | |
164 | "The version of this feature.", | |
165 | NULL, | |
166 | G_PARAM_READWRITE | | |
167 | G_PARAM_CONSTRUCT_ONLY | | |
168 | G_PARAM_STATIC_NAME | | |
169 | G_PARAM_STATIC_NICK | | |
170 | G_PARAM_STATIC_BLURB)); | |
171 | ||
172 | /** | |
173 | * GUPnPFeature:object-ids: | |
174 | * | |
175 | * The object IDs related to this feature. | |
176 | **/ | |
177 | g_object_class_install_property | |
178 | (object_class, | |
179 | PROP_OBJECT_IDS, | |
180 | g_param_spec_string ("object-ids", | |
181 | "Object IDs", | |
182 | "The object IDs of this feature.", | |
183 | NULL, | |
184 | G_PARAM_READWRITE | | |
185 | G_PARAM_CONSTRUCT_ONLY | | |
186 | G_PARAM_STATIC_NAME | | |
187 | G_PARAM_STATIC_NICK | | |
188 | G_PARAM_STATIC_BLURB)); | |
189 | } | |
190 | ||
191 | /** | |
192 | * gupnp_feature_get_name: | |
193 | * @feature: #GUPnPFeature | |
194 | * | |
195 | * Get the name of the @feature. | |
196 | * | |
197 | * Return value: The name of the @feature. | |
198 | **/ | |
199 | const char * | |
200 | gupnp_feature_get_name (GUPnPFeature *feature) | |
201 | { | |
202 | return feature->priv->name; | |
203 | } | |
204 | ||
205 | /** | |
206 | * gupnp_feature_get_version: | |
207 | * @feature: #GUPnPFeature | |
208 | * | |
209 | * Get the version of the @feature. | |
210 | * | |
211 | * Return value: The version of the @feature. | |
212 | **/ | |
213 | const char * | |
214 | gupnp_feature_get_version (GUPnPFeature *feature) | |
215 | { | |
216 | return feature->priv->version; | |
217 | } | |
218 | ||
219 | /** | |
220 | * gupnp_feature_get_object_ids: | |
221 | * @feature: #GUPnPFeature | |
222 | * | |
223 | * Get the object IDs related to the @feature. | |
224 | * | |
225 | * Return value: The object IDs related to the @feature. | |
226 | **/ | |
227 | const char * | |
228 | gupnp_feature_get_object_ids (GUPnPFeature *feature) | |
229 | { | |
230 | return feature->priv->object_ids; | |
231 | } |
0 | /* | |
1 | * Copyright (C) 2012 Intel Corporation. | |
2 | * | |
3 | * Authors: Regis Merlino <regis.merlino@intel.com> | |
4 | * | |
5 | * This library is free software; you can redistribute it and/or | |
6 | * modify it under the terms of the GNU Library General Public | |
7 | * License as published by the Free Software Foundation; either | |
8 | * version 2 of the License, or (at your option) any later version. | |
9 | * | |
10 | * This library is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Library General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Library General Public | |
16 | * License along with this library; if not, write to the | |
17 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 | * Boston, MA 02110-1301, USA. | |
19 | */ | |
20 | ||
21 | #ifndef __GUPNP_FEATURE_H_ | |
22 | #define __GUPNP_FEATURE_H_ | |
23 | ||
24 | #include <glib-object.h> | |
25 | ||
26 | G_BEGIN_DECLS | |
27 | ||
28 | GType | |
29 | gupnp_feature_get_type (void) G_GNUC_CONST; | |
30 | ||
31 | #define GUPNP_TYPE_FEATURE \ | |
32 | (gupnp_feature_get_type ()) | |
33 | #define GUPNP_FEATURE(obj) \ | |
34 | (G_TYPE_CHECK_INSTANCE_CAST ((obj), \ | |
35 | GUPNP_TYPE_FEATURE, \ | |
36 | GUPnPFeature)) | |
37 | #define GUPNP_FEATURE_CLASS(obj) \ | |
38 | (G_TYPE_CHECK_CLASS_CAST ((obj), \ | |
39 | GUPNP_TYPE_FEATURE, \ | |
40 | GUPnPFeatureClass)) | |
41 | #define GUPNP_IS_FEATURE(obj) \ | |
42 | (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \ | |
43 | GUPNP_TYPE_FEATURE)) | |
44 | #define GUPNP_IS_FEATURE_CLASS(obj) \ | |
45 | (G_TYPE_CHECK_CLASS_TYPE ((obj), \ | |
46 | GUPNP_TYPE_FEATURE)) | |
47 | #define GUPNP_FEATURE_GET_CLASS(obj) \ | |
48 | (G_TYPE_INSTANCE_GET_CLASS ((obj), \ | |
49 | GUPNP_TYPE_FEATURE, \ | |
50 | GUPnPFeatureClass)) | |
51 | ||
52 | typedef struct _GUPnPFeaturePrivate GUPnPFeaturePrivate; | |
53 | ||
54 | typedef struct { | |
55 | GObject parent; | |
56 | ||
57 | GUPnPFeaturePrivate *priv; | |
58 | } GUPnPFeature; | |
59 | ||
60 | typedef struct { | |
61 | GObjectClass parent_class; | |
62 | } GUPnPFeatureClass; | |
63 | ||
64 | const char * | |
65 | gupnp_feature_get_name (GUPnPFeature *feature); | |
66 | ||
67 | const char * | |
68 | gupnp_feature_get_version (GUPnPFeature *feature); | |
69 | ||
70 | const char * | |
71 | gupnp_feature_get_object_ids (GUPnPFeature *feature); | |
72 | ||
73 | G_END_DECLS | |
74 | ||
75 | #endif /* __GUPNP_FEATURE_H_ */ |
274 | 274 | g_ascii_strcasecmp (str, "1") == 0; |
275 | 275 | } |
276 | 276 | |
277 | char * | |
278 | xml_util_get_child_string (xmlNode *parent_node, | |
279 | xmlDoc *doc, | |
280 | const char *name) | |
281 | { | |
282 | xmlBuffer *buffer; | |
283 | char *ret; | |
284 | xmlNode *node; | |
285 | ||
286 | node = xml_util_get_element (parent_node, name, NULL); | |
287 | if (!node) | |
288 | return NULL; | |
289 | ||
290 | buffer = xmlBufferCreate (); | |
291 | xmlNodeDump (buffer, | |
292 | doc, | |
293 | node, | |
294 | 0, | |
295 | 0); | |
296 | ret = g_strndup ((char *) xmlBufferContent (buffer), | |
297 | xmlBufferLength (buffer)); | |
298 | xmlBufferFree (buffer); | |
299 | ||
300 | return ret; | |
301 | } |
95 | 95 | xml_util_verify_attribute_is_boolean (xmlNode *node, |
96 | 96 | const char *attribute_name); |
97 | 97 | |
98 | G_GNUC_INTERNAL char * | |
99 | xml_util_get_child_string (xmlNode *parent_node, | |
100 | xmlDoc *doc, | |
101 | const char *name); | |
98 | 102 | #endif /* __XML_UTIL_H__ */ |
0 | ||
1 | dnl vala.m4 | |
2 | dnl | |
3 | dnl Copyright 2010 Marc-Andre Lureau | |
4 | dnl Copyright 2011 Rodney Dawes <dobey.pwns@gmail.com> | |
5 | dnl | |
6 | dnl This library is free software; you can redistribute it and/or | |
7 | dnl modify it under the terms of the GNU Lesser General Public | |
8 | dnl License as published by the Free Software Foundation; either | |
9 | dnl version 2.1 of the License, or (at your option) any later version. | |
10 | dnl | |
11 | dnl This library is distributed in the hope that it will be useful, | |
12 | dnl but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
14 | dnl Lesser General Public License for more details. | |
15 | dnl | |
16 | dnl You should have received a copy of the GNU Lesser General Public | |
17 | dnl License along with this library; if not, write to the Free Software | |
18 | dnl Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA | |
19 | ||
20 | dnl dropped everything but VALA_PROG_VAPIGEN - Jens Georg <mail@jensge.org> | |
21 | ||
22 | # Check whether the Vala API Generator exists in `PATH'. If it is found, | |
23 | # the variable VAPIGEN is set. Optionally a minimum release number of the | |
24 | # generator can be requested. | |
25 | # | |
26 | # VALA_PROG_VAPIGEN([MINIMUM-VERSION]) | |
27 | # ------------------------------------ | |
28 | AC_DEFUN([VALA_PROG_VAPIGEN], | |
29 | [AC_PATH_PROG([VAPIGEN], [vapigen], []) | |
30 | AS_IF([test -z "$VAPIGEN"], | |
31 | [AC_MSG_WARN([No Vala API Generator found. You will not be able to generate .vapi files.])], | |
32 | [AS_IF([test -n "$1"], | |
33 | [AC_MSG_CHECKING([$VAPIGEN is at least version $1]) | |
34 | am__vapigen_version=`$VAPIGEN --version | sed 's/Vala API Generator *//'` | |
35 | AS_VERSION_COMPARE([$1], ["$am__vapigen_version"], | |
36 | [AC_MSG_RESULT([yes])], | |
37 | [AC_MSG_RESULT([yes])], | |
38 | [AC_MSG_RESULT([no]) | |
39 | AC_MSG_ERROR([Vala API Generator $1 not found.])])])]) | |
40 | ]) |
7 | 7 | $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ |
8 | 8 | $(LIBGUPNP_LIBS) |
9 | 9 | |
10 | check_PROGRAMS = check-search | |
10 | check_PROGRAMS = check-search \ | |
11 | check-feature-list-parser | |
11 | 12 | check_search_SOURCES = check-search.c |
12 | 13 | check_search_LDADD = $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ |
13 | 14 | $(LIBGUPNP_LIBS) |
15 | check_feature_list_parser_SOURCES = check-feature-list-parser.c | |
16 | check_feature_list_parser_LDADD = \ | |
17 | $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ | |
18 | $(LIBGUPNP_LIBS) | |
14 | 19 | |
15 | 20 | TESTS = $(check_PROGRAMS) |
34 | 34 | build_triplet = @build@ |
35 | 35 | host_triplet = @host@ |
36 | 36 | noinst_PROGRAMS = test-search-criteria-parser$(EXEEXT) |
37 | check_PROGRAMS = check-search$(EXEEXT) | |
37 | check_PROGRAMS = check-search$(EXEEXT) \ | |
38 | check-feature-list-parser$(EXEEXT) | |
38 | 39 | subdir = tests |
39 | 40 | DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in |
40 | 41 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 |
42 | 43 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
43 | 44 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
44 | 45 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
45 | $(top_srcdir)/configure.ac | |
46 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
46 | 47 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
47 | 48 | $(ACLOCAL_M4) |
48 | 49 | mkinstalldirs = $(install_sh) -d |
50 | 51 | CONFIG_CLEAN_FILES = |
51 | 52 | CONFIG_CLEAN_VPATH_FILES = |
52 | 53 | PROGRAMS = $(noinst_PROGRAMS) |
53 | am_check_search_OBJECTS = check-search.$(OBJEXT) | |
54 | check_search_OBJECTS = $(am_check_search_OBJECTS) | |
54 | am_check_feature_list_parser_OBJECTS = \ | |
55 | check-feature-list-parser.$(OBJEXT) | |
56 | check_feature_list_parser_OBJECTS = \ | |
57 | $(am_check_feature_list_parser_OBJECTS) | |
55 | 58 | am__DEPENDENCIES_1 = |
56 | check_search_DEPENDENCIES = \ | |
59 | check_feature_list_parser_DEPENDENCIES = \ | |
57 | 60 | $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ |
58 | 61 | $(am__DEPENDENCIES_1) |
59 | 62 | AM_V_lt = $(am__v_lt_@AM_V@) |
60 | 63 | am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) |
61 | 64 | am__v_lt_0 = --silent |
65 | am_check_search_OBJECTS = check-search.$(OBJEXT) | |
66 | check_search_OBJECTS = $(am_check_search_OBJECTS) | |
67 | check_search_DEPENDENCIES = \ | |
68 | $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ | |
69 | $(am__DEPENDENCIES_1) | |
62 | 70 | am_test_search_criteria_parser_OBJECTS = \ |
63 | 71 | test-search-criteria-parser.$(OBJEXT) |
64 | 72 | test_search_criteria_parser_OBJECTS = \ |
92 | 100 | AM_V_GEN = $(am__v_GEN_@AM_V@) |
93 | 101 | am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) |
94 | 102 | am__v_GEN_0 = @echo " GEN " $@; |
95 | SOURCES = $(check_search_SOURCES) \ | |
103 | SOURCES = $(check_feature_list_parser_SOURCES) $(check_search_SOURCES) \ | |
96 | 104 | $(test_search_criteria_parser_SOURCES) |
97 | DIST_SOURCES = $(check_search_SOURCES) \ | |
98 | $(test_search_criteria_parser_SOURCES) | |
105 | DIST_SOURCES = $(check_feature_list_parser_SOURCES) \ | |
106 | $(check_search_SOURCES) $(test_search_criteria_parser_SOURCES) | |
99 | 107 | RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ |
100 | 108 | html-recursive info-recursive install-data-recursive \ |
101 | 109 | install-dvi-recursive install-exec-recursive \ |
286 | 294 | check_search_LDADD = $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ |
287 | 295 | $(LIBGUPNP_LIBS) |
288 | 296 | |
297 | check_feature_list_parser_SOURCES = check-feature-list-parser.c | |
298 | check_feature_list_parser_LDADD = \ | |
299 | $(top_builddir)/libgupnp-av/libgupnp-av-1.0.la \ | |
300 | $(LIBGUPNP_LIBS) | |
301 | ||
289 | 302 | TESTS = $(check_PROGRAMS) |
290 | 303 | all: all-recursive |
291 | 304 | |
339 | 352 | list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ |
340 | 353 | echo " rm -f" $$list; \ |
341 | 354 | rm -f $$list |
355 | check-feature-list-parser$(EXEEXT): $(check_feature_list_parser_OBJECTS) $(check_feature_list_parser_DEPENDENCIES) $(EXTRA_check_feature_list_parser_DEPENDENCIES) | |
356 | @rm -f check-feature-list-parser$(EXEEXT) | |
357 | $(AM_V_CCLD)$(LINK) $(check_feature_list_parser_OBJECTS) $(check_feature_list_parser_LDADD) $(LIBS) | |
342 | 358 | check-search$(EXEEXT): $(check_search_OBJECTS) $(check_search_DEPENDENCIES) $(EXTRA_check_search_DEPENDENCIES) |
343 | 359 | @rm -f check-search$(EXEEXT) |
344 | 360 | $(AM_V_CCLD)$(LINK) $(check_search_OBJECTS) $(check_search_LDADD) $(LIBS) |
352 | 368 | distclean-compile: |
353 | 369 | -rm -f *.tab.c |
354 | 370 | |
371 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check-feature-list-parser.Po@am__quote@ | |
355 | 372 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/check-search.Po@am__quote@ |
356 | 373 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test-search-criteria-parser.Po@am__quote@ |
357 | 374 |
0 | /* | |
1 | * Copyright (C) 2012 Intel Corporation | |
2 | * | |
3 | * Authors: Regis Merlino <regis.merlino@intel.com> | |
4 | * | |
5 | * This library is free software; you can redistribute it and/or | |
6 | * modify it under the terms of the GNU Library General Public | |
7 | * License as published by the Free Software Foundation; either | |
8 | * version 2 of the License, or (at your option) any later version. | |
9 | * | |
10 | * This library is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Library General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Library General Public | |
16 | * License along with this library; if not, write to the | |
17 | * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | |
18 | * Boston, MA 02110-1301, USA. | |
19 | */ | |
20 | ||
21 | #include <libgupnp-av/gupnp-feature-list-parser.h> | |
22 | #include <stdlib.h> | |
23 | #include <string.h> | |
24 | ||
25 | static const char * const names[] = { | |
26 | "BOOKMARK", | |
27 | "EPG", | |
28 | }; | |
29 | ||
30 | static const char * const versions[] = { | |
31 | "1", | |
32 | "2", | |
33 | }; | |
34 | ||
35 | static const char * const ids[] = { | |
36 | "bookmark1,bookmark2,bookmark3", | |
37 | "epg1,epg2", | |
38 | }; | |
39 | ||
40 | static const char *text = | |
41 | "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" | |
42 | "<Features " | |
43 | "xmlns=\"urn:schemas-upnp-org:av:avs\" " | |
44 | "xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" " | |
45 | "xsi:schemaLocation=\"" | |
46 | "urn:schemas-upnp-org:av:avs " | |
47 | "http://www.upnp.org/schemas/av/avs-v1-20060531.xsd\">" | |
48 | "<Feature name=\"BOOKMARK\" version=\"1\">" | |
49 | "<objectIDs>bookmark1</objectIDs>" | |
50 | "<objectIDs>bookmark2,bookmark3</objectIDs>" | |
51 | "</Feature>" | |
52 | "<Feature name=\"EPG\" version=\"2\">" | |
53 | "<objectIDs>epg1,epg2</objectIDs>" | |
54 | "</Feature>" | |
55 | "</Features>"; | |
56 | ||
57 | static gboolean | |
58 | check_feature (GUPnPFeature *feature) | |
59 | { | |
60 | static int index = 0; | |
61 | ||
62 | if (strcmp (names[index], gupnp_feature_get_name (feature))) | |
63 | return FALSE; | |
64 | ||
65 | if (strcmp (versions[index], gupnp_feature_get_version (feature))) | |
66 | return FALSE; | |
67 | ||
68 | if (strcmp (ids[index], gupnp_feature_get_object_ids (feature))) | |
69 | return FALSE; | |
70 | ||
71 | index++; | |
72 | ||
73 | return TRUE; | |
74 | } | |
75 | ||
76 | int | |
77 | main (int argc, char **argv) | |
78 | { | |
79 | GUPnPFeatureListParser *parser; | |
80 | GError *error; | |
81 | GList *features; | |
82 | GList *item; | |
83 | gboolean success = TRUE; | |
84 | ||
85 | g_type_init (); | |
86 | ||
87 | parser = gupnp_feature_list_parser_new (); | |
88 | ||
89 | error = NULL; | |
90 | features = gupnp_feature_list_parser_parse_text (parser, text, &error); | |
91 | if (features == NULL) { | |
92 | g_printerr ("Parse error: %s\n", error->message); | |
93 | g_error_free (error); | |
94 | return EXIT_FAILURE; | |
95 | } | |
96 | ||
97 | for (item = features; item != NULL; item = g_list_next (item)) { | |
98 | success = check_feature ((GUPnPFeature *) item->data); | |
99 | if (!success) | |
100 | break; | |
101 | } | |
102 | ||
103 | g_print ("\n"); | |
104 | ||
105 | g_list_free_full (features, g_object_unref); | |
106 | g_object_unref (parser); | |
107 | ||
108 | return (success) ? EXIT_SUCCESS : EXIT_FAILURE; | |
109 | } |
40 | 40 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
41 | 41 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
42 | 42 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
43 | $(top_srcdir)/configure.ac | |
43 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
44 | 44 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
45 | 45 | $(ACLOCAL_M4) |
46 | 46 | mkinstalldirs = $(install_sh) -d |
7 | 7 | SearchCriteriaParserError skip |
8 | 8 | SearchCriteriaParser |
9 | 9 | .expression skip |
10 | ProtocolError skip | |
11 | protocol_error_quark skip |
40 | 40 | $(top_srcdir)/m4/introspection.m4 $(top_srcdir)/m4/libtool.m4 \ |
41 | 41 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ |
42 | 42 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ |
43 | $(top_srcdir)/configure.ac | |
43 | $(top_srcdir)/m4/vapigen.m4 $(top_srcdir)/configure.ac | |
44 | 44 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ |
45 | 45 | $(ACLOCAL_M4) |
46 | 46 | mkinstalldirs = $(install_sh) -d |
37 | 37 | FAILED |
38 | 38 | } |
39 | 39 | |
40 | [CCode (cheader_filename = "libgupnp-av/gupnp-av.h", cprefix = "GUPNP_PROTOCOL_ERROR_")] | |
41 | public errordomain ProtocolError { | |
42 | INVALID_SYNTAX, | |
43 | OTHER; | |
44 | public static GLib.Quark quark (); | |
45 | } | |
46 | ||
40 | 47 | public class SearchCriteriaParser : GLib.Object { |
41 | 48 | public virtual signal bool expression (string property, GUPnP.SearchCriteriaOp op, string value, GLib.Error error); |
42 | 49 | } |