![]() |
![]() |
![]() |
Tracker Client Library Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
#include <libtracker-client/tracker-client.h> gchar * tracker_sparql_escape (const gchar *str
); gchar * tracker_uri_printf_escaped (const gchar *format
,...
); gchar * tracker_uri_vprintf_escaped (const gchar *format
,va_list args
);
gchar * tracker_sparql_escape (const gchar *str
);
Escapes a string so it can be passed as a SPARQL parameter in any query/update.
|
a string to escape. |
Returns : |
the newly allocated escaped string which must be freed
using g_free() .
|
Since 0.8
gchar * tracker_uri_printf_escaped (const gchar *format
,...
);
Calls tracker_uri_vprintf_escaped()
with the Varargs
supplied.
|
a standard printf() format string, but notice
string precision pitfalls
|
|
the parameters to insert into the format string |
Returns : |
a newly-allocated string holding the result which should
be freed with g_free() when finished with.
|
Since 0.8
gchar * tracker_uri_vprintf_escaped (const gchar *format
,va_list args
);
Similar to the standard C vsprintf()
function but safer, since it
calculates the maximum space required and allocates memory to hold
the result.
The result is escaped using g_uri_escape_string()
.
|
a standard printf() format string, but notice
string precision pitfalls
|
|
the list of parameters to insert into the format string |
Returns : |
a newly-allocated string holding the result which should
be freed with g_free() when finished with.
|
Since 0.8