/usr/include/tracker-2.0/libtracker-miner/tracker-decorator.h is in libtracker-miner-2.0-dev 2.0.3-1ubuntu4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 | /*
* Copyright (C) 2014 Carlos Garnacho <carlosg@gnome.org>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
* Boston, MA 02110-1301, USA.
*/
#ifndef __LIBTRACKER_MINER_DECORATOR_H__
#define __LIBTRACKER_MINER_DECORATOR_H__
#if !defined (__LIBTRACKER_MINER_H_INSIDE__) && !defined (TRACKER_COMPILATION)
#error "Only <libtracker-miner/tracker-miner.h> can be included directly."
#endif
#include "tracker-miner-object.h"
G_BEGIN_DECLS
#define TRACKER_TYPE_DECORATOR (tracker_decorator_get_type())
#define TRACKER_DECORATOR(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TRACKER_TYPE_DECORATOR, TrackerDecorator))
#define TRACKER_DECORATOR_CLASS(c) (G_TYPE_CHECK_CLASS_CAST ((c), TRACKER_TYPE_DECORATOR, TrackerDecoratorClass))
#define TRACKER_IS_DECORATOR(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TRACKER_TYPE_DECORATOR))
#define TRACKER_IS_DECORATOR_CLASS(c) (G_TYPE_CHECK_CLASS_TYPE ((c), TRACKER_TYPE_DECORATOR))
#define TRACKER_DECORATOR_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), TRACKER_TYPE_DECORATOR, TrackerDecoratorClass))
typedef struct _TrackerDecorator TrackerDecorator;
typedef struct _TrackerDecoratorClass TrackerDecoratorClass;
typedef struct _TrackerDecoratorInfo TrackerDecoratorInfo;
/**
* TrackerDecorator:
*
* Abstract miner object for passive extended metadata indexing, i.e.
* data past the basic information such as file name, size, etc.
**/
struct _TrackerDecorator {
TrackerMiner parent_instance;
gpointer priv;
};
/**
* TrackerDecoratorClass:
* @parent_class: parent object class.
* @items_available: Called when there are resources to be processed.
* @finished: Called when all resources have been processed.
* @padding: Reserved for future API improvements.
*
* An implementation that takes care of extracting extra metadata
* specific to file types by talking to tracker-extract.
*
* Based on #TrackerMinerClass.
**/
struct _TrackerDecoratorClass {
TrackerMinerClass parent_class;
void (* items_available) (TrackerDecorator *decorator);
void (* finished) (TrackerDecorator *decorator);
/* <Private> */
gpointer padding[10];
};
/**
* TrackerDecoratorError:
* @TRACKER_DECORATOR_ERROR_EMPTY: There is no item to be processed
* next. It is entirely possible to have a ::items_available signal
* emitted and then have this error when calling
* tracker_decorator_next_finish() because the signal may apply to a
* class which we're not interested in. For example, a new nmo:Email
* might have been added to Tracker, but we might only be interested
* in nfo:Document. This case would give this error.
* @TRACKER_DECORATOR_ERROR_PAUSED: No work was done or will be done
* because the miner is currently paused.
*
* Possible errors returned when calling tracker_decorator_next_finish().
**/
typedef enum {
TRACKER_DECORATOR_ERROR_EMPTY,
TRACKER_DECORATOR_ERROR_PAUSED
} TrackerDecoratorError;
GType tracker_decorator_get_type (void) G_GNUC_CONST;
GQuark tracker_decorator_error_quark (void);
const gchar * tracker_decorator_get_data_source (TrackerDecorator *decorator);
const gchar** tracker_decorator_get_class_names (TrackerDecorator *decorator);
guint tracker_decorator_get_n_items (TrackerDecorator *decorator);
void tracker_decorator_prepend_id (TrackerDecorator *decorator,
gint id,
gint class_name_id);
void tracker_decorator_delete_id (TrackerDecorator *decorator,
gint id);
void tracker_decorator_next (TrackerDecorator *decorator,
GCancellable *cancellable,
GAsyncReadyCallback callback,
gpointer user_data);
TrackerDecoratorInfo *
tracker_decorator_next_finish (TrackerDecorator *decorator,
GAsyncResult *result,
GError **error);
void tracker_decorator_set_priority_rdf_types (TrackerDecorator *decorator,
const gchar * const *rdf_types);
GType tracker_decorator_info_get_type (void) G_GNUC_CONST;
TrackerDecoratorInfo *
tracker_decorator_info_ref (TrackerDecoratorInfo *info);
void tracker_decorator_info_unref (TrackerDecoratorInfo *info);
const gchar * tracker_decorator_info_get_urn (TrackerDecoratorInfo *info);
const gchar * tracker_decorator_info_get_url (TrackerDecoratorInfo *info);
const gchar * tracker_decorator_info_get_mimetype (TrackerDecoratorInfo *info);
GTask * tracker_decorator_info_get_task (TrackerDecoratorInfo *info);
void tracker_decorator_info_complete (TrackerDecoratorInfo *info,
gchar *sparql);
void tracker_decorator_info_complete_error (TrackerDecoratorInfo *info,
GError *error);
G_END_DECLS
#endif /* __LIBTRACKER_MINER_DECORATOR_H__ */
|