2727
2828#include <glib-object.h>
2929#include "as-component-box.h"
30+ #include "as-macros-private.h"
3031
3132G_BEGIN_DECLS
3233
3334#define AS_TYPE_CACHE (as_cache_get_type ())
35+ AS_INTERNAL_API
3436G_DECLARE_DERIVABLE_TYPE (AsCache , as_cache , AS , CACHE , GObject )
3537
3638struct _AsCacheClass {
@@ -89,26 +91,37 @@ typedef enum {
8991} AsCacheError ;
9092
9193#define AS_CACHE_ERROR as_cache_error_quark ()
94+ AS_INTERNAL_API
9295GQuark as_cache_error_quark (void );
9396
97+ AS_INTERNAL_API
9498AsCache * as_cache_new (void );
9599
100+ AS_INTERNAL_API
96101const gchar * as_cache_get_locale (AsCache * cache );
102+ AS_INTERNAL_API
97103void as_cache_set_locale (AsCache * cache , const gchar * locale );
98104
105+ AS_INTERNAL_API
99106void as_cache_set_locations (AsCache * cache ,
100107 const gchar * system_cache_dir ,
101108 const gchar * user_cache_dir );
102109
110+ AS_INTERNAL_API
103111gboolean as_cache_get_prefer_os_metainfo (AsCache * cache );
112+ AS_INTERNAL_API
104113void as_cache_set_prefer_os_metainfo (AsCache * cache , gboolean prefer_os_metainfo );
105114
115+ AS_INTERNAL_API
106116void as_cache_set_resolve_addons (AsCache * cache , gboolean resolve_addons );
107117
118+ AS_INTERNAL_API
108119void as_cache_prune_data (AsCache * cache );
109120
121+ AS_INTERNAL_API
110122void as_cache_clear (AsCache * cache );
111123
124+ AS_INTERNAL_API
112125gboolean as_cache_set_contents_for_section (AsCache * cache ,
113126 AsComponentScope scope ,
114127 AsFormatStyle source_format_style ,
@@ -117,69 +130,87 @@ gboolean as_cache_set_contents_for_section (AsCache *cache,
117130 const gchar * cache_key ,
118131 gpointer refinefn_user_data ,
119132 GError * * error );
133+ AS_INTERNAL_API
120134gboolean as_cache_set_contents_for_path (AsCache * cache ,
121135 GPtrArray * cpts ,
122136 const gchar * filename ,
123137 gpointer refinefn_user_data ,
124138 GError * * error );
125139
140+ AS_INTERNAL_API
126141time_t as_cache_get_ctime (AsCache * cache ,
127142 AsComponentScope scope ,
128143 const gchar * cache_key ,
129144 AsCacheScope * cache_scope );
130145
146+ AS_INTERNAL_API
131147void as_cache_load_section_for_key (AsCache * cache ,
132148 AsComponentScope scope ,
133149 AsFormatStyle source_format_style ,
134150 gboolean is_os_data ,
135151 const gchar * cache_key ,
136152 gboolean * is_outdated ,
137153 gpointer refinefn_user_data );
154+ AS_INTERNAL_API
138155void as_cache_load_section_for_path (AsCache * cache ,
139156 const gchar * filename ,
140157 gboolean * is_outdated ,
141158 gpointer refinefn_user_data );
142159
160+ AS_INTERNAL_API
143161void as_cache_mask_by_data_id (AsCache * cache , const gchar * cdid );
162+ AS_INTERNAL_API
144163gboolean as_cache_add_masking_components (AsCache * cache , GPtrArray * cpts , GError * * error );
145164
165+ AS_INTERNAL_API
146166void as_cache_set_refine_func (AsCache * cache , AsCacheDataRefineFn func );
147167
168+ AS_INTERNAL_API
148169gboolean as_cache_is_empty (AsCache * cache );
170+ AS_INTERNAL_API
149171guint as_cache_get_component_count (AsCache * cache );
150172
173+ AS_INTERNAL_API
151174AsComponentBox * as_cache_get_components_all (AsCache * cache , GError * * error );
152175
176+ AS_INTERNAL_API
153177AsComponentBox * as_cache_get_components_by_id (AsCache * cache , const gchar * id , GError * * error );
154178
179+ AS_INTERNAL_API
155180AsComponentBox * as_cache_get_components_by_extends (AsCache * cache ,
156181 const gchar * extends_id ,
157182 GError * * error );
158183
184+ AS_INTERNAL_API
159185AsComponentBox * as_cache_get_components_by_kind (AsCache * cache ,
160186 AsComponentKind kind ,
161187 GError * * error );
162188
189+ AS_INTERNAL_API
163190AsComponentBox * as_cache_get_components_by_provided_item (AsCache * cache ,
164191 AsProvidedKind kind ,
165192 const gchar * item ,
166193 GError * * error );
167194
195+ AS_INTERNAL_API
168196AsComponentBox * as_cache_get_components_by_categories (AsCache * cache ,
169197 gchar * * categories ,
170198 GError * * error );
171199
200+ AS_INTERNAL_API
172201AsComponentBox * as_cache_get_components_by_launchable (AsCache * cache ,
173202 AsLaunchableKind kind ,
174203 const gchar * id ,
175204 GError * * error );
176205
206+ AS_INTERNAL_API
177207AsComponentBox * as_cache_get_components_by_bundle_id (AsCache * cache ,
178208 AsBundleKind kind ,
179209 const gchar * id ,
180210 gboolean match_prefix ,
181211 GError * * error );
182212
213+ AS_INTERNAL_API
183214AsComponentBox * as_cache_search (AsCache * cache ,
184215 const gchar * const * terms ,
185216 gboolean sort ,
0 commit comments