/*
This file is part of GNUnet
- (C) 2009, 2011 Christian Grothoff (and other contributing authors)
+ Copyright (C) 2009, 2011 GNUnet e.V.
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
You should have received a copy of the GNU General Public License
along with GNUnet; see the file COPYING. If not, write to the
- Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- Boston, MA 02111-1307, USA.
+ Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
*/
/**
* @param anonymity anonymity-level for the content
* @param replication replication-level for the content
* @param expiration expiration time for the content
- * @param msg set to error message
- * @return GNUNET_OK on success
+ * @param cont continuation called with success or failure status
+ * @param cont_cls continuation closure
*/
-static int
+static void
template_plugin_put (void *cls, const struct GNUNET_HashCode * key, uint32_t size,
const void *data, enum GNUNET_BLOCK_Type type,
uint32_t priority, uint32_t anonymity,
uint32_t replication,
- struct GNUNET_TIME_Absolute expiration, char **msg)
+ struct GNUNET_TIME_Absolute expiration, PluginPutCont cont,
+ void *cont_cls)
{
GNUNET_break (0);
- *msg = GNUNET_strdup ("not implemented");
- return GNUNET_SYSERR;
+ cont (cont_cls, key, size, GNUNET_SYSERR, "not implemented");
}
* @param expire new expiration time should be the
* MAX of any existing expiration time and
* this value
- * @param msg set to error message
- * @return GNUNET_OK on success
+ * @param cont continuation called with success or failure status
+ * @param cons_cls continuation closure
*/
-static int
+static void
template_plugin_update (void *cls, uint64_t uid, int delta,
- struct GNUNET_TIME_Absolute expire, char **msg)
+ struct GNUNET_TIME_Absolute expire,
+ PluginUpdateCont cont, void *cont_cls)
{
GNUNET_break (0);
- *msg = GNUNET_strdup ("not implemented");
- return GNUNET_SYSERR;
+ cont (cont_cls, GNUNET_SYSERR, "not implemented");
}
PluginKeyProcessor proc,
void *proc_cls)
{
+ proc (proc_cls, NULL, 0);
}