分类: 嵌入式
2010-12-03 10:28:45
Certainly non trivial... 650Mhz device (from-to; expressed in ss.mmm format)
Connected to PC
IsNetworkAvailable(): 26.598-26.705
NetworkInterfaceType: 26.709-27.265
Wireless
IsNetworkAvailable(): 15.574-15.610
NetworkInterfaceType: 16.611-16.470
None
IsNetworkAvailable(): 2.305-2.341
NetworkInterfaceType: 2.342-3.633, 47.313-50.641, 22.608-23.964, 44.610-46.051
So with connection NetworkInterfaceType appeared to swing between 550ms and 900ms .
Without connection between 1.3s and 3.3s .
It does seem worth the trouble to hide the detail of calling IsNetworkAvailable on device and NetworkInterfaceType on emulator via an abstraction of your choosing.