<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
               "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
[
  <!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
]>
<refentry id="appstream-as-utils-private">
<refmeta>
<refentrytitle role="top_of_page" id="appstream-as-utils-private.top_of_page">as-utils-private</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>APPSTREAM Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>as-utils-private</refname>
<refpurpose></refpurpose>
</refnamediv>

<refsect1 id="appstream-as-utils-private.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_return" colwidth="150px"/>
<colspec colname="functions_name"/>
<tbody>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="as-utils-delete-dir-recursive">as_utils_delete_dir_recursive</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="as-utils-categories-from-strv">as_utils_categories_from_strv</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="as-utils-categories-from-str">as_utils_categories_from_str</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="as-utils-find-files-matching">as_utils_find_files_matching</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="as-utils-find-files">as_utils_find_files</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="as-utils-is-root">as_utils_is_root</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="as-utils-is-writable">as_utils_is_writable</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="as-str-replace">as_str_replace</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;**
</entry><entry role="function_name"><link linkend="as-ptr-array-to-strv">as_ptr_array_to_strv</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="as-touch-location">as_touch_location</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>


<refsect1 id="appstream-as-utils-private.description" role="desc">
<title role="desc.title">Description</title>
<para>
</para>

</refsect1>
<refsect1 id="appstream-as-utils-private.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="as-utils-delete-dir-recursive" role="function">
<title>as_utils_delete_dir_recursive&#160;()</title>
<indexterm zone="as-utils-delete-dir-recursive"><primary>as_utils_delete_dir_recursive</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
as_utils_delete_dir_recursive (<parameter>const <link linkend="gchar"><type>gchar</type></link> *dirname</parameter>);</programlisting>
<para>Remove directory and all its children (like rm -r does).</para>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>dirname</para></entry>
<entry role="parameter_description"><para>Directory to remove</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if operation was successful</para>
</refsect3></refsect2>
<refsect2 id="as-utils-categories-from-strv" role="function">
<title>as_utils_categories_from_strv&#160;()</title>
<indexterm zone="as-utils-categories-from-strv"><primary>as_utils_categories_from_strv</primary></indexterm>
<programlisting language="C"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
as_utils_categories_from_strv (<parameter><link linkend="gchar"><type>gchar</type></link> **categories_strv</parameter>,
                               <parameter><link linkend="GPtrArray"><type>GPtrArray</type></link> *system_categories</parameter>);</programlisting>
