Thu, 22 Jan 2015 13:21:57 +0100
Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6
michael@0 | 1 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 2 | * License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 3 | * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
michael@0 | 4 | |
michael@0 | 5 | #ifndef mozilla_net_DashboardTypes_h_ |
michael@0 | 6 | #define mozilla_net_DashboardTypes_h_ |
michael@0 | 7 | |
michael@0 | 8 | #include "nsString.h" |
michael@0 | 9 | #include "nsTArray.h" |
michael@0 | 10 | |
michael@0 | 11 | namespace mozilla { |
michael@0 | 12 | namespace net { |
michael@0 | 13 | |
michael@0 | 14 | struct SocketInfo |
michael@0 | 15 | { |
michael@0 | 16 | nsCString host; |
michael@0 | 17 | uint64_t sent; |
michael@0 | 18 | uint64_t received; |
michael@0 | 19 | uint16_t port; |
michael@0 | 20 | bool active; |
michael@0 | 21 | bool tcp; |
michael@0 | 22 | }; |
michael@0 | 23 | |
michael@0 | 24 | struct HalfOpenSockets |
michael@0 | 25 | { |
michael@0 | 26 | bool speculative; |
michael@0 | 27 | }; |
michael@0 | 28 | |
michael@0 | 29 | struct DNSCacheEntries |
michael@0 | 30 | { |
michael@0 | 31 | nsCString hostname; |
michael@0 | 32 | nsTArray<nsCString> hostaddr; |
michael@0 | 33 | uint16_t family; |
michael@0 | 34 | int64_t expiration; |
michael@0 | 35 | }; |
michael@0 | 36 | |
michael@0 | 37 | struct HttpConnInfo |
michael@0 | 38 | { |
michael@0 | 39 | uint32_t ttl; |
michael@0 | 40 | uint32_t rtt; |
michael@0 | 41 | nsString protocolVersion; |
michael@0 | 42 | |
michael@0 | 43 | void SetHTTP1ProtocolVersion(uint8_t pv); |
michael@0 | 44 | void SetHTTP2ProtocolVersion(uint8_t pv); |
michael@0 | 45 | }; |
michael@0 | 46 | |
michael@0 | 47 | struct HttpRetParams |
michael@0 | 48 | { |
michael@0 | 49 | nsCString host; |
michael@0 | 50 | nsTArray<HttpConnInfo> active; |
michael@0 | 51 | nsTArray<HttpConnInfo> idle; |
michael@0 | 52 | nsTArray<HalfOpenSockets> halfOpens; |
michael@0 | 53 | uint32_t counter; |
michael@0 | 54 | uint16_t port; |
michael@0 | 55 | bool spdy; |
michael@0 | 56 | bool ssl; |
michael@0 | 57 | }; |
michael@0 | 58 | |
michael@0 | 59 | } } |
michael@0 | 60 | |
michael@0 | 61 | #endif // mozilla_net_DashboardTypes_h_ |