indent
[oweals/gnunet.git] / src / ats / gnunet-service-ats_addresses.h
index 3c2e040f2363506cde134a02637a8e1555e6ade1..4f17fd9123aa0b7dd644f6750966d8e9ea4969d5 100644 (file)
  *    it as a value_number. If no configuration value is found it will assign
  *    GNUNET_ATS_DefaultBandwidth. The most important step is to load the
  *    configured solver using configuration "[ats]:MODE". Current solvers are
- *    MODE_SIMPLISTIC, MODE_MLP. Interaction is done using a solver API
+ *    MODE_PROPORTIONAL, MODE_MLP. Interaction is done using a solver API
  *
  *     1.4 Solver API
  *
@@ -448,6 +448,25 @@ typedef void
                                                                                                                                                                 enum GNUNET_ATS_PreferenceKind kind,
                                                                                                                                                                 double pref_rel);
 
+
+/**
+ * Give feedback about the current assignment
+ *
+ * @param handle the solver handle
+ * @param application the application sending this request
+ * @param peer the peer id
+ * @param scope the time interval for this feedback: [now - scope .. now]
+ * @param kind the preference kind for this feedback
+ * @param score the feedback score
+ */
+typedef void
+(*GAS_solver_address_feedback_preference) (void *solver,
+                                                                                                                                                                void *application,
+                                                                                                                                                                const struct GNUNET_PeerIdentity *peer,
+                                                                                                                                                                const struct GNUNET_TIME_Relative scope,
+                                                                                                                                                                enum GNUNET_ATS_PreferenceKind kind,
+                                                                                                                                                                double score);
+
 /**
  * Notify the solver about a bulk operation changing possibly a lot of values
  * Solver will not resolve until all bulk operations are marked as done
@@ -775,6 +794,25 @@ GAS_addresses_change_preference (struct GAS_Addresses_Handle *handle,
                                  float score_abs);
 
 
+/**
+ * Change the preference for a peer
+ *
+ * @param handle the address handle
+ * @param application the client sending this request
+ * @param peer the peer id
+ * @param scope the time interval this valid for: [now - scope .. now]
+ * @param kind the preference kind to change
+ * @param score_abs the new preference score
+ */
+void
+GAS_addresses_preference_feedback (struct GAS_Addresses_Handle *handle,
+                                                                                                                                               void *application,
+                                                                                                                                               const struct GNUNET_PeerIdentity *peer,
+                                                                                                                                               const struct GNUNET_TIME_Relative scope,
+                                                                                                                                               enum GNUNET_ATS_PreferenceKind kind,
+                                                                                                                                               float score_abs);
+
+
 /**
  * Iterator for GAS_addresses_iterate_peers
  *