<para>Create a list of categories from string array</para>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>categories_strv</para></entry>
<entry role="parameter_description"><para>a string array</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>system_categories</para></entry>
<entry role="parameter_description"><para>list of <link linkend="AsCategory"><type>AsCategory</type></link> objects available on this system</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 role="returns">
<title>Returns</title>
<para> <link linkend="GPtrArray"><type>GPtrArray</type></link> of <link linkend="AsCategory"><type>AsCategory</type></link> objects matching the strings in the array. </para>
<para><emphasis role="annotation">[<acronym>element-type</acronym> AsCategory][<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="as-utils-categories-from-str" role="function">
<title>as_utils_categories_from_str&#160;()</title>
<indexterm zone="as-utils-categories-from-str"><primary>as_utils_categories_from_str</primary></indexterm>
<programlisting language="C"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
as_utils_categories_from_str (<parameter>const <link linkend="gchar"><type>gchar</type></link> *categories_str</parameter>,
                              <parameter><link linkend="GPtrArray"><type>GPtrArray</type></link> *system_categories</parameter>);</programlisting>
<para>Create a list of categories from semicolon-separated string</para>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>categories_str</para></entry>
<entry role="parameter_description"><para>string with semicolon-separated categories</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>system_categories</para></entry>
<entry role="parameter_description"><para>list of <link linkend="AsCategory"><type>AsCategory</type></link> objects available on this system</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 role="returns">
<title>Returns</title>
<para> <link linkend="GPtrArray"><type>GPtrArray</type></link> of <link linkend="AsCategory"><type>AsCategory</type></link> objcts matching the strings in the array. </para>
<para><emphasis role="annotation">[<acronym>element-type</acronym> AsCategory][<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="as-utils-find-files-matching" role="function">
<title>as_utils_find_files_matching&#160;()</title>
<indexterm zone="as-utils-find-files-matching"><primary>as_utils_find_files_matching</primary></indexterm>
<programlisting language="C"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
as_utils_find_files_matching (<parameter>const <link linkend="gchar"><type>gchar</type></link> *dir</parameter>,
                              <parameter>const <link linkend="gchar"><type>gchar</type></link> *pattern</parameter>,
                              <parameter><link linkend="gboolean"><type>gboolean</type></link> recursive</parameter>,
                              <parameter><link linkend="GError"><type>GError</type></link> **error</parameter>);</programlisting>
</refsect2>
<refsect2 id="as-utils-find-files" role="function">
<title>as_utils_find_files&#160;()</title>
<indexterm zone="as-utils-find-files"><primary>as_utils_find_files</primary></indexterm>
<programlisting language="C"><link linkend="GPtrArray"><returnvalue>GPtrArray</returnvalue></link>&#160;*
as_utils_find_files (<parameter>const <link linkend="gchar"><type>gchar</type></link> *dir</parameter>,
                     <parameter><link linkend="gboolean"><type>gboolean</type></link> recursive</parameter>,
                     <parameter><link linkend="GError"><type>GError</type></link> **error</parameter>);</programlisting>
</refsect2>
<refsect2 id="as-utils-is-root" role="function">
<title>as_utils_is_root&#160;()</title>
<indexterm zone="as-utils-is-root"><primary>as_utils_is_root</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
as_utils_is_root (<parameter><type>void</type></parameter>);</programlisting>
</refsect2>
<refsect2 id="as-utils-is-writable" role="function">
<title>as_utils_is_writable&#160;()</title>
<indexterm zone="as-utils-is-writable"><primary>as_utils_is_writable</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
as_utils_is_writable (<parameter>const <link linkend="gchar"><type>gchar</type></link> *path</parameter>);</programlisting>
<para>Checks if a path is writable.</para>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>path</para></entry>
<entry role="parameter_description"><para>the path to check.</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>
<refsect2 id="as-str-replace" role="function">
<title>as_str_replace&#160;()</title>
<indexterm zone="as-str-replace"><primary>as_str_replace</primary></indexterm>
<programlisting language="C"><link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;*
as_str_replace (<parameter>const <link linkend="gchar"><type>gchar</type></link> *str</parameter>,
                <parameter>const <link linkend="gchar"><type>gchar</type></link> *old_str</parameter>,
                <parameter>const <link linkend="gchar"><type>gchar</type></link> *new_str</parameter>);</programlisting>
</refsect2>
<refsect2 id="as-ptr-array-to-strv" role="function">
<title>as_ptr_array_to_strv&#160;()</title>
<indexterm zone="as-ptr-array-to-strv"><primary>as_ptr_array_to_strv</primary></indexterm>
<programlisting language="C"><link linkend="gchar"><returnvalue>gchar</returnvalue></link>&#160;**
as_ptr_array_to_strv (<parameter><link linkend="GPtrArray"><type>GPtrArray</type></link> *array</parameter>);</programlisting>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>array</para></entry>
<entry role="parameter_description"><para>. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>element-type</acronym> utf8]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 role="returns">
<title>Returns</title>
<para> strv of the string array. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="as-touch-location" role="function">
<title>as_touch_location&#160;()</title>
<indexterm zone="as-touch-location"><primary>as_touch_location</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
as_touch_location (<parameter>const <link linkend="gchar"><type>gchar</type></link> *fname</parameter>);</programlisting>
<para>Change mtime of a filesystem location.</para>
<refsect3 role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fname</para></entry>
<entry role="parameter_description"><para>The file or directory to touch.</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>

</refsect1>
<refsect1 id="appstream-as-utils-private.other_details" role="details">
<title role="details.title">Types and Values</title>

</refsect1>

</refentry>
