~ubuntu-branches/ubuntu/raring/grilo/raring-proposed

« back to all changes in this revision

Viewing changes to libs/net/grl-net-private.h

  • Committer: Package Import Robot
  • Author(s): Alberto Garcia
  • Date: 2012-05-24 18:05:32 UTC
  • mfrom: (1.1.4)
  • Revision ID: package-import@ubuntu.com-20120524180532-ccftaeh72upen313
Tags: 0.1.19-1
* New upstream release.
* Build using Vala 0.16:
  - debian/control: update build dependencies.
  - debian/rules: install Vala API files in /usr/share/vala/vapi.
  - debian/libgrilo-0.1-dev.install: update path of Vala API files.
* Create a new libgrilo-0.1-bin package and move grl-inspect-0.1 there.
  - debian/rules: rename manpage to match the binary name.
* Drop libgrilo-0.1-0.shlibs and use dh_makeshlibs to generate a shlibs
  file.
* Multi-arch support:
  - debian/compat: set compatibility level to 9.
  - debian/control: build depend on debhelper >= 9.
  - debian/control: Add Multi-Arch and Pre-Depends fields to
    libgrilo-0.1-0.
  - debian/libgrilo-0.1-{0,dev}.install: replace usr/lib/ with
    usr/lib/*/.
  - bump shlibs to 0.1.19 and break grilo-plugins-0.1 << 0.1.19.
* libgrilo-0.1-{0,bin}.lintian-overrides: ignore the
  hardening-no-stackprotector warning, Grilo does not use character
  arrays on the stack.
* debian/copyright: update copyright years and add section for Debian
  files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Copyright (C) 2012 Igalia S.L.
 
3
 *
 
4
 * Contact: Iago Toral Quiroga <itoral@igalia.com>
 
5
 *
 
6
 * Authors: Víctor M. Jáquez L. <vjaquez@igalia.com>
 
7
 *          Juan A. Suarez Romero <jasuarez@igalia.com>
 
8
 *
 
9
 * This library is free software; you can redistribute it and/or
 
10
 * modify it under the terms of the GNU Lesser General Public License
 
11
 * as published by the Free Software Foundation; version 2.1 of
 
12
 * the License, or (at your option) any later version.
 
13
 *
 
14
 * This library is distributed in the hope that it will be useful, but
 
15
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 
17
 * Lesser General Public License for more details.
 
18
 *
 
19
 * You should have received a copy of the GNU Lesser General Public
 
20
 * License along with this library; if not, write to the Free Software
 
21
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
 
22
 * 02110-1301 USA
 
23
 *
 
24
 */
 
25
 
 
26
#ifndef _GRL_NET_PRIVATE_H_
 
27
#define _GRL_NET_PRIVATE_H_
 
28
 
 
29
#include <libsoup/soup.h>
 
30
#include <grilo.h>
 
31
 
 
32
#include "grl-net-wc.h"
 
33
 
 
34
G_BEGIN_DECLS
 
35
 
 
36
struct _GrlNetWcPrivate {
 
37
  SoupSession *session;
 
38
  SoupLoggerLogLevel log_level;
 
39
  guint throttling;             /* throttling in secs */
 
40
  GTimeVal last_request;        /* last request time  */
 
41
  GQueue *pending;              /* closure queue for delayed requests */
 
42
  guint cache_size;             /* cache size in Mb */
 
43
  void *requester;
 
44
  gchar *previous_data;
 
45
};
 
46
 
 
47
void parse_error (guint status,
 
48
                  const gchar *reason,
 
49
                  const gchar *response,
 
50
                  GSimpleAsyncResult *result);
 
51
 
 
52
void get_url_now (GrlNetWc *self,
 
53
                  const char *url,
 
54
                  GAsyncResult *result,
 
55
                  GCancellable *cancellable);
 
56
 
 
57
void get_content (GrlNetWc *self,
 
58
                  void *op,
 
59
                  gchar **content,
 
60
                  gsize *length);
 
61
 
 
62
void init_requester (GrlNetWc *self);
 
63
 
 
64
void finalize_requester (GrlNetWc *self);
 
65
 
 
66
void cache_down (GrlNetWc *self);
 
67
 
 
68
void cache_up (GrlNetWc *self);
 
69
 
 
70
gboolean cache_is_available (GrlNetWc *self);
 
71
 
 
72
void cache_set_size (GrlNetWc *self, guint size);
 
73
 
 
74
guint cache_get_size (GrlNetWc *self);
 
75
 
 
76
void free_op_res (void *op);
 
77
 
 
78
G_END_DECLS
 
79
 
 
80
#endif /* _GRL_NET_PRIVATE_H_ */