- wip
[oweals/gnunet.git] / src / include / gnunet_transport_service.h
index 0885ac56578f27c27b9bc19775debd55e0fc195b..817d3a18f6832e404b2d45ab8e8527dcffcefdc6 100644 (file)
@@ -43,14 +43,6 @@ extern "C"
  */
 #define GNUNET_TRANSPORT_VERSION 0x00000000
 
-// FIXME-mwachs; move this into some src/transport/-internal header!
-enum TRAFFIC_METRIC_DIRECTION
-{
-       TM_SEND = 0,
-       TM_RECEIVE = 1,
-       TM_BOTH = 2
-};
-
 
 /**
  * Function called by the transport for each received message.
@@ -66,10 +58,7 @@ typedef void (*GNUNET_TRANSPORT_ReceiveCallback) (void *cls,
                                                   GNUNET_PeerIdentity * peer,
                                                   const struct
                                                   GNUNET_MessageHeader *
-                                                  message,
-                                                  const struct
-                                                  GNUNET_ATS_Information * ats,
-                                                  uint32_t ats_count);
+                                                  message);
 
 
 /**
@@ -89,10 +78,7 @@ struct GNUNET_TRANSPORT_Handle;
  */
 typedef void (*GNUNET_TRANSPORT_NotifyConnect) (void *cls,
                                                 const struct GNUNET_PeerIdentity
-                                                * peer,
-                                                const struct
-                                                GNUNET_ATS_Information * ats,
-                                                uint32_t ats_count);
+                                                * peer);
 
 /**
  * Function called to notify transport users that another
@@ -212,6 +198,7 @@ GNUNET_TRANSPORT_try_connect (struct GNUNET_TRANSPORT_Handle *handle,
 void
 GNUNET_TRANSPORT_try_connect_cancel (struct GNUNET_TRANSPORT_TryConnectHandle *tch);
 
+
 /**
  * Opaque handle for a transmission-ready request.
  */
@@ -295,7 +282,8 @@ GNUNET_TRANSPORT_check_neighbour_connected (struct GNUNET_TRANSPORT_Handle *hand
  *
  * @param handle transport handle
  * @param peer the peer to set the metric for
- * @param direction can be: TM_SEND, TM_RECV, TM_BOTH
+ * @param inbound set inbound direction (GNUNET_YES or GNUNET_NO)
+ * @param outbound set outbound direction (GNUNET_YES or GNUNET_NO)
  * @param ats the metric as ATS information
  * @param ats_count the number of metrics
  *
@@ -317,10 +305,11 @@ GNUNET_TRANSPORT_check_neighbour_connected (struct GNUNET_TRANSPORT_Handle *hand
  */
 void
 GNUNET_TRANSPORT_set_traffic_metric (struct GNUNET_TRANSPORT_Handle *handle,
-                                                                                                                                               const struct GNUNET_PeerIdentity *peer,
-                                                                                                                                               int direction,
-                                                                                                                                               const struct GNUNET_ATS_Information *ats,
-                                                                                                                                               size_t ats_count);
+                                    const struct GNUNET_PeerIdentity *peer,
+                                    int inbound,
+                                    int outbound,
+                                    const struct GNUNET_ATS_Information *ats,
+                                    size_t ats_count);
 
 
 /**
@@ -376,6 +365,7 @@ GNUNET_TRANSPORT_offer_hello (struct GNUNET_TRANSPORT_Handle *handle,
 void
 GNUNET_TRANSPORT_offer_hello_cancel (struct GNUNET_TRANSPORT_OfferHelloHandle *ohh);
 
+
 /**
  * Handle to cancel a pending address lookup.
  */