Chromium Code Reviews| Index: webrtc/p2p/stunprober/stunprober.h |
| diff --git a/webrtc/p2p/stunprober/stunprober.h b/webrtc/p2p/stunprober/stunprober.h |
| index 9352e36dbc574f2346046381b73484939c792a30..f7068b447f60484b46b5d6c5589cb8e37ce3530d 100644 |
| --- a/webrtc/p2p/stunprober/stunprober.h |
| +++ b/webrtc/p2p/stunprober/stunprober.h |
| @@ -137,12 +137,20 @@ class StunProber { |
| READ_FAILED, // Reading the reply from the server failed. |
| }; |
| + enum NATTYPE { |
|
pthatcher2
2015/06/05 22:39:41
NatType, please.
guoweis_webrtc
2015/06/07 17:29:40
Done.
|
| + NATTYPE_UNKNOWN, |
| + NATTYPE_NO_NAT, |
| + NATTYPE_NAT_TYPE_UNKNOWN, |
| + NATTYPE_SYM_NAT, |
| + NATTYPE_NON_SYM_NAT |
| + }; |
| + |
| struct Stats { |
| Stats() {} |
| + |
| int num_request_sent = 0; |
| int num_response_received = 0; |
| - bool behind_nat = false; |
| - bool symmetric_nat = false; |
| + NATTYPE nat_type = NATTYPE_UNKNOWN; |
| int average_rtt_ms = -1; |
| int success_percent = 0; |
| int target_request_interval_ns = 0; |
| @@ -188,7 +196,7 @@ class StunProber { |
| // Method to retrieve the Stats once |finish_callback| is invoked. Returning |
| // false when the result is inconclusive, for example, whether it's behind a |
| // NAT or not. |
| - bool GetStats(Stats* stats); |
| + bool GetStats(Stats* stats) const; |
| private: |
| // A requester tracks the requests and responses from a single socket to many |