hanyizhao / NetSpeedMonitor

This is a net speed monitor just like 360 for windows user.
766 stars 113 forks source link

List & Switch Between Network Adapter #2

Closed Riajyuu closed 6 years ago

Riajyuu commented 6 years ago

Now it seems only using network portal stats.

hanyizhao commented 6 years ago

There are several network adapters in one PC. Thus, this PC has several IP addresses and this PC is in several subnets at the same time.

Now we analyze each packet. One packet maybe transfers

  1. from one subnet to another subnet. (just possible)
  2. from one IP address which belongs to this PC to another subnet. (For example, we transfer some data to our friends and we are in one subnet)
  3. from one IP address which belongs to this PC to another IP address. (For example, we open the Chrome and visit github.com)
  4. from one subnet to somewhere we don't know now (Maybe Internet). (For example, we use this PC to be a hotspot. Others visit internet via this PC.)

So, there are so many possibilities. Fortunately, we have dealt with all possibilities. See NetworkStructure.cs for more details.