Data flow counting method and terminal
A technology of data traffic and statistical methods, applied in electrical components, wireless communication, etc., can solve problems such as inability to distinguish the generation and use of data traffic
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0021] figure 1 A flow of a method for counting data traffic provided by an embodiment of the present invention is shown, and only parts related to the embodiment of the present invention are shown for ease of description.
[0022] In step S101, when a network connection is generated, a single application that is currently connected to the network is obtained and a data traffic value is calculated.
[0023] Among them, each single application has a unique application package name. In this step, the network connection needs to be monitored. When a network connection occurs, the package name of the single application that is currently connected to the network is obtained according to the connection request of the network port, and according to the The package name identifies the single application currently making the network connection. After obtaining the single application that is currently connected to the network, start to calculate the data traffic value.
[0024] In ste...
Embodiment 2
[0030] figure 2 A flow of a method for counting data traffic provided by the second embodiment of the present invention is shown, and only parts related to the embodiment of the present invention are shown for convenience of description.
[0031] In step S201, a flow database is established, and a total value of data flow is established for each single application with network connection authority.
[0032] In this step, it is first necessary to analyze which of the installed single applications have network connection permissions, and establish a traffic database, and establish the total data traffic values for these single applications. In this step, the total value of data flow is stored by establishing a database, which is convenient for unified management and calling of flow data.
[0033] In step S202, when a network connection is generated, a single application currently generating data traffic is obtained and data traffic value is calculated.
[0034] In this step...
Embodiment 3
[0052] image 3 A structural block diagram of a terminal provided by the third embodiment of the present invention is shown, and only parts related to the embodiment of the present invention are shown for convenience of description.
[0053] In the illustration, the device includes:
[0054] The network connection single application obtaining unit 301 is configured to obtain a current network connection single application and start to calculate the data traffic value when a network connection is generated.
[0055] Wherein, each single application has a unique application package name, and the network connection single application acquisition unit needs to monitor the network connection, and when a network connection is generated, obtain the package name of the current network connection single application according to the connection request of the network port , and determine the single application that is currently connected to the network according to the package name. Af...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 