-struct GNUNET_STATISTICS_Handle
- *GNUNET_STATISTICS_create (struct GNUNET_SCHEDULER_Handle *sched,
- const char *subsystem,
- const struct GNUNET_CONFIGURATION_Handle *cfg);
+struct GNUNET_STATISTICS_Handle *
+GNUNET_STATISTICS_create (const char *subsystem,
+ const struct GNUNET_CONFIGURATION_Handle *cfg);
+
+
+/**
+ * Destroy a handle (free all state associated with it).
+ *
+ * @param h statistics handle to destroy
+ * @param sync_first set to #GNUNET_YES if pending SET requests should
+ * be completed
+ */
+void
+GNUNET_STATISTICS_destroy (struct GNUNET_STATISTICS_Handle *h,
+ int sync_first);
+
+
+/**
+ * Watch statistics from the peer (be notified whenever they change).
+ *
+ * @param handle identification of the statistics service
+ * @param subsystem limit to the specified subsystem, never NULL
+ * @param name name of the statistic value, never NULL
+ * @param proc function to call on each value
+ * @param proc_cls closure for @a proc
+ * @return #GNUNET_OK on success, #GNUNET_SYSERR on error
+ */
+int
+GNUNET_STATISTICS_watch (struct GNUNET_STATISTICS_Handle *handle,
+ const char *subsystem,
+ const char *name,
+ GNUNET_STATISTICS_Iterator proc,
+ void *proc_cls);