2
* Copyright (C) 2011 Canonical Ltd
4
* This program is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License version 3 as
6
* published by the Free Software Foundation.
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU General Public License for more details.
13
* You should have received a copy of the GNU General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
16
* Authored by Mikkel Kamstrup Erlandsen <mikkel.kamstrup@canonical.com>
21
#ifndef _UNITY_RATINGS_DB_H_
22
#define _UNITY_RATINGS_DB_H_
29
/* This struct *must* start with 3 32 bit integers, to smoothly be able
30
* to store the results we read from the Software Center Ratings DB */
32
gint32 average_rating;
34
gint32 dampened_rating;
37
typedef struct _UnityRatingsDatabase UnityRatingsDatabase;
39
UnityRatingsDatabase* unity_ratings_database_new (GError **error);
41
void unity_ratings_database_free (UnityRatingsDatabase *self);
43
gboolean unity_ratings_database_query (UnityRatingsDatabase *self,
45
UnityRatingsResult *out_result);
50
#endif /* _UNITY_RATINGS_DB_H_ */