diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-01-30 16:02:52 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-01-30 16:02:52 +0000 |
commit | bc0e1c956bef848d2569e0c56ccbda13597418f7 (patch) | |
tree | 88d82a018890ed112c61f21fe2f38e2fe1edc89f /src/fs/gnunet-service-fs_pr.h | |
parent | dee60c25690117fabb90b497dbe23378b3e00db1 (diff) | |
download | gnunet-bc0e1c956bef848d2569e0c56ccbda13597418f7.tar.gz gnunet-bc0e1c956bef848d2569e0c56ccbda13597418f7.zip |
stuff
Diffstat (limited to 'src/fs/gnunet-service-fs_pr.h')
-rw-r--r-- | src/fs/gnunet-service-fs_pr.h | 62 |
1 files changed, 35 insertions, 27 deletions
diff --git a/src/fs/gnunet-service-fs_pr.h b/src/fs/gnunet-service-fs_pr.h index b4dd82839..24107534f 100644 --- a/src/fs/gnunet-service-fs_pr.h +++ b/src/fs/gnunet-service-fs_pr.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | (C) 2009, 2010 Christian Grothoff (and other contributing authors) | 3 | (C) 2009, 2010, 2011 Christian Grothoff (and other contributing authors) |
4 | 4 | ||
5 | GNUnet is free software; you can redistribute it and/or modify | 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 | 6 | it under the terms of the GNU General Public License as published |
@@ -120,6 +120,40 @@ GSF_pending_request_create_ (enum GSF_PendingRequestOptions options, | |||
120 | 120 | ||
121 | 121 | ||
122 | /** | 122 | /** |
123 | * Update a given pending request with additional replies | ||
124 | * that have been seen. | ||
125 | * | ||
126 | * @param pr request to update | ||
127 | * @param replies_seen hash codes of replies that we've seen | ||
128 | * @param replies_seen_count size of the replies_seen array | ||
129 | */ | ||
130 | void | ||
131 | GSF_pending_request_update_ (struct GSF_PendingRequest *pr, | ||
132 | const GNUNET_HashCode *replies_seen, | ||
133 | unsigned int replies_seen_count); | ||
134 | |||
135 | |||
136 | /** | ||
137 | * Get the query for a given pending request. | ||
138 | * | ||
139 | * @param pr the request | ||
140 | * @return pointer to the query (only valid as long as pr is valid) | ||
141 | */ | ||
142 | const GNUNET_HashCode * | ||
143 | GSF_pending_request_get_query_ (const struct GSF_PendingRequest *pr); | ||
144 | |||
145 | |||
146 | /** | ||
147 | * Get the type of a given pending request. | ||
148 | * | ||
149 | * @param pr the request | ||
150 | * @return query type | ||
151 | */ | ||
152 | enum GNUNET_BLOCK_Type | ||
153 | GSF_pending_request_get_type_ (const struct GSF_PendingRequest *pr); | ||
154 | |||
155 | |||
156 | /** | ||
123 | * Generate the message corresponding to the given pending request for | 157 | * Generate the message corresponding to the given pending request for |
124 | * transmission to other peers (or at least determine its size). | 158 | * transmission to other peers (or at least determine its size). |
125 | * | 159 | * |
@@ -167,31 +201,5 @@ GSF_iterate_pending_requests_ (GSF_PendingRequestIterator it, | |||
167 | 201 | ||
168 | 202 | ||
169 | 203 | ||
170 | /** | ||
171 | * Register callback to invoke on request destruction. | ||
172 | * | ||
173 | * @param pr request to monitor | ||
174 | * @param it function to call on destruction | ||
175 | * @param it_cls closure for it | ||
176 | */ | ||
177 | void | ||
178 | GSF_pending_request_register_destroy_callback_ (struct GSF_PendingRequest *pr, | ||
179 | GSF_PendingRequestIterator it, | ||
180 | void *it_cls); | ||
181 | |||
182 | |||
183 | /** | ||
184 | * Unregister callback to invoke on request destruction. | ||
185 | * | ||
186 | * @param pr request to stop monitoring | ||
187 | * @param it function to no longer call on destruction | ||
188 | * @param it_cls closure for it | ||
189 | */ | ||
190 | void | ||
191 | GSF_pending_request_unregister_destroy_callback_ (struct GSF_PendingRequest *pr, | ||
192 | GSF_PendingRequestIterator it, | ||
193 | void *it_cls); | ||
194 | |||
195 | |||
196 | #endif | 204 | #endif |
197 | /* end of gnunet-service-fs_pr.h */ | 205 | /* end of gnunet-service-fs_pr.h */ |