diff options
Diffstat (limited to 'src/fs/download.h')
-rw-r--r-- | src/fs/download.h | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/src/fs/download.h b/src/fs/download.h new file mode 100644 index 00000000..e2c8767b --- /dev/null +++ b/src/fs/download.h | |||
@@ -0,0 +1,83 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | (C) 2010 Christian Grothoff (and other contributing authors) | ||
4 | |||
5 | GNUnet is free software; you can redistribute it and/or modify | ||
6 | it under the terms of the GNU General Public License as published | ||
7 | by the Free Software Foundation; either version 2, or (at your | ||
8 | option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU General Public License | ||
16 | along with GNUnet; see the file COPYING. If not, write to the | ||
17 | Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
18 | Boston, MA 02111-1307, USA. | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file src/download.h | ||
23 | * @brief functions for downloading | ||
24 | * @author Christian Grothoff | ||
25 | */ | ||
26 | |||
27 | #ifndef DOWNLOAD_H | ||
28 | #define DOWNLOAD_H | ||
29 | #include "common.h" | ||
30 | |||
31 | /** | ||
32 | * Information we keep for a download. | ||
33 | */ | ||
34 | struct DownloadContext | ||
35 | { | ||
36 | /** | ||
37 | * URI for the download. | ||
38 | */ | ||
39 | struct GNUNET_FS_Uri *uri; | ||
40 | |||
41 | /** | ||
42 | * Meta data. | ||
43 | */ | ||
44 | struct GNUNET_CONTAINER_MetaData *meta; | ||
45 | |||
46 | /** | ||
47 | * Mime type. | ||
48 | */ | ||
49 | char *mime; | ||
50 | |||
51 | /** | ||
52 | * Suggested filename, or NULL. | ||
53 | */ | ||
54 | char *filename; | ||
55 | |||
56 | /** | ||
57 | * Row reference (if URI was found by search, or | ||
58 | * part of directory, etc.); otherwise NULL (download by URI). | ||
59 | */ | ||
60 | GtkTreeRowReference *rr; | ||
61 | |||
62 | /** | ||
63 | * Associated search result, or NULL. | ||
64 | */ | ||
65 | struct GNUNET_FS_SearchResult *sr; | ||
66 | |||
67 | /** | ||
68 | * Is this a recursive download? | ||
69 | */ | ||
70 | int is_recursive; | ||
71 | |||
72 | /** | ||
73 | * Desired (default) anonymity level. | ||
74 | */ | ||
75 | int anonymity; | ||
76 | }; | ||
77 | |||
78 | |||
79 | |||
80 | void | ||
81 | GNUNET_GTK_open_download_as_dialog (struct DownloadContext *dc); | ||
82 | |||
83 | #endif | ||