CN106899987B - Method and device for calibrating data flow of mobile terminal - Google Patents
Method and device for calibrating data flow of mobile terminal Download PDFInfo
- Publication number
- CN106899987B CN106899987B CN201510964220.0A CN201510964220A CN106899987B CN 106899987 B CN106899987 B CN 106899987B CN 201510964220 A CN201510964220 A CN 201510964220A CN 106899987 B CN106899987 B CN 106899987B
- Authority
- CN
- China
- Prior art keywords
- traffic
- query
- mobile terminal
- query result
- type
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 46
- 238000004891 communication Methods 0.000 claims abstract description 53
- 230000014509 gene expression Effects 0.000 claims description 27
- 230000006870 function Effects 0.000 description 11
- 238000012545 processing Methods 0.000 description 4
- 230000008901 benefit Effects 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 238000004590 computer program Methods 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 238000000429 assembly Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000012217 deletion Methods 0.000 description 1
- 230000037430 deletion Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W24/00—Supervisory, monitoring or testing arrangements
- H04W24/02—Arrangements for optimising operational condition
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/24—Accounting or billing
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Mobile Radio Communication Systems (AREA)
- Telephonic Communication Services (AREA)
Abstract
Description
技术领域technical field
本发明涉及网络通信技术领域,具体涉及一种对移动终端的数据流量进行校准的方法及装置。The present invention relates to the technical field of network communication, in particular to a method and device for calibrating data traffic of a mobile terminal.
背景技术Background technique
随着智能移动终端的普及,越来越多的用户习惯于通过移动终端访问互联网,以便随时获取各类网络信息。运营商一般会根据移动终端获取网络信息时所产生的数据流量收取相应的流量资费。为了将移动终端的流量资费控制在合理限度内,通常情况下,用户可以在移动终端上安装流量监控软件,由该流量监控软件在后台实时监控移动终端的数据流量使用情况。With the popularization of intelligent mobile terminals, more and more users are accustomed to accessing the Internet through mobile terminals in order to obtain various network information at any time. Operators generally charge corresponding traffic charges according to the data traffic generated when the mobile terminal obtains network information. In order to control the traffic tariff of the mobile terminal within a reasonable limit, usually, the user can install traffic monitoring software on the mobile terminal, and the traffic monitoring software can monitor the data traffic usage of the mobile terminal in real time in the background.
但是,流量监控软件所统计的数据流量与运营商统计的数据流量经常会出现不一致的情况:例如,由于计费规则不同,导致本地设备上安装的流量监控软件所统计的流量包含移动终端所产生的全部数据流量,而运营商计费时可能会将流量进一步划分为普通流量、定向流量、优惠流量等多种类型,所以运营商可能仅统计普通流量,从而导致二者出现不一致的情况。另外,还有些业务因其属于免流量下载的业务范畴而不予计费,例如,免流量专区中提供的应用、彩信业务等。又如,本地设备上安装的流量监控软件无法统计网关重传的流量,而运营商所统计的数据流量中却包含网关重传的数据流量,从而导致二者出现不一致的情况。However, the data traffic counted by the traffic monitoring software is often inconsistent with the data traffic counted by the operator: for example, due to different billing rules, the traffic counted by the traffic monitoring software installed on the local device includes the traffic generated by the mobile terminal. However, the operator may further divide the traffic into various types such as ordinary traffic, directional traffic, preferential traffic, etc., so the operator may only count the ordinary traffic, resulting in inconsistency between the two. In addition, some services are not billed because they belong to the business category of free-flow download, for example, applications provided in the free-flow zone, MMS services, and so on. For another example, the traffic monitoring software installed on the local device cannot count the traffic retransmitted by the gateway, but the data traffic counted by the operator includes the data traffic retransmitted by the gateway, resulting in inconsistency between the two.
总之,现有的流量监控软件所统计的数据流量与运营商统计的数据流量存在误差,因而无法为用户提供准确的流量使用信息,进而导致用户无法根据流量监控软件统计的数据流量准确管理流量资费。In a word, there is a discrepancy between the data traffic counted by the existing traffic monitoring software and the data traffic counted by the operator, so it is impossible to provide users with accurate traffic usage information, which in turn makes it impossible for users to accurately manage traffic charges based on the data traffic counted by the traffic monitoring software. .
发明内容SUMMARY OF THE INVENTION
鉴于上述问题,提出了本发明以便提供一种克服上述问题或者至少部分地解决上述问题的对移动终端的数据流量进行校准的方法及装置。In view of the above problems, the present invention is proposed in order to provide a method and apparatus for calibrating data traffic of a mobile terminal which overcomes the above problems or at least partially solves the above problems.
依据本发明的一个方面,提供了一种对移动终端的数据流量进行校准的方法,包括:根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求;接收所述运营商服务器返回的流量查询结果,根据预先设置的解析规则对所述流量查询结果进行解析,以获取其中包含的流量信息;将所述流量信息发送给所述移动终端,以供所述移动终端根据所述流量信息对本地设备统计的数据流量进行校准。According to one aspect of the present invention, a method for calibrating data traffic of a mobile terminal is provided, comprising: sending traffic to an operator server according to a communication service type of the mobile terminal and a traffic query instruction corresponding to the type of communication service query request; receive the traffic query result returned by the operator server, parse the traffic query result according to a preset parsing rule to obtain the traffic information contained therein; send the traffic information to the mobile terminal, for the mobile terminal to calibrate the data traffic counted by the local device according to the traffic information.
依据本发明的另一方面,提供了一种对移动终端的数据流量进行校准的装置,包括:查询模块,适于根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求;解析模块,适于接收所述运营商服务器返回的流量查询结果,根据预先设置的解析规则对所述流量查询结果进行解析,以获取其中包含的流量信息;发送模块,适于将所述流量信息发送给所述移动终端,以供所述移动终端根据所述流量信息对本地设备统计的数据流量进行校准。According to another aspect of the present invention, a device for calibrating data traffic of a mobile terminal is provided, comprising: a query module adapted to query the command according to the communication service type of the mobile terminal and the traffic corresponding to the type of communication service Send a traffic query request to the operator server; a parsing module, adapted to receive the traffic query result returned by the operator server, and parse the traffic query result according to a preset parsing rule to obtain the traffic information contained therein; send The module is adapted to send the traffic information to the mobile terminal, so that the mobile terminal can calibrate the data traffic counted by the local device according to the traffic information.
在本发明提供的对移动终端的数据流量进行校准的方法及装置中,能够根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求,并根据运营商服务器返回的流量查询结果对移动终端的数据流量进行校准,从而克服了本地设备所统计的数据流量与运营商统计的数据流量存在误差的技术问题,因而使用户能够根据本地设备统计的数据流量准确管理流量资费。具体地,在本发明中,通过预先设置的解析规则对运营商服务器返回的流量查询结果进行解析,以获取其中包含的流量信息,从而提高了解析的效率和准确性。In the method and device for calibrating data traffic of a mobile terminal provided by the present invention, a traffic query request can be sent to an operator server according to a communication service type of the mobile terminal and a traffic query instruction corresponding to the type of communication service, and The data traffic of the mobile terminal is calibrated according to the traffic query result returned by the operator's server, so as to overcome the technical problem of the discrepancy between the data traffic counted by the local device and the data traffic counted by the operator, thus enabling the user to Data traffic accurately manages traffic tariffs. Specifically, in the present invention, the traffic query result returned by the operator server is parsed through preset parsing rules to obtain the traffic information contained therein, thereby improving the efficiency and accuracy of the parsing.
上述说明仅是本发明技术方案的概述,为了能够更清楚了解本发明的技术手段,而可依照说明书的内容予以实施,并且为了让本发明的上述和其它目的、特征和优点能够更明显易懂,以下特举本发明的具体实施方式。The above description is only an overview of the technical solutions of the present invention, in order to be able to understand the technical means of the present invention more clearly, it can be implemented according to the content of the description, and in order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand , the following specific embodiments of the present invention are given.
附图说明Description of drawings
通过阅读下文优选实施方式的详细描述,各种其他的优点和益处对于本领域普通技术人员将变得清楚明了。附图仅用于示出优选实施方式的目的,而并不认为是对本发明的限制。而且在整个附图中,用相同的参考符号表示相同的部件。在附图中:Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are for the purpose of illustrating preferred embodiments only and are not to be considered limiting of the invention. Also, the same components are denoted by the same reference numerals throughout the drawings. In the attached image:
图1示出了本发明提供的一种对移动终端的数据流量进行校准的方法的流程图;1 shows a flowchart of a method for calibrating data traffic of a mobile terminal provided by the present invention;
图2示出了本发明另一具体实施例提供的一种对移动终端的数据流量进行校准的方法的流程图;以及,FIG. 2 shows a flowchart of a method for calibrating data traffic of a mobile terminal provided by another specific embodiment of the present invention; and,
图3示出了本发明提供的一种对移动终端的数据流量进行校准的装置的结构图。FIG. 3 shows a structural diagram of an apparatus for calibrating data traffic of a mobile terminal provided by the present invention.
具体实施方式Detailed ways
下面将参照附图更详细地描述本公开的示例性实施例。虽然附图中显示了本公开的示例性实施例,然而应当理解,可以以各种形式实现本公开而不应被这里阐述的实施例所限制。相反,提供这些实施例是为了能够更透彻地理解本公开,并且能够将本公开的范围完整的传达给本领域的技术人员。Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that the present disclosure will be more thoroughly understood, and will fully convey the scope of the present disclosure to those skilled in the art.
本发明实施例提供了一种对移动终端的数据流量进行校准的方法及装置,至少能够解决现有的流量监控软件无法为用户提供准确的流量使用信息的技术问题。The embodiments of the present invention provide a method and device for calibrating data traffic of a mobile terminal, which can at least solve the technical problem that existing traffic monitoring software cannot provide users with accurate traffic usage information.
图1示出了本发明提供的一种对移动终端的数据流量进行校准的方法的流程图。如图1所示,该方法包括以下步骤:FIG. 1 shows a flowchart of a method for calibrating data traffic of a mobile terminal provided by the present invention. As shown in Figure 1, the method includes the following steps:
步骤S110:根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求。Step S110: Send a traffic query request to the operator server according to the communication service type of the mobile terminal and the traffic query instruction corresponding to the communication service of the type.
其中,移动终端的通信业务类型包括移动、联通、电信等多种类型,且各个类型还可以进一步分为多个子类型。各种通信业务类型对应的流量查询指令可以根据相应运营商提供的流量查询方式进行确定。Among them, the communication service types of the mobile terminal include multiple types such as mobile, China Unicom, and telecommunications, and each type can be further divided into multiple sub-types. The traffic query instructions corresponding to various communication service types can be determined according to the traffic query method provided by the corresponding operator.
步骤S120:接收运营商服务器返回的流量查询结果,根据预先设置的解析规则对流量查询结果进行解析,以获取其中包含的流量信息。Step S120: Receive the traffic query result returned by the operator server, and parse the traffic query result according to a preset parsing rule to obtain the traffic information contained therein.
其中,解析规则可以通过以下方式设置:预先收集各种类型的通信业务所对应的流量查询结果,根据流量查询结果中包含的标识信息,将流量查询结果划分为多种类型;分别分析每种类型的流量查询结果中包含的流量信息的种类以及与各种流量信息相对应的信息字段的格式规范;根据信息字段的格式规范分别为每种类型的流量查询结果设定相应的正则表达式匹配规则。Among them, the parsing rules can be set in the following ways: collecting the traffic query results corresponding to various types of communication services in advance, dividing the traffic query results into multiple types according to the identification information contained in the traffic query results; analyzing each type separately The type of traffic information contained in the traffic query results of the corresponding traffic information and the format specification of the information fields corresponding to various traffic information; according to the format specifications of the information fields, the corresponding regular expression matching rules are set for each type of traffic query results. .
相应地,根据预先设置的解析规则对流量查询结果进行解析的步骤包括:根据运营商服务器返回的流量查询结果中包含的标识信息确定流量查询结果的类型;获取与该类型的流量查询结果相对应的正则表达式匹配规则;根据正则表达式匹配规则对运营商服务器返回的流量查询结果中的各个字符进行匹配,以获取其中包含的各种流量信息的数值。Correspondingly, the step of analyzing the traffic query result according to the preset parsing rule includes: determining the type of the traffic query result according to the identification information contained in the traffic query result returned by the operator server; obtaining the traffic query result corresponding to the type. The regular expression matching rules of ; match each character in the traffic query result returned by the operator server according to the regular expression matching rules to obtain the numerical values of various traffic information contained therein.
步骤S130:将流量信息发送给移动终端,以供移动终端根据流量信息对本地设备统计的数据流量进行校准。Step S130: Send the traffic information to the mobile terminal, so that the mobile terminal can calibrate the data traffic counted by the local device according to the traffic information.
由此可见,在本发明提供的方法中,能够根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求,并根据运营商服务器返回的流量查询结果对移动终端的数据流量进行校准,从而克服了本地设备所统计的数据流量与运营商统计的数据流量存在误差的技术问题,因而使用户能够根据本地设备统计的数据流量准确管理流量资费。具体地,在本发明中,通过预先设置的解析规则对运营商服务器返回的流量查询结果进行解析,以获取其中包含的流量信息,从而提高了解析的效率和准确性。It can be seen that, in the method provided by the present invention, the traffic query request can be sent to the operator server according to the communication service type of the mobile terminal and the traffic query instruction corresponding to the communication service of the type, and the traffic flow returned by the operator server can be sent according to the The query result calibrates the data flow of the mobile terminal, thereby overcoming the technical problem of the discrepancy between the data flow counted by the local device and the data flow counted by the operator, thus enabling the user to accurately manage the flow rate according to the data flow counted by the local device. Specifically, in the present invention, the traffic query result returned by the operator server is parsed through preset parsing rules to obtain the traffic information contained therein, thereby improving the efficiency and accuracy of the parsing.
图2示出了本发明另一具体实施例提供的一种对移动终端的数据流量进行校准的方法的流程图。如图2所示,该方法包括以下步骤:FIG. 2 shows a flowchart of a method for calibrating data traffic of a mobile terminal according to another specific embodiment of the present invention. As shown in Figure 2, the method includes the following steps:
步骤S210:获取待校准的各个移动终端的通信业务类型。Step S210: Obtain the communication service type of each mobile terminal to be calibrated.
在本实施例中,能够通过流量校准服务器对多个移动终端的数据流量进行校准。具体实施时,可以将安装有流量监控软件或者手机助手软件等任何具有流量监控功能的软件用户所使用的移动终端全部作为校准对象,也可以仅将开通了自动校准功能的移动终端作为校准对象。例如,可以在任何具有流量监控功能的软件界面上设置“自动校准功能”的功能入口,当用户通过该功能入口选择开启自动校准功能时,移动终端获取到自动校准指令,并根据该指令自动向服务器发送包含该移动终端标识信息的自动校准请求。服务器根据接收到的自动校准请求中包含的标识信息确定相应移动终端的通信业务类型。具体地,该标识信息可以是移动终端的手机号码,服务器根据手机号码归属地等信息来确定其对应的通信业务类型。另外,该标识信息还可以是移动终端的ICCID,其固化在手机SIM卡中,共有20位数字组成,根据其中包含的运营商代码即可确定出相应的通信业务类型。例如,中国移动的代码为898600或898602,中国联通的代码为898601,中国电信的代码为898603。本领域技术人员还可以采用其他多种形式的标识信息,只要能够起到唯一标识移动终端并确定业务类型的目的即可。In this embodiment, the data traffic of multiple mobile terminals can be calibrated through the traffic calibration server. In specific implementation, all mobile terminals used by users of any software with traffic monitoring functions, such as flow monitoring software or mobile phone assistant software, may be used as calibration objects, or only mobile terminals with automatic calibration function enabled may be used as calibration objects. For example, a function entry of "automatic calibration function" can be set on any software interface with flow monitoring function. When the user chooses to enable the automatic calibration function through the function entry, the mobile terminal obtains the automatic calibration instruction, and automatically sends the automatic calibration instruction to the user according to the instruction. The server sends an automatic calibration request containing the identification information of the mobile terminal. The server determines the communication service type of the corresponding mobile terminal according to the identification information contained in the received automatic calibration request. Specifically, the identification information may be the mobile phone number of the mobile terminal, and the server determines the corresponding communication service type according to the attribution of the mobile phone number and other information. In addition, the identification information can also be the ICCID of the mobile terminal, which is solidified in the SIM card of the mobile phone and consists of 20 digits, and the corresponding communication service type can be determined according to the operator code contained therein. For example, China Mobile's code is 898600 or 898602, China Unicom's code is 898601, and China Telecom's code is 898603. Those skilled in the art can also use other forms of identification information, as long as the purpose of uniquely identifying the mobile terminal and determining the service type can be achieved.
另外,除了由服务器分析标识信息得出通信业务类型之外,也可以直接由移动终端将自身使用的通信业务类型发送给服务器。In addition, in addition to obtaining the communication service type by analyzing the identification information by the server, the mobile terminal can also directly send the communication service type used by itself to the server.
步骤S220:获取各种通信业务类型对应的流量查询指令。Step S220: Obtain traffic query instructions corresponding to various communication service types.
在本实施例中,根据运营商类型可以将通信业务类型划分为三大类型,分别为移动类型、联通类型以及电信类型。进一步地,由于运营商存在地域性差别,因而,又可以根据全国所包含的省市数量将上述三大类型中的每种类型进一步划分为数十个小类型,例如,以移动类型为例来说,进一步分为北京移动、河南移动、江苏移动等小类型。又进一步地,每种小类型的通信业务能够向用户提供多种套餐类型的业务,因而,又可以将上述的各个小类型进一步细分为若干子类型,例如,以北京移动为例来说,其进一步包含动感地带类型的通信业务、神州行类型的通信业务等。由此可见,本实施例中的通信业务类型包含很多子类,有些子类对应的流量查询指令相同,而有些子类对应的流量查询指令不同,因而,在本步骤中,需要为各种通信业务类型(包含上述的大类型、小类型以及子类型)分别配置相应的流量查询指令。In this embodiment, the communication service types can be divided into three types according to the type of the operator, namely, the mobile type, the China Unicom type, and the telecommunication type. Further, due to regional differences among operators, each of the above three types can be further divided into dozens of small types according to the number of provinces and cities in the country. For example, take the mobile type as an example. Said, further divided into Beijing Mobile, Henan Mobile, Jiangsu Mobile and other small types. Further, each small type of communication service can provide users with a variety of package types of services. Therefore, the above-mentioned small types can be further subdivided into several subtypes. For example, taking Beijing Mobile as an example, It further includes a dynamic zone type communication service, a Shenzhouxing type communication service, and the like. It can be seen that the communication service types in this embodiment include many sub-categories, some sub-categories have the same traffic query instructions, while some sub-categories have different traffic query instructions. Therefore, in this step, various communication The service type (including the above-mentioned large type, small type and sub-type) is configured with corresponding traffic query instructions respectively.
其中,流量查询指令是根据运营商为用户提供的流量查询方式来确定的。例如,运营商通常会向用户提供短信查询数据流量的方式、电话查询数据流量的方式以及微信查询数据流量的方式等。在本实施例中,主要根据运营商提供的短信查询数据流量的方式来设置流量查询指令。在流量查询指令中,进一步包含查询代码以及查询端口号。例如,以北京移动类型的通信业务为例,流量查询指令包括如下两部分:(1)查询代码:CXGLL(2)查询端口号:10086。The traffic query instruction is determined according to the traffic query mode provided by the operator for the user. For example, operators usually provide users with a way to query data traffic by SMS, a way to query data traffic by phone, and a way to query data traffic by WeChat. In this embodiment, the traffic query instruction is set mainly according to the way of querying the data traffic through the short message provided by the operator. In the traffic query instruction, the query code and the query port number are further included. For example, taking the communication service of Beijing Mobile as an example, the traffic query instruction includes the following two parts: (1) query code: CXGLL (2) query port number: 10086.
为了便于统计及查询,在本实施例中,可以将获取到的各种通信业务类型对应的流量查询指令存储在流量查询指令表格中,其中,该流量查询指令表格中存储有待校准的全部移动终端的标识信息、通信业务类型及其对应的流量查询指令。并且,为了适应运营商服务器升级改版等需求,流量查询指令表格能够根据接收到的更新指令进行更新,该更新指令进一步包括:新增类型的更新指令、修改类型的更新指令以及删除类型的更新指令。其中,可以由专门的服务器对流量查询指令表格进行维护及更新,以确保其中存储的流量查询指令为最新的指令信息。In order to facilitate statistics and query, in this embodiment, the obtained traffic query instructions corresponding to various communication service types may be stored in a traffic query command table, where all mobile terminals to be calibrated are stored in the traffic query command table. The identification information, communication service type and its corresponding traffic query instruction. Moreover, in order to meet the needs of the operator's server upgrade and revision, the traffic query instruction table can be updated according to the received update instruction, and the update instruction further includes: an update instruction of a new type, an update instruction of a modification type, and an update instruction of a deletion type. . The traffic query instruction table may be maintained and updated by a special server to ensure that the traffic query instruction stored therein is the latest instruction information.
步骤S230:将待校准的全部移动终端划分为多个分组,为各个分组分别创建用于校准该分组内各移动终端的数据流量的子进程。Step S230: Divide all the mobile terminals to be calibrated into a plurality of groups, and create a sub-process for calibrating the data flow of each mobile terminal in the group for each group.
其中,可以根据移动终端的通信业务类型将待校准的全部移动终端划分为多个分组。例如,可以根据运营商类型以及运营商所述地域将待校准的移动终端划分为数十个分组,即包含:北京移动、河南移动、北京联通、北京电信以及江苏电信等数十个分组。或者,也可以根据通信业务类型所对应的流量查询指令来划分分组,从而将流量查询指令相同的移动终端分为同一分组。例如,可能北京移动和河北移动的流量查询指令相同,因而可以将这两种类型的移动终端分为同一分组。Wherein, all mobile terminals to be calibrated may be divided into multiple groups according to the communication service types of the mobile terminals. For example, the mobile terminal to be calibrated can be divided into dozens of groups according to the type of operator and the region described by the operator, that is, dozens of groups including: Beijing Mobile, Henan Mobile, Beijing Unicom, Beijing Telecom, and Jiangsu Telecom. Alternatively, the groups may also be divided according to the traffic query instructions corresponding to the communication service types, so that the mobile terminals with the same traffic query instructions are divided into the same group. For example, it is possible that Beijing Mobile and Hebei Mobile have the same traffic query instructions, so these two types of mobile terminals can be divided into the same group.
将移动终端划分为多个分组之后,为各个分组分别创建一个或多个用于校准该分组内各移动终端的数据流量的子进程。通过多进程并行处理的方式能够显著提高校准效率,使服务器能够同时为多个移动终端提供校准服务。After the mobile terminal is divided into multiple groups, one or more sub-processes for calibrating the data flow of each mobile terminal in the group are respectively created for each group. By means of multi-process parallel processing, the calibration efficiency can be significantly improved, so that the server can provide calibration services for multiple mobile terminals at the same time.
步骤S240:各个子进程根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求。Step S240: Each sub-process sends a traffic query request to the operator server according to the communication service type of the mobile terminal and the traffic query instruction corresponding to the communication service of the type.
其中,各个子进程可以每隔预设的时间间隔发送一次流量查询请求,以触发后续的流量校准操作。其中,该时间间隔可以通过多种方式确定,例如,可以通过预先接收到的来自移动终端的周期设定指令来确定,或者,也可以由服务器进行设定,如设定为每隔一天发送一次流量查询请求或每隔一小时发送一次流量查询请求等。Wherein, each sub-process may send a traffic query request every preset time interval to trigger a subsequent traffic calibration operation. The time interval can be determined in various ways, for example, it can be determined by a pre-received cycle setting instruction from the mobile terminal, or it can also be set by the server, for example, it is set to be sent every other day Traffic query request or send traffic query request every hour, etc.
具体实现时,各个子进程相互并行地为本分组内的各个移动终端发送流量查询请求,从而提高查询效率。各个子进程首先通过读取流量查询指令表格来获取相应分组内待校准的移动终端的标识信息以及通信业务类型及其对应的流量查询指令。然后,根据移动终端的标识信息为本分组内的各个移动终端分别发送流量查询请求。其中,每条流量查询请求分别以对应的移动终端的名义进行发送,例如,通过修改流量查询请求所包含的发件人地址来实现代替移动终端发送流量查询请求,以查询对应移动终端的数据流量的目的。During specific implementation, each sub-process sends a traffic query request to each mobile terminal in the group in parallel with each other, thereby improving query efficiency. Each sub-process first obtains the identification information of the mobile terminal to be calibrated in the corresponding group, the communication service type and its corresponding traffic query instruction by reading the flow query instruction table. Then, according to the identification information of the mobile terminal, each mobile terminal in the group sends a traffic query request respectively. Wherein, each traffic query request is sent in the name of the corresponding mobile terminal, for example, by modifying the sender address included in the traffic query request to send the traffic query request instead of the mobile terminal to query the data traffic of the corresponding mobile terminal the goal of.
其中,该流量查询请求可以是根据流量查询指令中包含的查询代码以及查询端口号生成的流量查询短信。例如,当流量查询指令中包括查询代码“CXGLL”以及查询端口号“10086”时,构造短信内容为“CXGLL”的短信,并发送给号码为“10086”的收件人。除了流量查询短信的实现方式之外,本领域技术人员还可以通过语音消息、微信消息等多种形式发送流量查询请求。The traffic query request may be a traffic query short message generated according to the query code and the query port number contained in the traffic query instruction. For example, when the query code "CXGLL" and the query port number "10086" are included in the traffic query instruction, a short message with the short message content "CXGLL" is constructed and sent to the recipient with the number "10086". In addition to the implementation of the traffic query short message, those skilled in the art can also send the traffic query request in various forms such as voice messages and WeChat messages.
步骤S250:接收运营商服务器返回的流量查询结果,根据预先设置的解析规则对流量查询结果进行解析,以获取其中包含的流量信息。Step S250: Receive the traffic query result returned by the operator server, and parse the traffic query result according to a preset parsing rule to obtain the traffic information contained therein.
当流量查询请求为流量查询短信时,运营商服务器返回的流量查询结果是包含流量信息的流量反馈短信。其中,流量查询结果中可能包含多种流量信息,例如包括:套餐内总流量、本月已使用流量、本月剩余流量、本地数据流量以及漫游数据流量等。When the traffic query request is a traffic query short message, the traffic query result returned by the operator server is a traffic feedback short message containing traffic information. Among them, the traffic query result may contain various traffic information, such as: total traffic in the package, traffic used in this month, remaining traffic in this month, local data traffic, and roaming data traffic.
在本步骤中,利用预先设置的解析规则对流量查询结果进行解析,以获取其中包含的流量信息的具体数值。其中,解析规则可以通过以下步骤设置:In this step, the traffic query result is parsed by using a preset parsing rule, so as to obtain the specific value of the traffic information contained therein. Among them, the parsing rules can be set by the following steps:
(1)预先收集各种类型的通信业务所对应的流量查询结果。(1) Collect the traffic query results corresponding to various types of communication services in advance.
本步骤的目的在于,获取流量查询结果的样本。其中,可以通过人工获取的方式进行收集,也可以通过服务器向各个运营商服务器发送各种通信业务类型的流量查询请求,以获取对应的流量查询结果。为了便于分析,针对每种类型的通信业务,可以获取多个流量查询结果作为样本,样本数量越多,分析结果越准确,后续的解析精确度也越高。The purpose of this step is to obtain a sample of the traffic query result. Wherein, the collection can be performed by manual acquisition, or the server can send traffic query requests of various communication service types to each operator's server, so as to obtain corresponding traffic query results. To facilitate analysis, for each type of communication service, multiple traffic query results can be obtained as samples. The larger the number of samples, the more accurate the analysis results and the higher the accuracy of subsequent analysis.
(2)根据流量查询结果中包含的标识信息,将流量查询结果划分为多种类型。(2) According to the identification information contained in the traffic query result, the traffic query result is divided into various types.
本步骤的目的在于,对海量的流量查询结果的样本进行分类。其中,流量查询结果中包含的标识信息可以是运营商标识,例如,以中国移动返回的流量查询结果为例,其中包含用以标识运营商信息的端口号“10086”。相应地,中国联通返回的流量查询结果则包含端口号“10010”。由此可见,根据运营商标识能够将流量查询结果划分为移动、联通、电信三大类型。另外,流量查询结果中包含的标识信息还可以进一步包括地域信息,通过该地域信息可以将流量查询结果进一步细分为北京移动类型、河北移动类型等。除此之外,还可以根据移动终端的套餐类型将北京移动类型进一步划分为动感地带型北京移动类型、全球通型北京移动终端类型、神州行型北京移动类型。总之,本发明对标识信息的具体内容以及分类方式不做限定。由于同一类型的流量查询结果所对应的短信格式相同,因此,对流量查询结果的样本进行分类能够将同一类型的结果统一处理,从而提高处理效率。The purpose of this step is to classify the samples of massive traffic query results. The identification information included in the traffic query result may be an operator identification. For example, take the traffic query result returned by China Mobile as an example, which includes the port number "10086" for identifying operator information. Correspondingly, the traffic query result returned by China Unicom includes the port number "10010". It can be seen that the traffic query results can be divided into three types: mobile, China Unicom, and telecommunications according to the operator ID. In addition, the identification information included in the traffic query result may further include regional information, and the traffic query result can be further subdivided into Beijing mobile type, Hebei mobile type, etc. through the regional information. In addition, Beijing Mobile types can be further divided into dynamic zone type Beijing mobile terminal types, global access type Beijing mobile terminal types, and Shenzhouxing type Beijing mobile types according to the package types of the mobile terminals. In a word, the present invention does not limit the specific content and classification manner of the identification information. Since the short message formats corresponding to the same type of traffic query results are the same, classifying the samples of the traffic query results can uniformly process the same type of results, thereby improving the processing efficiency.
(3)分别分析每种类型的流量查询结果中包含的流量信息的种类以及与各种流量信息相对应的信息字段的格式规范。(3) Analyze the types of traffic information contained in each type of traffic query result and the format specification of information fields corresponding to various traffic information.
例如,以动感地带型北京移动类型的流量查询结果为例,其对应的一个样本的短信内容为“您好!上月结转至本月:国内通用流量上月结转为6.0MB,本地闲时流量上月结转为100.0MB。截至到2015年12月17日15时01分,您已使用数据流量9.15MB,套餐内剩余流量216.86MB,其中,国内通用流量剩余17.86MB(含国内通用流量结转0.0MB),本地闲时流量剩余199.0MB(含本地闲时流量结转99.0MB),感谢您使用流量查询服务。您可使用客户端,随时查询流量使用情况。点击下载:http://mobilebj.cn/?c=120/中国移动”。For example, taking the traffic query result of the dynamic zone type Beijing Mobile as an example, the corresponding SMS content of a sample is "Hello! Carry forward from the previous month to this month: the domestic general traffic carried over from the previous month is 6.0MB, and the local idle time is 6.0MB. The traffic carried over from the previous month was 100.0MB. As of 15:01 on December 17, 2015, you have used 9.15MB of data traffic, and the remaining traffic in the package is 216.86MB, of which the remaining domestic general traffic is 17.86MB (including domestic general traffic). Carry forward 0.0MB), the remaining 199.0MB of local idle traffic (including 99.0MB of local idle traffic), thank you for using the traffic query service. You can use the client to check the traffic usage at any time. Click to download: http:/ /mobilebj.cn/?c=120/China Mobile”.
首先,对上述短信内容进行分析,确定其中至少包含如下几种流量信息:a)国内通用流量上月结转,b)本地闲时流量上月结转,c)已使用数据流量,d)套餐内剩余流量。其中,套餐内剩余流量又进一步分为国内通用流量剩余以及本地闲时流量剩余两部分。First, analyze the content of the above-mentioned short messages, and determine that it contains at least the following traffic information: a) domestic general traffic carried over from the previous month, b) local idle traffic carried over from the previous month, c) used data traffic, d) package remaining flow. Among them, the remaining traffic in the package is further divided into two parts: the remaining domestic general traffic and the remaining local idle traffic.
然后,分析每种流量信息相对应的信息字段的格式规范。例如,国内通用流量上月结转对应的信息字段包括“国内通用流量上月结转”以及“6.0MB”。其中,信息字段“国内通用流量上月结转”为固定字段,在每次返回的查询结果中该字段均不发生变化。信息字段“6.0MB”为可变字段,在每次返回的查询结果中该字段根据流量使用情况而实时更新,进一步地,该可变字段又包括由阿拉伯数字组成的第一部分以及由英文字母组成的第二部分。类似地,其他几种流量信息中也至少包含固定字段和可变字段。Then, the format specification of the information field corresponding to each kind of traffic information is analyzed. For example, the information fields corresponding to the carry-over of domestic general traffic last month include "Domestic general traffic carried forward last month" and "6.0MB". Among them, the information field "Domestic General Traffic Carryover from Last Month" is a fixed field, and this field does not change in each returned query result. The information field "6.0MB" is a variable field, which is updated in real time according to the traffic usage in each returned query result. Further, the variable field includes the first part consisting of Arabic numerals and the first part consisting of English letters the second part. Similarly, other types of traffic information also contain at least fixed fields and variable fields.
(4)根据信息字段的格式规范分别为每种类型的流量查询结果设定相应的正则表达式匹配规则。(4) Set corresponding regular expression matching rules for each type of traffic query result according to the format specification of the information field.
在设定正则表达式匹配规则时,结合信息字段的特征以及格式规范进行设定。例如,以固定字段“国内通用流量上月结转”为例来说,可以通过匹配中文字符的正则表达式“[u4e00-u9fa5]”来设定匹配规则。又如,以可变字段“6.0MB”为例来说,其第一部分可以通过用于匹配阿拉伯数字的正则表达式来设定匹配规则,其第二部分可以通过用于匹配大写英文字母的正则表达式来设定匹配规则。另外,正则表达式还能够匹配空格、URL网址、正整数、负整数、浮点数等多种类型的内容。When setting the regular expression matching rule, set it according to the characteristics of the information field and the format specification. For example, taking the fixed field "Domestic general traffic carried over from last month" as an example, a matching rule can be set by the regular expression "[u4e00-u9fa5]" that matches Chinese characters. For another example, taking the variable field "6.0MB" as an example, the first part of the variable field can be set by a regular expression for matching Arabic numerals, and the second part can be set by a regular expression used to match uppercase English letters. expression to set matching rules. In addition, regular expressions can also match various types of content such as spaces, URLs, positive integers, negative integers, and floating-point numbers.
与之相应地,在根据上述解析规则对流量查询结果进行解析时,具体可以通过如下步骤实现:Correspondingly, when parsing the traffic query result according to the above parsing rules, the following steps can be specifically implemented:
(1)根据运营商服务器返回的流量查询结果中包含的标识信息确定流量查询结果的类型。(1) Determine the type of the traffic query result according to the identification information included in the traffic query result returned by the operator server.
例如,当标识信息为“10086”时,确定为中国移动类型的流量查询结果。进一步地,还可以根据流量查询结果中包含的移动终端号码来确定与该号码相对应的运营商归属地以及套餐类型。For example, when the identification information is "10086", it is determined to be a traffic query result of China Mobile type. Further, the operator's home location and package type corresponding to the number can also be determined according to the mobile terminal number included in the traffic query result.
(2)获取与该类型的流量查询结果相对应的正则表达式匹配规则。(2) Obtain the regular expression matching rule corresponding to the traffic query result of this type.
其中,可以预先将各种类型的流量查询结果相对应的正则表达式匹配规则存储在预设的匹配规则表中,通过查询该匹配规则表,即可获取到与该类型的流量查询结果相对应的正则表达式匹配规则。Among them, the regular expression matching rules corresponding to various types of traffic query results can be stored in a preset matching rule table in advance, and by querying the matching rule table, the corresponding types of traffic query results can be obtained. regular expression matching rules.
(3)根据获取到的正则表达式匹配规则对运营商服务器返回的流量查询结果中的各个字符进行匹配,以获取其中包含的各种流量信息的数值。(3) Matching each character in the traffic query result returned by the operator server according to the obtained regular expression matching rule to obtain the numerical values of various traffic information contained therein.
例如,以上述动感地带型北京移动类型的流量查询结果为例,通过正则表达式匹配规则对流量查询结果中的各个字符进行匹配,可以确定出其中包含的各种流量信息对应的固定字段以及可变字段的内容,进而分析出各种流量信息的数值。For example, taking the traffic query result of the above-mentioned dynamic zone type Beijing Mobile as an example, by matching each character in the traffic query result through regular expression matching rules, the fixed fields and variable fields corresponding to various traffic information contained therein can be determined. The content of the field, and then analyze the value of various traffic information.
步骤S260:将获取到的流量信息发送给移动终端,以供移动终端根据该流量信息对本地设备统计的数据流量进行校准。Step S260: Send the acquired traffic information to the mobile terminal, so that the mobile terminal can calibrate the data traffic counted by the local device according to the traffic information.
其中,移动终端的本地设备统计的数据流量可以是由流量监控软件统计的数据流量,该数据流量主要通过移动终端的网卡获取。流量监控软件接收到来自服务器的流量信息之后,将来自服务器的流量信息与本地统计的流量信息进行比对,若二者一致则无需处理;若二者不一致则根据来自服务器的流量信息修正本地统计的流量信息。The data traffic counted by the local device of the mobile terminal may be the data traffic counted by the traffic monitoring software, and the data traffic is mainly obtained through the network card of the mobile terminal. After the traffic monitoring software receives the traffic information from the server, it compares the traffic information from the server with the traffic information from the local statistics. If the two are consistent, no processing is required; traffic information.
由于移动终端本地无法统计网管重传的数据流量,且移动终端本地对于一些免流量专区的优惠流量无法识别,因而统计结果无法实现精准,而运营商服务器返回的数据流量是最终计费的衡量标准,所以,通过本实施例中的方式能够使移动终端本地统计的数据流量与运营商一致,从而对用户的资费情况做出准确提醒。Because the mobile terminal cannot locally count the data traffic retransmitted by the network management, and the mobile terminal cannot identify the preferential traffic in some traffic-free zones locally, the statistical results cannot be accurate, and the data traffic returned by the operator's server is the final billing standard. , therefore, the method in this embodiment can make the data traffic counted locally by the mobile terminal consistent with that of the operator, thereby accurately reminding the user of the tariff situation.
可选地,在本方法中,还可以进一步根据校准后的数据流量向用户发出提醒消息。例如,可以在校准后的数据流量超出预设阈值时,向用户发出提醒消息,该提醒消息可以通过弹框方式、短消息方式等多种方式发出。其中,预设阈值可以根据预先接收到的阈值设定指令确定,用户可以通过流量监控软件提供的设定报警阈值的功能入口发送包含预设阈值信息的阈值设定指令。另外,该预设阈值也可以根据移动终端套餐业务所包含的流量总数进行设定,例如,当已使用数据流量达到可用流量总数的百分之八十时发出提醒消息。进一步地,如果校准后的已使用数据流量等于或大于可用流量总数,还可以断开当前网络连接,同时给予用户提示。Optionally, in this method, a reminder message may be sent to the user according to the calibrated data flow. For example, when the calibrated data flow exceeds a preset threshold, a reminder message can be sent to the user, and the reminder message can be sent in a variety of ways such as a pop-up box and a short message. The preset threshold can be determined according to a pre-received threshold setting instruction, and the user can send a threshold setting instruction containing preset threshold information through the function portal for setting an alarm threshold provided by the traffic monitoring software. In addition, the preset threshold can also be set according to the total amount of traffic included in the mobile terminal package service, for example, when the used data traffic reaches 80% of the total available traffic, a reminder message is sent out. Further, if the used data traffic after calibration is equal to or greater than the total amount of available traffic, the current network connection can also be disconnected, and a prompt is given to the user at the same time.
通过本发明实施例中的上述步骤,即可由服务器自动完成对多个移动终端的流量校准操作。由于发送流量查询请求以及接收流量查询结果的操作均由服务器通过多进程并行处理的方式统一完成,因而不仅能够提高查询效率,同时校准大量的移动终端;而且,还避免了收发短信的操作对于移动终端用户带来的干扰。另外,在本发明中,预先设置有正则表达式匹配规则,根据该匹配规则对流量查询结果进行解析,由于正则表达式查询方便且匹配迅速,从而缩短了服务器的解析时长,提高了解析效率;而且,由于正则表达式的类型非常灵活,能够适配各种格式的字段,因而还提高了解析的精确度,使本发明校准后的流量更为精准。Through the above steps in the embodiment of the present invention, the server can automatically complete the traffic calibration operation for multiple mobile terminals. Since the operations of sending traffic query requests and receiving traffic query results are unified by the server through multi-process parallel processing, it can not only improve query efficiency, but also calibrate a large number of mobile terminals; Interference from end users. In addition, in the present invention, a regular expression matching rule is preset, and the traffic query result is parsed according to the matching rule. Because the regular expression query is convenient and the matching is fast, the analysis time of the server is shortened and the analysis efficiency is improved; Moreover, since the type of regular expression is very flexible and can be adapted to fields of various formats, the accuracy of parsing is also improved, and the calibrated flow of the present invention is more accurate.
本领域技术人员还可以对上述实施例进行各种改进或变形,上述各个步骤可以合并为更少的步骤或拆分为更多的步骤,且其中的部分步骤可省略。例如,对移动终端进行分组并设置多个进程分别校准各分组内移动终端的步骤也可以省略。Those skilled in the art can also make various improvements or modifications to the above embodiments, the above steps can be combined into fewer steps or divided into more steps, and some of the steps can be omitted. For example, the step of grouping the mobile terminals and setting up multiple processes to calibrate the mobile terminals in each group can also be omitted.
另外,本领域技术人员还可以对上述步骤中的实现方式进行灵活更改。例如,发送流量查询请求以及接收流量查询结果的步骤也可以由移动终端完成,此时,移动终端将接收到的流量查询结果发送给服务器解析。为了减少对移动终端用户的干扰,发送流量查询请求的操作可以由移动终端自动完成,例如,只需用户通过流量监控软件提供的“静默校准”功能入口进行设置即可。而且,移动终端还可以对接收到的流量查询结果进行拦截,使其不进入移动终端用户的收件箱。例如,可以通过移动终端安装的防护软件中的短信拦截功能入口进行拦截。也可以根据发件人号码进行拦截(拦截号码为运营商的短信),为了避免拦截到对用户有用的短信,可以设置拦截时间,例如,拦截发送流量查询请求后预设时间段内的运营商短信。In addition, those skilled in the art can also flexibly modify the implementation manners in the above steps. For example, the steps of sending the traffic query request and receiving the traffic query result may also be completed by the mobile terminal. At this time, the mobile terminal sends the received traffic query result to the server for analysis. In order to reduce the interference to the mobile terminal user, the operation of sending the traffic query request can be automatically completed by the mobile terminal, for example, the user only needs to set it through the "silent calibration" function portal provided by the traffic monitoring software. Moreover, the mobile terminal can also intercept the received traffic query result so that it does not enter the inbox of the mobile terminal user. For example, it can be intercepted through the entrance of the short message interception function in the protection software installed on the mobile terminal. It can also be intercepted according to the sender's number (the interception number is the SMS of the operator). In order to avoid intercepting the SMS useful to the user, the interception time can be set. For example, the operator within the preset time period after the traffic query request is intercepted. Short message.
图3示出了本发明另一实施例提供的对移动终端的数据流量进行校准的装置的结构图。如图3所示,该装置包括:FIG. 3 shows a structural diagram of an apparatus for calibrating data traffic of a mobile terminal according to another embodiment of the present invention. As shown in Figure 3, the device includes:
查询模块31,适于根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求;The
解析模块32,适于接收所述运营商服务器返回的流量查询结果,根据预先设置的解析规则对所述流量查询结果进行解析,以获取其中包含的流量信息;The
发送模块33,适于将所述流量信息发送给所述移动终端,以供所述移动终端根据所述流量信息对本地设备统计的数据流量进行校准。The sending
可选地,该装置进一步包括:解析规则设定模块,适于预先收集各种类型的通信业务所对应的流量查询结果,根据所述流量查询结果中包含的标识信息,将所述流量查询结果划分为多种类型;分别分析每种类型的流量查询结果中包含的流量信息的种类以及与各种流量信息相对应的信息字段的格式规范;根据所述信息字段的格式规范分别为每种类型的流量查询结果设定相应的正则表达式匹配规则。Optionally, the device further includes: a parsing rule setting module, adapted to collect in advance the traffic query results corresponding to various types of communication services, and according to the identification information contained in the traffic query results, set the traffic query results. Divided into multiple types; analyze the types of traffic information contained in the traffic query results of each type and the format specifications of the information fields corresponding to various traffic information; according to the format specifications of the information fields, each type is Set the corresponding regular expression matching rules for the traffic query results.
可选地,所述解析模块32具体用于:根据所述运营商服务器返回的流量查询结果中包含的标识信息确定所述流量查询结果的类型;获取与该类型的流量查询结果相对应的正则表达式匹配规则;根据所述正则表达式匹配规则对所述运营商服务器返回的流量查询结果中的各个字符进行匹配,以获取其中包含的各种流量信息的数值。Optionally, the parsing
可选地,所述流量查询结果中包含的流量信息的种类包括以下一种或多种:套餐内总流量、本月已使用流量、本月剩余流量、本地数据流量以及漫游数据流量。Optionally, the types of traffic information included in the traffic query result include one or more of the following: total traffic in the package, used traffic this month, remaining traffic this month, local data traffic, and roaming data traffic.
可选地,所述流量查询请求是根据所述流量查询指令中包含的查询代码以及查询端口号生成的流量查询短信,且所述流量查询结果是包含流量信息的流量反馈短信。Optionally, the traffic query request is a traffic query short message generated according to the query code and the query port number contained in the traffic query instruction, and the traffic query result is a traffic feedback short message including traffic information.
可选地,该装置进一步包括:流量提醒模块,适于在所述运营商服务器返回的流量查询结果中包含的流量信息的数值超出预设阈值时,向所述移动终端发送流量提醒消息。Optionally, the device further includes: a traffic reminder module, adapted to send a traffic reminder message to the mobile terminal when the value of the traffic information contained in the traffic query result returned by the operator server exceeds a preset threshold.
在本发明提供的对移动终端的数据流量进行校准的方法及装置中,能够根据移动终端的通信业务类型以及与该类型的通信业务相对应的流量查询指令向运营商服务器发送流量查询请求,并根据运营商服务器返回的流量查询结果对移动终端的数据流量进行校准,从而克服了本地设备所统计的数据流量与运营商统计的数据流量存在误差的技术问题,因而使用户能够根据本地设备统计的数据流量准确管理流量资费。具体地,在本发明中,通过预先设置的解析规则对运营商服务器返回的流量查询结果进行解析,以获取其中包含的流量信息,从而提高了解析的效率和准确性。In the method and device for calibrating data traffic of a mobile terminal provided by the present invention, a traffic query request can be sent to an operator server according to a communication service type of the mobile terminal and a traffic query instruction corresponding to the type of communication service, and The data traffic of the mobile terminal is calibrated according to the traffic query result returned by the operator's server, so as to overcome the technical problem of the discrepancy between the data traffic counted by the local device and the data traffic counted by the operator, thus enabling the user to Data traffic accurately manages traffic tariffs. Specifically, in the present invention, the traffic query result returned by the operator server is parsed through preset parsing rules to obtain the traffic information contained therein, thereby improving the efficiency and accuracy of the parsing.
在此提供的算法和显示不与任何特定计算机、虚拟系统或者其它设备固有相关。各种通用系统也可以与基于在此的示教一起使用。根据上面的描述,构造这类系统所要求的结构是显而易见的。此外,本发明也不针对任何特定编程语言。应当明白,可以利用各种编程语言实现在此描述的本发明的内容,并且上面对特定语言所做的描述是为了披露本发明的最佳实施方式。The algorithms and displays provided herein are not inherently related to any particular computer, virtual system, or other device. Various general-purpose systems can also be used with teaching based on this. The structure required to construct such a system is apparent from the above description. Furthermore, the present invention is not directed to any particular programming language. It is to be understood that various programming languages may be used to implement the inventions described herein, and that the descriptions of specific languages above are intended to disclose the best mode for carrying out the invention.
在此处所提供的说明书中,说明了大量具体细节。然而,能够理解,本发明的实施例可以在没有这些具体细节的情况下实践。在一些实例中,并未详细示出公知的方法、结构和技术,以便不模糊对本说明书的理解。In the description provided herein, numerous specific details are set forth. It will be understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
类似地,应当理解,为了精简本公开并帮助理解各个发明方面中的一个或多个,在上面对本发明的示例性实施例的描述中,本发明的各个特征有时被一起分组到单个实施例、图、或者对其的描述中。然而,并不应将该公开的方法解释成反映如下意图:即所要求保护的本发明要求比在每个权利要求中所明确记载的特征更多的特征。更确切地说,如下面的权利要求书所反映的那样,发明方面在于少于前面公开的单个实施例的所有特征。因此,遵循具体实施方式的权利要求书由此明确地并入该具体实施方式,其中每个权利要求本身都作为本发明的单独实施例。Similarly, it is to be understood that in the above description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together into a single embodiment, figure, or its description. This disclosure, however, should not be construed as reflecting an intention that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the Detailed Description are hereby expressly incorporated into this Detailed Description, with each claim standing on its own as a separate embodiment of this invention.
本领域那些技术人员可以理解,可以对实施例中的设备中的模块进行自适应性地改变并且把它们设置在与该实施例不同的一个或多个设备中。可以把实施例中的模块或单元或组件组合成一个模块或单元或组件,以及此外可以把它们分成多个子模块或子单元或子组件。除了这样的特征和/或过程或者单元中的至少一些是相互排斥之外,可以采用任何组合对本说明书(包括伴随的权利要求、摘要和附图)中公开的所有特征以及如此公开的任何方法或者设备的所有过程或单元进行组合。除非另外明确陈述,本说明书(包括伴随的权利要求、摘要和附图)中公开的每个特征可以由提供相同、等同或相似目的的替代特征来代替。Those skilled in the art will understand that the modules in the device in the embodiment can be adaptively changed and arranged in one or more devices different from the embodiment. The modules or units or components in the embodiments may be combined into one module or unit or component, and further they may be divided into multiple sub-modules or sub-units or sub-assemblies. All features disclosed in this specification (including accompanying claims, abstract and drawings) and any method so disclosed may be employed in any combination, unless at least some of such features and/or procedures or elements are mutually exclusive. All processes or units of equipment are combined. Each feature disclosed in this specification (including accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
此外,本领域的技术人员能够理解,尽管在此的一些实施例包括其它实施例中所包括的某些特征而不是其它特征,但是不同实施例的特征的组合意味着处于本发明的范围之内并且形成不同的实施例。例如,在下面的权利要求书中,所要求保护的实施例的任意之一都可以以任意的组合方式来使用。Furthermore, it will be understood by those skilled in the art that although some of the embodiments herein include certain features, but not others, included in other embodiments, that combinations of features of the different embodiments are intended to be within the scope of the present invention And form different embodiments. For example, in the following claims, any of the claimed embodiments may be used in any combination.
本发明的各个部件实施例可以以硬件实现,或者以在一个或者多个处理器上运行的软件模块实现,或者以它们的组合实现。本领域的技术人员应当理解,可以在实践中使用微处理器或者数字信号处理器(DSP)来实现根据本发明实施例的装置中的一些或者全部部件的一些或者全部功能。本发明还可以实现为用于执行这里所描述的方法的一部分或者全部的设备或者装置程序(例如,计算机程序和计算机程序产品)。这样的实现本发明的程序可以存储在计算机可读介质上,或者可以具有一个或者多个信号的形式。这样的信号可以从因特网网站上下载得到,或者在载体信号上提供,或者以任何其他形式提供。Various component embodiments of the present invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art should understand that a microprocessor or a digital signal processor (DSP) may be used in practice to implement some or all of the functions of some or all of the components in the apparatus according to the embodiments of the present invention. The present invention can also be implemented as apparatus or apparatus programs (eg, computer programs and computer program products) for performing part or all of the methods described herein. Such a program implementing the present invention may be stored on a computer-readable medium, or may be in the form of one or more signals. Such signals may be downloaded from Internet sites, or provided on carrier signals, or in any other form.
应该注意的是上述实施例对本发明进行说明而不是对本发明进行限制,并且本领域技术人员在不脱离所附权利要求的范围的情况下可设计出替换实施例。在权利要求中,不应将位于括号之间的任何参考符号构造成对权利要求的限制。单词“包含”不排除存在未列在权利要求中的元件或步骤。位于元件之前的单词“一”或“一个”不排除存在多个这样的元件。本发明可以借助于包括有若干不同元件的硬件以及借助于适当编程的计算机来实现。在列举了若干装置的单元权利要求中,这些装置中的若干个可以是通过同一个硬件项来具体体现。单词第一、第二、以及第三等的使用不表示任何顺序。可将这些单词解释为名称。It should be noted that the above-described embodiments illustrate rather than limit the invention, and that alternative embodiments may be devised by those skilled in the art without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed computer. In a unit claim enumerating several means, several of these means may be embodied by one and the same item of hardware. The use of the words first, second, and third, etc. do not denote any order. These words can be interpreted as names.
Claims (12)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510964220.0A CN106899987B (en) | 2015-12-21 | 2015-12-21 | Method and device for calibrating data flow of mobile terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510964220.0A CN106899987B (en) | 2015-12-21 | 2015-12-21 | Method and device for calibrating data flow of mobile terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106899987A CN106899987A (en) | 2017-06-27 |
CN106899987B true CN106899987B (en) | 2020-02-18 |
Family
ID=59190737
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510964220.0A Active CN106899987B (en) | 2015-12-21 | 2015-12-21 | Method and device for calibrating data flow of mobile terminal |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106899987B (en) |
Families Citing this family (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108520056A (en) * | 2018-04-03 | 2018-09-11 | 北京京东金融科技控股有限公司 | Business datum monitoring method and device, system, readable medium and electronic equipment |
CN108768777A (en) * | 2018-05-31 | 2018-11-06 | 连尚(新昌)网络科技有限公司 | Flow information inquiry, flow information providing method, equipment and medium |
CN110876123A (en) * | 2018-08-30 | 2020-03-10 | 北京三星通信技术研究有限公司 | Flow acquiring, providing, sharing, calibrating and transferring method and equipment |
CN110708211B (en) * | 2019-08-30 | 2021-09-17 | 上海唯链信息科技有限公司 | Network flow testing method and system |
CN110995541A (en) * | 2019-12-13 | 2020-04-10 | 北京小米移动软件有限公司 | Method and device for counting flow in real time |
CN113965900B (en) * | 2020-07-20 | 2023-09-05 | 中国移动通信集团安徽有限公司 | Method, device, computing device and storage medium for dynamic capacity expansion of traffic resources |
CN114969138B (en) * | 2021-02-26 | 2024-12-20 | 中移(苏州)软件技术有限公司 | A data request statistics method, server, terminal and system |
CN113904884B (en) * | 2021-09-30 | 2023-05-30 | 中国联合网络通信集团有限公司 | Traffic service message control method and equipment |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102752398A (en) * | 2012-07-18 | 2012-10-24 | 腾讯科技(深圳)有限公司 | Method and system for resolving flow value, terminal and server |
CN103188647A (en) * | 2011-12-29 | 2013-07-03 | 北京网秦天下科技有限公司 | Method and system for statistically analyzing and warning Internet surfing flow of mobile terminal |
CN103220643A (en) * | 2012-01-20 | 2013-07-24 | 腾讯科技(深圳)有限公司 | Information providing method and device and template base matching method and device |
CN104159209A (en) * | 2014-08-01 | 2014-11-19 | 北京奇虎科技有限公司 | Data traffic calibration method and device for mobile terminal |
CN104853334A (en) * | 2015-05-25 | 2015-08-19 | 小米科技有限责任公司 | Method and device for analyzing short message |
CN104994541A (en) * | 2015-05-22 | 2015-10-21 | 小米科技有限责任公司 | Network flow correction method and device |
CN104994220A (en) * | 2015-05-18 | 2015-10-21 | 北京奇虎科技有限公司 | Data processing method and system |
CN104994219A (en) * | 2015-05-18 | 2015-10-21 | 北京奇虎科技有限公司 | Data processing method and system |
-
2015
- 2015-12-21 CN CN201510964220.0A patent/CN106899987B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103188647A (en) * | 2011-12-29 | 2013-07-03 | 北京网秦天下科技有限公司 | Method and system for statistically analyzing and warning Internet surfing flow of mobile terminal |
CN103220643A (en) * | 2012-01-20 | 2013-07-24 | 腾讯科技(深圳)有限公司 | Information providing method and device and template base matching method and device |
CN102752398A (en) * | 2012-07-18 | 2012-10-24 | 腾讯科技(深圳)有限公司 | Method and system for resolving flow value, terminal and server |
CN104159209A (en) * | 2014-08-01 | 2014-11-19 | 北京奇虎科技有限公司 | Data traffic calibration method and device for mobile terminal |
CN104994220A (en) * | 2015-05-18 | 2015-10-21 | 北京奇虎科技有限公司 | Data processing method and system |
CN104994219A (en) * | 2015-05-18 | 2015-10-21 | 北京奇虎科技有限公司 | Data processing method and system |
CN104994541A (en) * | 2015-05-22 | 2015-10-21 | 小米科技有限责任公司 | Network flow correction method and device |
CN104853334A (en) * | 2015-05-25 | 2015-08-19 | 小米科技有限责任公司 | Method and device for analyzing short message |
Also Published As
Publication number | Publication date |
---|---|
CN106899987A (en) | 2017-06-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106899987B (en) | Method and device for calibrating data flow of mobile terminal | |
CN104159209A (en) | Data traffic calibration method and device for mobile terminal | |
CN107026746A (en) | Network servicequality appraisal procedure, system and the network equipment | |
CN107295594A (en) | Network switching method, device and mobile terminal | |
CN107818133A (en) | A kind of residential block network capabilities analysis method and system based on big data | |
EP2287799A1 (en) | System and method for reporting advertisement measurement | |
CN105898085B (en) | Harass recognition methods and the device of communications account | |
CN109634649B (en) | Page flow experimental method, system, equipment and readable storage medium | |
WO2012106861A1 (en) | Terminal distribution information acquisition method, data acquisition device and communication system | |
CN105450772B (en) | Exempt from flow method for down loading and device | |
WO2016041171A1 (en) | Method and apparatus for determining terminal roaming status, terminal and server | |
US10750031B2 (en) | Tariff data determining method and apparatus for creating the same | |
CN112232881A (en) | Data detection method and device, electronic equipment and storage medium | |
CN102769838A (en) | Mobile terminal tariff acquisition method, mobile terminal and tariff acquisition system | |
CN103369486A (en) | System and method for preventing fraud SMS (Short message Service) message | |
CN106899775B (en) | Method and device for calibrating data traffic of mobile terminal | |
CN113542043A (en) | Data sampling method, device, device and medium for network equipment | |
CN106844532A (en) | A kind of application program acquisition methods and device and a kind of terminal device | |
CN110677825A (en) | Processing method and device based on short promotion message reach rate and storage medium | |
CN105208571B (en) | The calibration method and device of communication service usage amount | |
KR101404448B1 (en) | Method and system for guiding package data protocol activation | |
CN104994220A (en) | Data processing method and system | |
CN113452533B (en) | Billing self-inspection, self-healing method, device, computer equipment and storage medium | |
CN101834749A (en) | Method and device for acquiring data, method and device for monitoring business service quality | |
CN110602228A (en) | Processing method and device based on short promotion message reach rate and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220819 Address after: No. 9-3-401, No. 39, Gaoxin 6th Road, Binhai Science and Technology Park, High-tech Zone, Binhai New District, Tianjin 300000 Patentee after: 3600 Technology Group Co.,Ltd. Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park) Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd. Patentee before: Qizhi software (Beijing) Co.,Ltd. |