Initial stubs for adding support for photo sets
[frogr:mainline.git] / src / flicksoup / fsp-photos-mgr.h
1 /*
2  * fsp-photos-mgr.h
3  *
4  * Copyright (C) 2010 Mario Sanchez Prada
5  * Authors: Mario Sanchez Prada <msanchez@igalia.com>
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of version 3 of the GNU Lesser General
9  * Public License as published by the Free Software Foundation.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public
17  * License along with this program; if not, write to the
18  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  *
21  */
22
23 #ifndef _FSP_PHOTOS_MGR_H
24 #define _FSP_PHOTOS_MGR_H
25
26 #include <glib.h>
27 #include <glib-object.h>
28
29 #include <flicksoup/fsp-data.h>
30 #include <flicksoup/fsp-session.h>
31
32 G_BEGIN_DECLS
33
34 #define FSP_TYPE_PHOTOS_MGR                   \
35   (fsp_photos_mgr_get_type())
36 #define FSP_PHOTOS_MGR(obj)                                           \
37   (G_TYPE_CHECK_INSTANCE_CAST (obj, FSP_TYPE_PHOTOS_MGR, FspPhotosMgr))
38 #define FSP_PHOTOS_MGR_CLASS(klass)                                   \
39   (G_TYPE_CHECK_CLASS_CAST(klass, FSP_TYPE_PHOTOS_MGR, FspPhotosMgrClass))
40 #define FSP_IS_PHOTOS_MGR(obj)                                \
41   (G_TYPE_CHECK_INSTANCE_TYPE(obj, FSP_TYPE_PHOTOS_MGR))
42 #define FSP_IS_PHOTOS_MGR_CLASS(klass)                        \
43   (G_TYPE_CHECK_CLASS_TYPE((klass), FSP_TYPE_PHOTOS_MGR))
44 #define FSP_PHOTOS_MGR_GET_CLASS(obj)                                 \
45   (G_TYPE_INSTANCE_GET_CLASS ((obj), FSP_TYPE_PHOTOS_MGR, FspPhotosMgrClass))
46
47 typedef struct _FspPhotosMgr FspPhotosMgr;
48 typedef struct _FspPhotosMgrClass FspPhotosMgrClass;
49 typedef struct _FspPhotosMgrPrivate FspPhotosMgrPrivate;
50
51 struct _FspPhotosMgr
52 {
53   GObject parent_instance;
54   FspPhotosMgrPrivate *priv;
55 };
56
57 struct _FspPhotosMgrClass
58 {
59   GObjectClass parent_class;
60 };
61
62
63 GType
64 fsp_photos_mgr_get_type                 (void) G_GNUC_CONST;
65
66 FspPhotosMgr *
67 fsp_photos_mgr_new                      (FspSession *session);
68
69 FspSession *
70 fsp_photos_mgr_get_session              (FspPhotosMgr *self);
71
72 void
73 fsp_photos_mgr_upload_async             (FspPhotosMgr        *self,
74                                          const gchar         *filepath,
75                                          const gchar         *title,
76                                          const gchar         *description,
77                                          const gchar         *tags,
78                                          FspVisibility        is_public,
79                                          FspVisibility        is_family,
80                                          FspVisibility        is_friend,
81                                          FspSafetyLevel       safety_level,
82                                          FspContentType       content_type,
83                                          FspSearchScope       hidden,
84                                          GCancellable        *cancellable,
85                                          GAsyncReadyCallback  callback,
86                                          gpointer             user_data);
87
88 gchar *
89 fsp_photos_mgr_upload_finish            (FspPhotosMgr  *self,
90                                          GAsyncResult  *res,
91                                          GError       **error);
92
93 void
94 fsp_photos_mgr_get_info_async           (FspPhotosMgr        *self,
95                                          const gchar         *photo_id,
96                                          GCancellable        *cancellable,
97                                          GAsyncReadyCallback  callback,
98                                          gpointer             user_data);
99
100 FspDataPhotoInfo *
101 fsp_photos_mgr_get_info_finish          (FspPhotosMgr  *self,
102                                          GAsyncResult  *res,
103                                          GError       **error);
104 void
105 fsp_photos_mgr_get_photosets_async      (FspPhotosMgr        *self,
106                                          GCancellable        *cancellable,
107                                          GAsyncReadyCallback  callback,
108                                          gpointer             user_data);
109
110 GSList *
111 fsp_photos_mgr_get_photosets_finish     (FspPhotosMgr  *self,
112                                          GAsyncResult  *res,
113                                          GError       **error);
114
115 void
116 fsp_photos_mgr_add_to_photosets_async   (FspPhotosMgr        *self,
117                                          const gchar         *photo_id,
118                                          const gchar         *photoset_id,
119                                          GCancellable        *cancellable,
120                                          GAsyncReadyCallback  callback,
121                                          gpointer             user_data);
122
123 gboolean
124 fsp_photos_mgr_add_to_photoset_finish   (FspPhotosMgr  *self,
125                                          GAsyncResult  *res,
126                                          GError       **error);
127 void
128 fsp_photos_mgr_create_photoset_async    (FspPhotosMgr        *self,
129                                          const gchar         *title,
130                                          const gchar         *description,
131                                          const gchar         *primary_photo_id,
132                                          GCancellable        *cancellable,
133                                          GAsyncReadyCallback  callback,
134                                          gpointer             user_data);
135
136 FspDataPhotoSet *
137 fsp_photos_mgr_create_photoset_finish   (FspPhotosMgr  *self,
138                                          GAsyncResult  *res,
139                                          GError       **error);
140
141
142 G_END_DECLS
143
144 #endif