+

CN106936601A - A kind of business charging method and device - Google Patents

A kind of business charging method and device Download PDF

Info

Publication number
CN106936601A
CN106936601A CN201511028652.7A CN201511028652A CN106936601A CN 106936601 A CN106936601 A CN 106936601A CN 201511028652 A CN201511028652 A CN 201511028652A CN 106936601 A CN106936601 A CN 106936601A
Authority
CN
China
Prior art keywords
charging
factor
billing
current service
result
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.)
Granted
Application number
CN201511028652.7A
Other languages
Chinese (zh)
Other versions
CN106936601B (en
Inventor
陆敬石
彭云峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201511028652.7A priority Critical patent/CN106936601B/en
Publication of CN106936601A publication Critical patent/CN106936601A/en
Application granted granted Critical
Publication of CN106936601B publication Critical patent/CN106936601B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/14Charging, metering or billing arrangements for data wireline or wireless communications
    • H04L12/1403Architecture for metering, charging or billing

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Charge And Discharge Circuits For Batteries Or The Like (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

本发明实施例公开了一种业务计费方法及装置,涉及通信技术领域,可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。具体方案为:获取一用户的当前业务的业务使用信息;确定用户为当前业务订购的资费策略,并从用户为当前业务订购的资费策略中,确定出当前业务的计费因子;采用当前业务的计费因子匹配预先存储的历史计费结果,历史计费结果中包含计费因子以及与计费因子存在对应关系的计费结果;若存在与当前业务的计费因子匹配的历史计费结果,则采用与当前业务的计费因子匹配的历史计费结果,根据当前业务的业务使用信息为当前业务计费,以获得当前业务的计费结果。本发明用于电信业务的计费过程中。

The embodiment of the invention discloses a service charging method and device, which relate to the field of communication technology, can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance. The specific scheme is as follows: obtain the service usage information of a user's current service; determine the tariff policy subscribed by the user for the current service, and determine the billing factor of the current service from the tariff policy subscribed by the user for the current service; The billing factor matches the pre-stored historical billing results, which include the billing factor and the billing result corresponding to the billing factor; if there is a historical billing result that matches the billing factor of the current service, The historical charging result matching the charging factor of the current service is used, and the current service is charged according to the service usage information of the current service, so as to obtain the charging result of the current service. The invention is used in the billing process of telecommunication services.

Description

一种业务计费方法及装置A service charging method and device

技术领域technical field

本发明涉及通信技术领域,尤其涉及一种业务计费方法及装置。The present invention relates to the technical field of communications, in particular to a service charging method and device.

背景技术Background technique

随着电子信息产业的发展,运营商可以针对不同的客户群体设计出可供客户选择的多种资费策略,以满足客户的业务需求。运营商可以将这些配置到计费系统中,形成资费数据,以便于根据用户订购的资费策略以及其业务使用情况对用户业务进行计费。With the development of the electronic information industry, operators can design a variety of tariff strategies for customers to choose from for different customer groups, so as to meet the business needs of customers. Operators can configure these into the billing system to form tariff data, so as to charge user services according to the tariff policies subscribed by users and their service usage.

现有技术对用户业务进行计费的过程,可以包括:获取用户的计费号码、当前业务的业务类型(如数据业务和语音业务)以及业务使用量等计费因子;获取该用户订购的所有资费策略;采用上述计费因子分别匹配每一个资费策略,进行计费(即计算出仅适用该资费策略时,该用户应该支付的费用),得到计算结果;将多个资费策略的计费结果进行合并(如选取所有计算结果中资费最少的资费策略的计算结果),得到最终计费结果。The process of charging user services in the prior art may include: obtaining the charging number of the user, the service type of the current service (such as data service and voice service), and charging factors such as service usage; Tariff strategy; use the above billing factors to match each tariff strategy respectively, and perform billing (that is, calculate the fee that the user should pay when only this tariff strategy is applicable), and obtain the calculation result; combine the billing results of multiple tariff strategies Combining (such as selecting the calculation result of the tariff policy with the least tariff among all the calculation results) is performed to obtain the final charging result.

但是,现有技术进行用户业务的计费处理过程中,需要逐个、循序渐进的采用每一个资费策略分别进行计费,然后再多个资费策略的计算结果进行合并,过程复杂,对系统性能消耗较大。However, in the charging process of user services in the prior art, it is necessary to adopt each charging strategy one by one and step by step for charging separately, and then combine the calculation results of multiple charging strategies, the process is complicated and consumes a lot of system performance. big.

发明内容Contents of the invention

本发明的实施例提供一种业务计费方法及装置,可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。Embodiments of the present invention provide a service charging method and device, which can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

为达到上述目的,本发明的实施例采用如下技术方案:In order to achieve the above object, embodiments of the present invention adopt the following technical solutions:

本发明实施例的第一方面,提供一种业务计费方法,包括:According to the first aspect of the embodiments of the present invention, a service charging method is provided, including:

获取一用户的当前业务的业务使用信息;Obtaining service usage information of a user's current service;

确定所述用户为所述当前业务订购的资费策略,并从所述用户为所述当前业务订购的资费策略中,确定出所述当前业务的计费因子;determining the tariff policy ordered by the user for the current service, and determining the billing factor of the current service from the tariff policy subscribed by the user for the current service;

采用所述当前业务的计费因子匹配预先存储的历史计费结果,所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果;Using the charging factor of the current service to match the pre-stored historical charging result, the historical charging result includes the charging factor and the charging result corresponding to the charging factor;

若存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果。If there is a historical charging result that matches the charging factor of the current service, then adopt the historical charging result that matches the charging factor of the current service, and calculate the current service for the current service according to the service usage information of the current service Charging, to obtain the charging result of the current service.

通过本方案,可以从用户为当前业务订购的资费策略中,确定出当前业务的计费因子,然后采用当前业务的计费因子匹配历史计费结果,存在与当前业务的计费因子匹配的历史计费结果,则可以直接复用该历史计费结果对当前业务进行计费,而不是逐个、循序渐进的采用每一个资费策略分别进行计费。复用历史计费结果对当前业务进行计费可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。Through this solution, the charging factor of the current service can be determined from the tariff policy ordered by the user for the current service, and then the charging factor of the current service is used to match the historical charging results, and there is a history of matching the charging factor of the current service If the billing results are obtained, the historical billing results can be directly reused to bill the current service, instead of using each tariff strategy one by one and step by step. Multiplexing the historical charging results to charge the current service can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

可选的,本发明实施例的一种可能的实现方式中,所述当前业务的计费因子包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项;Optionally, in a possible implementation manner of the embodiment of the present invention, the charging factor of the current service includes: at least one of a precise charging factor, a complex charging factor, and a stepped charging factor;

其中,所述精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子;Wherein, the precise billing factor is a billing factor whose value range is limited and whose value directly affects the billing result;

所述复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子;The complex billing factor is a billing factor whose operation result after logical operation affects the billing result;

所述阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子。The step billing factor is a billing factor whose value range cannot be enumerated, is regulated by a mathematical formula, and can be converted into the precise billing factor after mapping.

本方案中,根据用户业务的不同将计费因子分为精确计费因子、复杂计费因子以及阶梯计费因子三类。本方案中的计费因子可以为精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项;由此,通过本方案,便可以采用精确计费因子、复杂计费因子以及阶梯计费因子中任一项或者任意组合,匹配历史计费结果,从而对当前业务进行计费。In this solution, the charging factors are divided into three types according to different user services: precise charging factors, complex charging factors, and stepped charging factors. The billing factor in this scheme can be at least one of the precise billing factor, the complex billing factor and the step billing factor; thus, through this scheme, the precise billing factor, the complex billing factor and the step billing factor can be adopted Any one or any combination of charging factors can match the historical charging results, so as to charge the current service.

可选的,本发明实施例的一种可能的实现方式中,所述精确计费因子包括:精确因子标识和精确因子取值;Optionally, in a possible implementation manner of the embodiment of the present invention, the precise charging factor includes: a precise factor identifier and a precise factor value;

所述复杂计费因子包括:复杂因子标识、复杂因子函数和复杂因子参数;The complex charging factors include: complex factor identification, complex factor functions and complex factor parameters;

所述阶梯计费因子包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。The step charging factor includes: a step factor identifier, a step factor function, a step tariff identifier and a step factor parameter.

可选的,在本发明实施例的一种可能的实现方式中,所述历史计费结果中包含的与所述计费因子存在对应关系的计费结果包括:历史计费公式和业务计费结果中的至少一项;Optionally, in a possible implementation manner of the embodiment of the present invention, the charging results included in the historical charging results and corresponding to the charging factors include: historical charging formulas and service charging at least one of the results;

所述历史计费公式为在历史计费过程中归纳总结得到的与所述计费因子对应的用于计费计算的数学公式;The historical billing formula is a mathematical formula for billing calculation corresponding to the billing factor obtained by summarizing the historical billing process;

所述业务计费结果为在历史计费过程中归纳总结得到的与所述计费因子对应的使用固定业务所需的计费金额。The service charging result is the charging amount required for using the fixed service corresponding to the charging factor and obtained in the historical charging process.

对于资费策略较为简单的计费因子,其所对应的计费结果则可以为上述业务计费结果(即使用固定业务所需的计费金额),例如使用一个数据流量包的计费金额是固定的;而对于资费策略较为复杂的计费因子,其所对应的计费结果则可能需要采用一定的数学公式进行计费计算的数学公式,例如当语音通信的时长大于一定阈值时,其计费金额与固定阈值区间内的语音通信时长满足一定的线性关系。For billing factors with relatively simple tariff policies, the corresponding billing results can be the above-mentioned service billing results (that is, the billing amount required for using fixed services), for example, the billing amount for using a data flow package is fixed For billing factors with more complex tariff policies, the corresponding billing results may need to use certain mathematical formulas for billing calculations. For example, when the duration of voice communication is greater than a certain threshold, the billing The amount satisfies a certain linear relationship with the voice communication duration within the fixed threshold interval.

可选的,在本发明实施例的一种可能的实现方式中,所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子;Optionally, in a possible implementation manner of the embodiment of the present invention, the charging factor of the current service includes: the precise charging factor and the complex charging factor;

所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子;The billing factors of the current service include: the precise billing factor and the complex billing factor;

所述采用所述当前业务的计费因子匹配预先存储的历史计费结果,包括:The matching of the pre-stored historical charging results using the charging factor of the current service includes:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result;

所述若存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果,包括:If there is a historical charging result matching the charging factor of the current service, then adopting the historical charging result matching the charging factor of the current service, according to the service usage information of the current service for the Current service charging, to obtain the charging result of the current service, including:

若存在第三计费结果,则采用所述第三计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果,以获得所述当前业务的计费结果。If there is a third charging result, adopt the third charging result, charge the current service according to the service usage information of the current service, and the third charging result is the second charging result The charging result matched with the complex charging factor in order to obtain the charging result of the current service.

由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高。Since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, and the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result; Compared with complex billing factors, billing factors are easier to match historical billing results, that is, accurate billing factors are more likely to directly reuse historical billing results.

如此,当当前业务的计费因子包括精确计费因子和复杂计费因子时,优先采用精确计费因子匹配历史计费结果(第一计费结果),然后再采用复杂计费因子匹配与精确计费因子匹配的历史计费结果(第二计费结果),则可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, when the billing factors of the current service include precise billing factors and complex billing factors, the precise billing factor is first used to match the historical billing result (the first billing result), and then the complex billing factor is used to match the exact billing factor. The historical charging result (second charging result) matched by the charging factor can improve the possibility of successful matching and the possibility of reusing the historical charging result.

可选的,在本发明实施例的一种可能的实现方式中,所述当前业务的计费因子包括:所述精确计费因子、所述复杂计费因子和所述阶梯计费因子;Optionally, in a possible implementation manner of the embodiment of the present invention, the charging factor of the current service includes: the precise charging factor, the complex charging factor, and the stepped charging factor;

所述采用所述当前业务的计费因子匹配预先存储的历史计费结果,包括:The matching of the pre-stored historical charging results using the charging factor of the current service includes:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result;

若存在第三计费结果,则采用所述阶梯计费因子匹配所述第三计费结果,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果;If there is a third charging result, matching the third charging result with the stepped charging factor, where the third charging result is the second charging result that matches the complex charging factor billing result;

所述若存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果,包括:If there is a historical charging result matching the charging factor of the current service, then adopting the historical charging result matching the charging factor of the current service, according to the service usage information of the current service for the Current service charging, to obtain the charging result of the current service, including:

若存在第四计费结果,则采用所述第四计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第四计费结果为所述第三计费结果中与所述阶梯计费因子匹配的计费结果,以获得所述当前业务的计费结果。If there is a fourth charging result, adopt the fourth charging result, charge the current service according to the service usage information of the current service, and the fourth charging result is the third charging result The charging result matched with the step charging factor in order to obtain the charging result of the current service.

由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子,阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高;复杂计费因子相较于阶梯计费因子,更容易匹配历史计费结果,即复杂计费因子复用历史计费结果的可能性高于阶梯计费因子复用历史计费结果的可能性。Since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, and the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result, step billing The factor is a billing factor whose value range is not enumerable, regularized by mathematical formula, and can be converted into the precise billing factor after mapping; therefore, it can be seen that the precise billing factor is easier to match the historical billing than the complex billing factor As a result, accurate billing factors are more likely to directly reuse historical billing results; complex billing factors are easier to match historical billing results than ladder billing factors, that is, complex billing factors reuse historical billing results The probability of the result is higher than the possibility of multiplexing the historical charging results by the step charging factor.

如此,当当前业务的计费因子包括精确计费因子、复杂计费因子和阶梯计费因子时,依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果,可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, when the billing factors of the current service include precise billing factors, complex billing factors, and step billing factors, matching historical billing results with precise billing factors, complex billing factors, and step billing factors can improve The probability of successful matching and the possibility of reusing historical billing results.

优选的,在本发明实施例的一种可能的实现方式中,所述当前业务的计费因子中包含所述当前业务的计费因子对应的序列化特征值,该序列化特征值用于唯一标识该计费因子;Preferably, in a possible implementation of the embodiment of the present invention, the charging factor of the current service includes a serialized characteristic value corresponding to the charging factor of the current service, and the serialized characteristic value is used for unique identify the charging factor;

所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果,具体为:The historical billing results include billing factors and billing results corresponding to the billing factors, specifically:

所述历史计费结果中包含待匹配序列化特征值以及与所述待匹配序列化特征值存在对应关系的计费结果,一个所述待匹配序列化特征值用于唯一标识一个计费因子。The historical charging results include serialized characteristic values to be matched and charging results corresponding to the serialized characteristic values to be matched, and one serialized characteristic value to be matched is used to uniquely identify a charging factor.

可以想到的是,为了提高计费因子与历史计费结果的匹配速度,本发明实施例中可以对计费因子进行序列化,为其生成一个可以唯一标识该计费因子的序列化特征值,然后通过序列化特征值的匹配实现计费因子与历史计费结果的匹配。It is conceivable that, in order to improve the matching speed of the billing factor and the historical billing result, the billing factor can be serialized in the embodiment of the present invention, and a serialized characteristic value that can uniquely identify the billing factor can be generated for it, Then, the matching of the billing factor and the historical billing result is realized through the matching of serialized characteristic values.

可选的,在本发明实施例的一种可能的实现方式中,所述采用所述当前业务的计费因子匹配预先存储的历史计费结果,包括:Optionally, in a possible implementation manner of the embodiment of the present invention, the matching of the pre-stored historical charging results using the charging factor of the current service includes:

采用所述当前业务的计费因子对应的序列化特征值匹配预先存储的待匹配序列化特征值;Using the serialized characteristic value corresponding to the billing factor of the current service to match the pre-stored serialized characteristic value to be matched;

其中,当所述当前业务的计费因子对应的序列化特征值等于一待匹配序列化特征值时,所述当前业务的计费因子与该待匹配序列化特征值对应的计费结果匹配。Wherein, when the serialized characteristic value corresponding to the charging factor of the current service is equal to a serialized characteristic value to be matched, the charging factor of the current service matches the charging result corresponding to the serialized characteristic value to be matched.

进一步的,在本发明实施例的一种可能的实现方式中,所述业务计费方法还包括:Further, in a possible implementation manner of the embodiment of the present invention, the service charging method further includes:

若不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果。If there is no historical charging result matching the charging factor of the current service, each of the charging strategies subscribed by the user for the current service is adopted to charge the current service, so that Obtain the charging result of the current service.

本方案中,当不存在与当前业务的计费因子匹配的历史计费结果时,则可以分别采用用户为所述当前业务订购的资费策略中的每一个资费策略,为当前业务计费。如此,无论是否存在与当前业务的计费因子匹配的历史计费结果,通过本方案均可以为当前业务计费,获得当前业务的计费结果。In this solution, when there is no historical charging result matching the charging factor of the current service, each of the charging policies subscribed by the user for the current service may be used to charge the current service. In this way, no matter whether there is a historical charging result matching the charging factor of the current service, the current service can be charged through this solution, and the charging result of the current service can be obtained.

需要说明的是,本发明实施例这里的提到的“不存在与当前业务的计费因子匹配的历史计费结果”包括:“不存在与上述精确计费因子匹配的历史计费结果”、“不存在与上述复杂计费因子匹配的历史计费结果”以及“不存在与上述阶梯计费因子匹配的历史计费结果”中的任意一项。It should be noted that "there is no historical charging result matching the charging factor of the current service" mentioned here in the embodiment of the present invention includes: "there is no historical charging result matching the above-mentioned precise charging factor", Either one of "there is no historical charging result matching the above-mentioned complex charging factor" and "there is no historical charging result matching the above-mentioned tiered charging factor".

需要强调的是,当当前业务的计费因子包括:精确计费因子和复杂计费因子,或者当前业务的计费因子包括:精确计费因子、复杂计费因子和阶梯计费因子时,若不存在与上述精确计费因子匹配的历史计费结果,则不需要再采用复杂计费因子匹配历史计费结果。It should be emphasized that when the billing factors of the current service include: precise billing factor and complex billing factor, or the billing factors of the current service include: precise billing factor, complex billing factor and stepped billing factor, if If there is no historical charging result matching the above-mentioned precise charging factor, it is not necessary to use complex charging factors to match the historical charging result.

同理,当前业务的计费因子包括:精确计费因子、复杂计费因子和阶梯计费因子时,若不存在与上述复杂计费因子匹配的历史计费结果,则不需要再采用阶梯计费因子匹配历史计费结果。Similarly, when the billing factors of the current service include: precise billing factors, complex billing factors, and step billing factors, if there is no historical billing result that matches the above complex billing factors, it is not necessary to use step billing again. The fee factor matches historical charging results.

可选的,在所述若不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果之后,所述方法还包括:保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。Optionally, if there is no historical charging result matching the charging factor of the current service, each of the charging policies subscribed by the user for the current service is adopted respectively, for all After charging the current service to obtain the charging result of the current service, the method further includes: saving the correspondence between the charging factor of the current service and the charging result of the current service.

可以想到的是,保存当前业务的计费因子与当前业务的计费结果之间的对应关系后,下次对类似业务进行计费时,则可以直接复用本次保存的与当前业务的计费因子存在对应关系的计费结果,则不需要按照第五种可能的实现方式中所述的计费方式对类似业务进行计费,从而可以减少上述类似业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。It is conceivable that after saving the corresponding relationship between the billing factor of the current business and the billing result of the current business, the next time the similar business is billed, the saved calculation of the current business can be directly reused. If there is a charging result corresponding to the fee factor, it is not necessary to charge similar services according to the charging method described in the fifth possible implementation mode, thereby reducing the amount of calculation in the charging process of the above-mentioned similar services, simplifying The billing process can reduce the consumption of system performance.

优选的,所述保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系,包括:Preferably, said storing the corresponding relationship between the charging factor of the current service and the charging result of the current service includes:

若所述当前业务的计费因子的使用频率高于第一频率阈值,则保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。If the usage frequency of the charging factor of the current service is higher than the first frequency threshold, storing the correspondence between the charging factor of the current service and the charging result of the current service.

本方案中,仅保存使用频率高于第一频率阈值的计费因子以及与其存在对应关系的计费结果,可以避免不常用(即使用频率较低)的计费因子以及与其存在对应关系的计费结果对计费系统存储空间的占用,影响系统性能。In this solution, only billing factors whose usage frequency is higher than the first frequency threshold and the billing results corresponding to them are saved, which can avoid charging factors that are not commonly used (that is, less frequently used) and billing factors corresponding to them. The billing results occupy the storage space of the billing system and affect system performance.

可选的,为了进一步避免不常用(即使用频率较低)的计费因子以及与其存在对应关系的计费结果对计费系统存储空间的占用,本发明实施例的方法还可以包括:Optionally, in order to further avoid infrequently used (that is, less frequently used) charging factors and charging results corresponding to them from occupying the storage space of the charging system, the method in the embodiment of the present invention may further include:

若所述当前业务的计费因子的使用频率低于第二频率阈值,则删除所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。If the usage frequency of the charging factor of the current service is lower than the second frequency threshold, delete the correspondence between the charging factor of the current service and the charging result of the current service.

本发明实施例的第二方面,提供一种业务计费装置,包括:The second aspect of the embodiments of the present invention provides a service charging device, including:

获取单元,用于获取一用户的当前业务的业务使用信息;an acquisition unit, configured to acquire service use information of a user's current service;

确定单元,用于确定所述用户为所述当前业务订购的资费策略,并从所述用户为所述当前业务订购的资费策略中,确定出所述当前业务的计费因子;A determining unit, configured to determine the charging policy subscribed by the user for the current service, and determine the charging factor of the current service from the charging policy subscribed by the user for the current service;

匹配单元,用于采用所述确定单元确定的所述当前业务的计费因子匹配预先存储的历史计费结果,所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果;A matching unit, configured to use the charging factor of the current service determined by the determining unit to match a pre-stored historical charging result, where the historical charging result includes a charging factor and has a corresponding relationship with the charging factor the billing results;

计费单元,用于若所述匹配单元确定存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果。The charging unit is configured to adopt the historical charging result matching the charging factor of the current service if the matching unit determines that there is a historical charging result matching the charging factor of the current service, according to the The service usage information of the current service charges the current service, so as to obtain the charging result of the current service.

结合第二方面,在第一种可能的实现方式中,所述当前业务的计费因子包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项;With reference to the second aspect, in a first possible implementation manner, the charging factor of the current service includes: at least one of a precise charging factor, a complex charging factor, and a stepped charging factor;

其中,所述精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子;Wherein, the precise billing factor is a billing factor whose value range is limited and whose value directly affects the billing result;

所述复杂计费因子为经过函数运算后的运算结果影响计费结果的计费因子;The complex billing factor is a billing factor whose calculation result after the function operation affects the billing result;

所述阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子。The step billing factor is a billing factor whose value range cannot be enumerated, is regulated by a mathematical formula, and can be converted into the precise billing factor after mapping.

结合第一种可能的实现方式,在第二种可能的实现方式中,所述精确计费因子包括:精确因子标识和精确因子取值;With reference to the first possible implementation, in the second possible implementation, the precise charging factor includes: a precise factor identifier and a precise factor value;

所述复杂计费因子包括:复杂因子标识、复杂因子函数和复杂因子参数;The complex charging factors include: complex factor identification, complex factor functions and complex factor parameters;

所述阶梯计费因子包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。The step charging factor includes: a step factor identifier, a step factor function, a step tariff identifier and a step factor parameter.

结合第二方面、第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述历史计费结果中包含的与所述计费因子存在对应关系的计费结果包括:历史计费公式和业务计费结果中的至少一项;With reference to the second aspect, the first possible implementation manner, or the second possible implementation manner, in a third possible implementation manner, the historical charging results included in the The charging results include: at least one of historical charging formulas and service charging results;

所述历史计费公式为在历史计费过程中归纳总结得到的与所述计费因子对应的用于计费计算的数学公式;The historical billing formula is a mathematical formula for billing calculation corresponding to the billing factor obtained by summarizing the historical billing process;

所述业务计费结果为在历史计费过程中归纳总结得到的与所述计费因子对应的计费金额。The service charging result is the charging amount corresponding to the charging factor summed up in the historical charging process.

结合第一种可能的实现方式或第二种可能的实现方式,在第四种可能的实现方式中,所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子;With reference to the first possible implementation or the second possible implementation, in a fourth possible implementation, the charging factor of the current service includes: the precise charging factor and the complex charging factor ;

所述匹配单元,具体用于:The matching unit is specifically used for:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result;

所述计费单元,具体用于:The billing unit is specifically used for:

若所述匹配单元确定存在第三计费结果,则采用所述第三计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果,以获得所述当前业务的计费结果。If the matching unit determines that there is a third charging result, the third charging result is adopted, and the current service is charged according to the service usage information of the current service, and the third charging result is the A charging result matching the complex charging factor in the second charging result to obtain the charging result of the current service.

结合第一种可能的实现方式或第二种可能的实现方式,在第五种可能的实现方式中,所述当前业务的计费因子包括:所述精确计费因子、所述复杂计费因子和所述阶梯计费因子;With reference to the first possible implementation or the second possible implementation, in a fifth possible implementation, the charging factors of the current service include: the precise charging factor, the complex charging factor and the tiered charging factor;

所述匹配单元,具体用于:The matching unit is specifically used for:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result;

若存在第三计费结果,则采用所述阶梯计费因子匹配所述第三计费结果,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果;If there is a third charging result, matching the third charging result with the stepped charging factor, where the third charging result is the second charging result that matches the complex charging factor billing result;

所述计费单元,具体用于:The billing unit is specifically used for:

若所述匹配单元确定存在第四计费结果,则采用所述第四计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第四计费结果为所述第三计费结果中与所述阶梯计费因子匹配的计费结果,以获得所述当前业务的计费结果。If the matching unit determines that there is a fourth charging result, the fourth charging result is adopted, and the current service is charged according to the service usage information of the current service, and the fourth charging result is the A charging result matching the step charging factor in the third charging result to obtain the charging result of the current service.

结合第二方面,第一种可能的实现方式或第二种可能的实现方式,在第六种可能的实现方式中,所述当前业务的计费因子中包含所述当前业务的计费因子对应的序列化特征值,该序列化特征值用于唯一标识该计费因子;With reference to the second aspect, the first possible implementation manner or the second possible implementation manner, in a sixth possible implementation manner, the charging factor of the current service includes the charging factor corresponding to the current service The serialized characteristic value of the serialized characteristic value is used to uniquely identify the billing factor;

所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果,具体为:The historical billing results include billing factors and billing results corresponding to the billing factors, specifically:

所述历史计费结果中包含待匹配序列化特征值以及与所述待匹配序列化特征值存在对应关系的计费结果,一个所述待匹配序列化特征值用于唯一标识一个计费因子。The historical charging results include serialized characteristic values to be matched and charging results corresponding to the serialized characteristic values to be matched, and one serialized characteristic value to be matched is used to uniquely identify a charging factor.

结合第六种可能的实现方式,在第七种可能的实现方式中,所述匹配单元,具体用于:With reference to the sixth possible implementation manner, in the seventh possible implementation manner, the matching unit is specifically configured to:

采用所述当前业务的计费因子对应的序列化特征值匹配预先存储的待匹配序列化特征值;Using the serialized characteristic value corresponding to the billing factor of the current service to match the pre-stored serialized characteristic value to be matched;

其中,当所述当前业务的计费因子对应的序列化特征值等于一待匹配序列化特征值时,所述当前业务的计费因子与该待匹配序列化特征值对应的计费结果匹配。Wherein, when the serialized characteristic value corresponding to the charging factor of the current service is equal to a serialized characteristic value to be matched, the charging factor of the current service matches the charging result corresponding to the serialized characteristic value to be matched.

结合第二方面,第一种可能的实现方式或第二种可能的实现方式,在第八种可能的实现方式中,所述计费单元,还用于:With reference to the second aspect, the first possible implementation manner or the second possible implementation manner, in an eighth possible implementation manner, the billing unit is further configured to:

若所述匹配单元确定不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果。If the matching unit determines that there is no historical charging result that matches the charging factor of the current service, each tariff policy in the tariff policies ordered by the user for the current service is respectively adopted to provide the current Service charging, to obtain the charging result of the current service.

结合第七种可能的实现方式,在第九种可能的实现方式中,所述业务计费装置还包括:With reference to the seventh possible implementation manner, in a ninth possible implementation manner, the service charging device further includes:

保存单元,用于在所述计费单元分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果之后,保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。A storage unit, configured to use each of the tariff policies subscribed by the user for the current service in the charging unit to charge the current service, so as to obtain the charging result of the current service Afterwards, the corresponding relationship between the charging factor of the current service and the charging result of the current service is saved.

结合第九种可能的实现方式,在第十种可能的实现方式中,所述保存单元,具体用于:With reference to the ninth possible implementation manner, in the tenth possible implementation manner, the storage unit is specifically configured to:

若所述当前业务的计费因子的使用频率高于第一频率阈值,则保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。If the usage frequency of the charging factor of the current service is higher than the first frequency threshold, storing the correspondence between the charging factor of the current service and the charging result of the current service.

结合第九种可能的实现方式,在第十一种可能的实现方式中,所述业务计费装置,还包括:With reference to the ninth possible implementation manner, in the eleventh possible implementation manner, the service charging device further includes:

删除单元,用于若所述当前业务的计费因子的使用频率低于第二频率阈值,则删除所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。A deleting unit, configured to delete the correspondence between the charging factor of the current service and the charging result of the current service if the usage frequency of the charging factor of the current service is lower than a second frequency threshold.

本发明实施例的第三方面提供一种业务计费装置,所述业务计费装置包括:一个或多个处理器、存储器、总线系统、收发器以及一个或多个应用程序,所述一个或多个处理器、所述存储器和所述收发器通过所述总线系统相连;A third aspect of the embodiments of the present invention provides a service charging device, the service charging device includes: one or more processors, memory, bus system, transceiver and one or more application programs, the one or more a plurality of processors, said memory and said transceiver are connected via said bus system;

所述一个或多个应用程序存储在所述存储器中,所述一个或多个应用程序包括指令,当所述业务计费装置的处理器执行所述指令时,所述业务计费装置执行如第一方面以及第一方面的各种可选方式所述的业务计费方法。The one or more application programs are stored in the memory, the one or more application programs include instructions, and when the processor of the service charging device executes the instructions, the service charging device performs the following steps: The service charging method described in the first aspect and various optional modes of the first aspect.

本发明实施例的第四方面提供一种计算机可读存储介质,所述计算机可读存储介质中存储有一个或多个程序,所述一个或多个程序包括指令,当所述业务计费装置的处理器执行所述指令时,所述业务计费装置执行如第一方面以及第一方面的各种可选方式所述的业务计费方法。A fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, one or more programs are stored in the computer-readable storage medium, and the one or more programs include instructions. When the service charging device When the processor executes the instructions, the service charging device executes the service charging method described in the first aspect and various optional modes of the first aspect.

需要说明的是,本发明实施例第二方面以及第三方面提供的业务计费装置的相关技术效果可参见上述第一方面及其各种可选方式中的相关描述,此处不再赘述。It should be noted that, for related technical effects of the service charging device provided in the second aspect and the third aspect of the embodiment of the present invention, reference may be made to the related descriptions in the first aspect and its various optional modes, and details are not repeated here.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. For those skilled in the art, other drawings can also be obtained according to these drawings without any creative effort.

图1为本发明实施例提供的一种在线计费系统的示意图;FIG. 1 is a schematic diagram of an online charging system provided by an embodiment of the present invention;

图2为本发明实施例提供的在线计费系统的网络架构示意图;FIG. 2 is a schematic diagram of a network architecture of an online charging system provided by an embodiment of the present invention;

图3为本发明实施例提供的一种业务计费方法的流程示意图;FIG. 3 is a schematic flowchart of a service charging method provided by an embodiment of the present invention;

图4为本发明实施例提供的另一种业务计费方法的流程示意图;FIG. 4 is a schematic flowchart of another service charging method provided by an embodiment of the present invention;

图5为本发明实施例提供的另一种业务计费方法的流程示意图;FIG. 5 is a schematic flowchart of another service charging method provided by an embodiment of the present invention;

图6为本发明实施例提供的另一种业务计费方法的流程示意图;FIG. 6 is a schematic flowchart of another service charging method provided by an embodiment of the present invention;

图7为本发明实施例提供的另一种业务计费方法的流程示意图;FIG. 7 is a schematic flowchart of another service charging method provided by an embodiment of the present invention;

图8为本发明实施例提供的一种业务计费方法的流程示意图;FIG. 8 is a schematic flowchart of a service charging method provided by an embodiment of the present invention;

图9为本发明实施例提供的一种业务计费装置的组成示意图;FIG. 9 is a schematic composition diagram of a service charging device provided by an embodiment of the present invention;

图10为本发明实施例提供的一种业务计费装置的组成示意图;FIG. 10 is a schematic composition diagram of a service charging device provided by an embodiment of the present invention;

图11为本发明实施例提供的一种业务计费装置的组成示意图。Fig. 11 is a schematic composition diagram of a service charging device provided by an embodiment of the present invention.

具体实施方式detailed description

本发明的说明书以及附图中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一频率阈值和第二频率阈值是用于区别频率阈值,而不是用于描述频率阈值的特征顺序。The terms "first" and "second" and the like in the description and drawings of the present invention are used to distinguish different objects, rather than to describe a specific order of objects. For example, the first frequency threshold and the second frequency threshold are used to distinguish the frequency thresholds, not to describe the characteristic sequence of the frequency thresholds.

在本发明的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理器是指两个或两个以上处理器。In the description of the present invention, unless otherwise specified, the meaning of "plurality" refers to two or more than two. For example, multiple processors refers to two or more processors.

此外,本发明的描述中所提到的术语“包括”和“具有”以及它们的任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括其他没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其它步骤或单元。In addition, the terms "including" and "having" and any variations thereof mentioned in the description of the present invention are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units is not limited to the listed steps or units, but optionally also includes other unlisted steps or units, or optionally also includes Other steps or elements inherent to the process, method, product or apparatus are included.

另外,本文中术语“系统”和“网络”在本文中常被可互换使用。本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中字符“/”,一般表示前后关联对象是一种“或”的关系。Additionally, the terms "system" and "network" are often used herein interchangeably. The term "and/or" in this article is just an association relationship describing associated objects, which means that there can be three relationships, for example, A and/or B can mean: A exists alone, A and B exist simultaneously, and there exists alone B these three situations. In addition, the character "/" in this article generally indicates that the contextual objects are an "or" relationship.

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行详细地描述,显然,所描述的实施例仅仅是本发明的一部分实施例,而不是全部实施例。The technical solutions in the embodiments of the present invention will be described in detail below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them.

本发明实施例提供的业务计费方法可以应用于如图1所示的在线计费系统(Online Charging System,OCS),如图1所示,该OCS 10至少可以包括:资费数据库11、用户数据库12和计费服务器13。其中,资费数据库11、用户数据库12和计费服务器13之间相互连接。The service charging method provided by the embodiment of the present invention can be applied to an online charging system (Online Charging System, OCS) as shown in Figure 1, as shown in Figure 1, the OCS 10 can include at least: tariff database 11, user database 12 and billing server 13. Among them, the tariff database 11, the user database 12 and the billing server 13 are connected to each other.

其中,资费数据库11用于存储资费策略不同的资费策略对应于不同的业务类型。运营管理人员可以通过管理客户端向资费数据库11中配置资费策略;并且,运营管理人员可以根据运营商为用户提供的业务类型的变化实时更新资费数据库11中保存的资费策略。Wherein, the tariff database 11 is used for storing tariff policies. Different tariff policies correspond to different service types. The operation manager can configure the tariff policy in the tariff database 11 through the management client; and the operation manager can update the tariff policy stored in the tariff database 11 in real time according to the change of the service type provided by the operator for the user.

用户数据库12用于存储用户的资费数据(如用户所订购的资费策略)和用户的账户余额。其中,运营商可以通过一定的平台向用户展示资费数据库11中配置资费策略,以供用户选择,当用户选择了资费数据库11中配置的相关资费策略后,则可以由用户数据库12记录并存储该相关资费策略,以便于计费服务器13用于用户的业务使用信息,结合用户数据库12保存的相关资费策略,对用户业务进行计费。The user database 12 is used to store the tariff data of the user (such as the tariff policy subscribed by the user) and the account balance of the user. Among them, the operator can display the tariff strategy configured in the tariff database 11 to the user through a certain platform for the user to choose. When the user selects the relevant tariff strategy configured in the tariff database 11, the user database 12 can record and store the tariff strategy Relevant charging policies, so that the billing server 13 can use the user's service usage information in combination with the relevant charging policies stored in the user database 12 to charge the user's services.

可以想到的是,用户数据库12可以仅存储用户订购的资费策略的标识,计费服务器13可以根据用户数据库12中存储的用户订购的资费策略的标识从资费数据库11中查询具体的资费策略。It is conceivable that the user database 12 may only store the identification of the tariff policy subscribed by the user, and the charging server 13 may query the specific tariff policy from the tariff database 11 according to the identification of the tariff policy subscribed by the user stored in the user database 12 .

示例性的,为了实现OCS的在线计费,如图2所示,OCS连接无线局域网络(Wireless Local Area Networks,WLAN),并分别网络侧的移动交换中心(MobileSwitching Center,MSC)、服务GPRS支持节点(Serving GPRS Support Node,SGSN)、IP多媒体子系统应用服务器(IP Multimedia Subsystem Application Server,IMS AS)、IMS多媒体资源控制器(Multimedia Resource Function Controller,MRFC)以及IMS多媒体资源处理器(Multimedia Resource Function Processor,MRFP)建立连接。同时,为了实时更新OCS中保存的用户账户余额,OCS还可以连接充值服务器(Charging Server),以便于实时从充值服务器获得用户的充值信息。Exemplarily, in order to realize the online charging of OCS, as shown in Figure 2, OCS is connected to wireless local area network (Wireless Local Area Networks, WLAN), and mobile switching center (MobileSwitching Center, MSC) of network side, service GPRS support respectively Node (Serving GPRS Support Node, SGSN), IP Multimedia Subsystem Application Server (IP Multimedia Subsystem Application Server, IMS AS), IMS Multimedia Resource Controller (Multimedia Resource Function Controller, MRFC) and IMS Multimedia Resource Processor (Multimedia Resource Function Processor, MRFP) to establish a connection. At the same time, in order to update the balance of the user's account stored in the OCS in real time, the OCS can also be connected to a charging server (Charging Server), so as to obtain the user's charging information from the charging server in real time.

本发明实施例提供的业务计费方法可以应用于上述计费服务器13对用户业务进行计费的过程中。本发明实施例提供的业务计费方法的执行主体可以为计费服务器或者计费服务器中用于执行上述业务计费方法的装置(如业务计费装置),计费服务器中用于执行上述业务计费方法的装置可以为上述计费服务器的中央处理器(CentralProcessing Unit,CPU)或者可以为上述计费服务器的中的控制单元或者模块。其中,本发明实施例中以业务计费装置为业务计费方法的执行主体为例,对本发明实施例提供的业务计费方法进行详细说明。The service charging method provided by the embodiment of the present invention can be applied to the process of charging user services by the charging server 13 described above. The execution subject of the service charging method provided by the embodiment of the present invention may be a charging server or a device (such as a service charging device) used to execute the above-mentioned service charging method in the charging server, and the charging server is used to perform the above-mentioned business. The apparatus of the charging method may be a central processing unit (Central Processing Unit, CPU) of the above-mentioned charging server, or may be a control unit or a module in the above-mentioned charging server. Wherein, in the embodiment of the present invention, the service charging method provided by the embodiment of the present invention is described in detail by taking the service charging device as the execution body of the service charging method as an example.

下面结合附图,通过具体的实施例及其应用场景对本发明实施例提供的一种业务计费方法及装置进行详细地说明。A service charging method and device provided in the embodiments of the present invention will be described in detail below through specific embodiments and application scenarios with reference to the accompanying drawings.

本发明实施例提供一种业务计费方法,如图3所示,该业务计费方法包括:An embodiment of the present invention provides a service charging method, as shown in Figure 3, the service charging method includes:

S101、业务计费装置获取一用户的当前业务的业务使用信息。S101. The service charging device acquires service usage information of a user's current service.

示例性的,用户的当前业务可以为:语音通信业务、短信业务、数据流量业务、彩信业务以及彩铃订购业务等电信业务中的任一项。其中,上述数据流量业务至少可以包括数据流量包订购业务和数据流量通信业务。Exemplarily, the user's current service may be any one of telecommunication services such as voice communication service, short message service, data traffic service, multimedia message service, and ring tone subscription service. Wherein, the above-mentioned data flow service may at least include a data flow package subscription service and a data flow communication service.

当前业务的业务使用信息可以包括:用户对该当前业务的使用情况、该用户当前可以使用的资源和余额,以及该用户本月的消费累计信息。The service use information of the current service may include: the user's use of the current service, the resources and balance currently available to the user, and the accumulated consumption information of the user this month.

例如,若当前业务为语音通信业务,则当前业务的业务使用信息可以包含本次语音通信的时长、本次语音通信的开始时间、本次语音通信的主叫号码、本次语音通信的被叫号码以及本次语音通信的发生地等信息;该用户当前可以使用的资源则可以为该用户当前可以用的免费通话时长,余额即为该用户的账户余额;该用户本月的消费累计信息则可以包括该用户的通话累计时长和该用户语音通话的累计资费金额。For example, if the current service is a voice communication service, the service usage information of the current service may include the duration of this voice communication, the start time of this voice communication, the calling number of this voice communication, the called number of this voice communication information such as the number and the place where the voice communication occurred; the resources currently available to the user can be the free call time currently available to the user, and the balance is the account balance of the user; the cumulative consumption information of the user this month is It may include the accumulated call duration of the user and the accumulated charge amount of the user's voice call.

需要说明的是,本发明实施例中的当前业务包括但不限于上述所列举的用户业务,其他的用户业务可以参考现有电信业务中的用户业务,此处不再赘述。并且,本发明实施例中当前业务的业务使用信息包括但不限于上述所列举的业务使用信息,各个用户业务的业务使用信息的详细内容可以参考现有电信业务中的用户业务的业务使用信息,此处不再赘述。It should be noted that the current services in the embodiments of the present invention include but are not limited to the user services listed above, and other user services may refer to the user services in the existing telecommunication services, which will not be repeated here. Moreover, the service use information of the current service in the embodiment of the present invention includes but is not limited to the above-mentioned service use information, and the detailed content of the service use information of each user service can refer to the service use information of the user service in the existing telecommunication service, I won't repeat them here.

S102、业务计费装置确定用户为当前业务订购的资费策略。S102. The service charging device determines the charging policy subscribed by the user for the current service.

可以想到的是,用户可以根据需求订购包含多个资费策略的资费套餐。例如,一A地用户S1可以订购如下资费策略:(P1)38元月基本套餐,包含:本月内100分钟免费市话、30M免费数据流量、市话资费0.3元/分钟以及长途资费0.5元/分钟;(P2)10元50M数据流量,超出50M后0.29元/Kb;(P3)语音资费策略1:市话前10分钟的资费为0.3元/分钟,市话10分钟后的资费为0.2元/分钟;(P4)语音资费策略2:闲时(22:00-24:00)通话,50%优惠;(P5)语音资费策略3:长途费50元封顶,本月长途资费超过50元后不再计费(即免费);(P6)语音资费策略4:本月长途累计时长超过300分钟,赠送60分钟长途免费时长;(P7)语音资费策略5:在A地呼叫B地用户,0.05元/分钟。It is conceivable that a user may order a tariff package including multiple tariff strategies according to requirements. For example, a user S1 in a place A can order the following tariff policy: (P1) 38 yuan monthly basic package, including: 100 minutes of free local calls, 30M free data traffic, local call charges 0.3 yuan/minute and long-distance charges 0.5 yuan/minute ; (P2) 10 yuan for 50M data traffic, 0.29 yuan/Kb after exceeding 50M; (P3) voice tariff policy 1: the tariff for the first 10 minutes of local calls is 0.3 yuan/minute, and the tariff for local calls after 10 minutes is 0.2 yuan/minute; (P4) Voice Tariff Strategy 2: 50% discount for calls during idle hours (22:00-24:00); (P5) Voice Tariff Strategy 3: Long-distance charges are capped at 50 yuan, and the long-distance charges will not be counted if they exceed 50 yuan this month. (that is, free); (P6) Voice tariff strategy 4: If the accumulated long-distance time exceeds 300 minutes this month, 60 minutes of long-distance free time will be given as a gift; (P7) Voice tariff strategy 5: 0.05 yuan/minute for calling a user in B from A .

其中,业务计费装置(计费服务器13)可以根据一用户的账户(如手机号码)从用户数据库12中查询得到该用户所订购的所有资费策略,然后从该用户所订购的所有资费策略中确定出该用户为当前业务订购的资费策略。Wherein, the service billing device (billing server 13) can query from the user database 12 according to a user's account (such as a mobile phone number) to obtain all the tariff policies ordered by the user, and then obtain all tariff policies ordered by the user. Determine the tariff policy subscribed by the user for the current service.

基于上述实例,假设当前业务为语音通信业务,具体为用户S1对B地的用户S2的语音通信业务;业务计费装置则可以从用户S1订购的所有资费策略(P1)-(P7)中,确定出用户S1为上述语音通信业务所订购的资费策略(P4)-(P7)。Based on the above example, assume that the current service is a voice communication service, specifically the voice communication service of user S1 to user S2 at B; The tariff policies (P4)-(P7) subscribed by the user S1 for the voice communication service are determined.

S103、业务计费装置从用户为当前业务订购的资费策略中,确定出当前业务的计费因子。S103. The service charging device determines the charging factor of the current service from the charging policy subscribed by the user for the current service.

示例性的,本发明实施例中当前业务的计费因子可以包括:当前业务的业务类型(包括:语音业务、数据业务、短信业务和彩信业务)、当前业务的长途或短途(包括:本地、长途、国际)、当前业务的网划分(包括:网内呼叫和网外)、定时优惠、定向长途等。Exemplarily, the charging factor of the current service in the embodiment of the present invention may include: the service type of the current service (including: voice service, data service, short message service and multimedia message service), the long distance or short distance of the current service (including: local, long-distance, international), current service network division (including: on-net call and off-net call), fixed-time discount, directional toll, etc.

其中,此处的网内呼叫是指属于同一运营商的号码之间的呼叫(如电信用户对电信用户的呼叫),网外是指不同运营商的号码之间的呼叫(如电信用户对移动用户的呼叫)。Among them, the in-network call here refers to the call between numbers belonging to the same operator (such as a call from a telecom user to a telecom user), and the off-net refers to a call between numbers of different operators (such as a call from a telecom user to a mobile user's call).

本发明实施例中的计费因子可以包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项。The billing factor in this embodiment of the present invention may include: at least one of a precise billing factor, a complex billing factor, and a stepped billing factor.

其中,精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子。本发明实施例中的精确计费因子可以包括:精确因子标识和精确因子取值。Wherein, the accurate billing factor is a billing factor whose value range is limited, and whose value directly affects the billing result. The precise charging factor in this embodiment of the present invention may include: a precise factor identifier and a precise factor value.

示例性的,本发明实施例中的精确计费因子可以包括:业务类型、长途或短途、网划分以及资费组合(包括:用户所订购所有资费策略的任意组合)等。例如,如表1所示,为本发明实施例提供的精确计费因子实例:Exemplarily, the precise billing factor in this embodiment of the present invention may include: service type, long-distance or short-distance, network division, and tariff combination (including: any combination of all tariff policies subscribed by the user), etc. For example, as shown in Table 1, the precise charging factor example provided for the embodiment of the present invention:

表1Table 1

其中,复杂计费因子为经过函数运算后的运算结果影响计费结果的计费因子。本发明实施例中的复杂计费因子可以包括:复杂因子标识、复杂因子函数和复杂因子参数。Wherein, the complex charging factor is a charging factor whose operation result after the function operation affects the charging result. The complex charging factor in this embodiment of the present invention may include: a complex factor identifier, a complex factor function, and a complex factor parameter.

示例性的,以语音通信业务的定时优惠为例,如表2所示,为本发明实施例提供的复杂计费因子实例:Exemplarily, taking the timing preference of the voice communication service as an example, as shown in Table 2, it is an example of the complex charging factor provided by the embodiment of the present invention:

表2Table 2

其中,表2中的Funcl 1(复杂因子函数)为对22:00-24:00时段所进行的语音通话进行计费所要使用的数学函数,Funcl 2(复杂因子函数)为对9:00-11:00时段所进行的语音通话进行计费所要使用的数学函数。Wherein, Funcl 1 (complex factor function) in Table 2 is the mathematical function to be used for charging the voice calls carried out in the 22:00-24:00 period, and Funcl 2 (complex factor function) is the mathematical function to be used for 9:00-24:00 Mathematical function to be used for billing of voice calls made during the 11:00 time period.

例如,假设在22:00-24:00时段的语音通信的资费为0.05元/分钟,此时,Funcl1=0.05×△t1,△t1为表2中的时刻t 1到时刻t 2的时长,其中,时刻t 1和时刻t 2均为[22:00,24:00]内的时刻。假设在9:00-11:00时段的语音通信的资费为0.6元/分钟,此时,Funcl 2=0.6×△t2,△t2为表2中的时刻t 3到时刻t 4的时长,其中,时刻t3和时刻t 4均为[9:00,11:00]内的时刻。For example, assuming that the rate of voice communication in the 22:00-24:00 period is 0.05 yuan/minute, at this time, Funcl1=0.05×Δt1, Δt1 is the duration from time t1 to time t2 in Table 2, Wherein, the time t 1 and the time t 2 are both within [22:00, 24:00]. Assuming that the voice communication fee in the 9:00-11:00 period is 0.6 yuan/minute, at this time, Funcl 2=0.6×Δt2, Δt2 is the time length from time t3 to time t4 in Table 2, where , both time t3 and time t4 are within [9:00,11:00].

示例性的,以语音通信业务的定向呼叫方案为例,如表3所示,为本发明实施例提供的复杂计费因子实例:Exemplarily, taking the directional call scheme of the voice communication service as an example, as shown in Table 3, it is an example of the complex charging factor provided by the embodiment of the present invention:

表3table 3

其中,表3中的Funcl 3(复杂因子函数)为对主叫号码归属地为A地、被叫号码归属地为B地的语音通信业务(语音呼叫)进行计费所要使用的数学函数,Funcl 4(复杂因子函数)为对主叫号码归属地为A地、被叫号码归属地为C地的语音通信业务进行计费所要使用的数学函数。Wherein, Funcl 3 (complex factor function) in table 3 is the mathematical function to be used for charging the voice communication service (voice call) that the calling number belongs to A place and the called number belongs to B place, Funcl 4 (complex factor function) is a mathematical function to be used for charging the voice communication service where the calling number belongs to place A and the called number belongs to place C.

例如,假设主叫号码归属地为A地、被叫号码归属地为B地的语音通信业务(语音呼叫)的资费为0.03元/分钟,此时,Funcl 3=0.03×t,t为语音通信业务的通话时长。For example, assuming that the calling number belongs to A place and the called number belongs to B place, the voice communication service (voice call) charge is 0.03 yuan/minute, at this time, Funcl 3=0.03×t, t is the voice communication Business call duration.

如上所示,上述复杂计费因子(如时间方案)经过函数运算后的运算结果可以影响计费结果。As shown above, the calculation result of the complex charging factors (such as the time plan) after the function calculation can affect the charging result.

其中,阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为精确计费因子的计费因子。本发明实施例中的阶梯计费因子可以包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。其中,阶梯资费标识用于区别标识阶梯计费因子中各个阶段的资费信息。Among them, the step billing factor is a billing factor whose value range is not enumerable, regularized by a mathematical formula, and can be converted into an accurate billing factor after mapping. The step charging factor in the embodiment of the present invention may include: a step factor identifier, a step factor function, a step tariff identifier and a step factor parameter. Wherein, the tiered tariff identifier is used to distinguish and identify the tariff information of each stage in the tiered charging factor.

示例性的,以语音通信业务的分档资费(阶梯因子标识)方案为例,假设语音通信业务的资费可以分为三档:通话时长(0,3]分钟,其资费为0.1元/分钟;通话时长(3,5]分钟,其资费为0.08元/分钟;通话时长(5,∞)分钟,其资费为0.05元/分钟。Exemplarily, taking the graded tariff (step factor identification) scheme of the voice communication service as an example, it is assumed that the tariff of the voice communication service can be divided into three grades: the call duration is (0, 3] minutes, and the tariff is 0.1 yuan/minute; The call duration is (3, 5] minutes, and the tariff is 0.08 yuan/minute; the call duration is (5, ∞) minutes, and the tariff is 0.05 yuan/minute.

表4Table 4

基于上述实例,假设上述一A地用户S1为电信用户,B地的用户S2为移动用户,A地用户S1在早8点向B地的用户S2发起语音通信业务,且本次语音通信业务持续7分钟(即A地用户S1与B地的用户S2通话时长7分钟)。Based on the above example, assume that the user S1 at A is a telecom user, and the user S2 at B is a mobile user. The user S1 at A initiates a voice communication service to user S2 at B at 8:00 a.m., and the voice communication service continues. 7 minutes (that is, the call between user S1 at A and user S2 at B lasts 7 minutes).

业务计费装置可以从用户S1为当前业务(A地用户S1与B地的用户S2之间持续7分钟的语音通信业务)订购的资费策略(P4)-(P7)中,确定出当前业务的计费因子包括:语音业务、长途、网外、资费组合(P4+P5+P6+P7)、定向呼叫和分档资费。The service charging device can determine the current service from the tariff policy (P4)-(P7) ordered by the user S1 for the current service (the voice communication service between the user S1 at A and the user S2 at B for 7 minutes) Billing factors include: voice service, long-distance, off-network, tariff combination (P4+P5+P6+P7), directional call and sub-file tariff.

S104、业务计费装置采用当前业务的计费因子匹配预先存储的历史计费结果,历史计费结果中包含计费因子以及与计费因子存在对应关系的计费结果。S104. The service charging device uses the charging factor of the current service to match the pre-stored historical charging result, and the historical charging result includes the charging factor and the charging result corresponding to the charging factor.

其中,历史计费结果中包含计费因子以及与计费因子存在对应关系的计费结果。Wherein, the historical charging results include charging factors and charging results corresponding to the charging factors.

业务计费装置采用当前业务的计费因子匹配预先存储的历史计费结果的方法可以包括:业务计费装置从预先存储的历史计费结果包含的计费因子中查找与当前业务的计费因子匹配(相同)的计费因子;若预先存储的历史计费结果中存在与当前业务的计费因子匹配的计费因子(简称匹配计费因子),那么则认为与该匹配计费因子存在对应关系的计费结果与当前业务的计费因子匹配。The method for the service charging device to use the charging factor of the current service to match the pre-stored historical charging results may include: the service charging device searches for the charging factor of the current service from the charging factors contained in the pre-stored historical charging results. Matching (same) billing factor; if there is a billing factor that matches the billing factor of the current service in the pre-stored historical billing results (referred to as matching billing factor), then it is considered that there is a correspondence with the matching billing factor The charging result of the relationship matches the charging factor of the current service.

S105、若存在与当前业务的计费因子匹配的历史计费结果,业务计费装置则采用与当前业务的计费因子匹配的历史计费结果,根据当前业务的业务使用信息为当前业务计费,以获得当前业务的计费结果。S105. If there is a historical charging result matching the charging factor of the current service, the service charging device adopts the historical charging result matching the charging factor of the current service, and charges the current service according to the service usage information of the current service to obtain the charging result of the current service.

本发明实施例提供的业务计费方法,可以从用户为当前业务订购的资费策略中,确定出当前业务的计费因子,然后采用当前业务的计费因子匹配历史计费结果,存在与当前业务的计费因子匹配的历史计费结果,则可以直接复用该历史计费结果对当前业务进行计费,而不是逐个、循序渐进的采用每一个资费策略分别进行计费。复用历史计费结果对当前业务进行计费可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。The service charging method provided by the embodiment of the present invention can determine the charging factor of the current service from the charging policy ordered by the user for the current service, and then use the charging factor of the current service to match the historical charging results. If the historical billing result matched by the billing factor is used, the historical billing result can be directly reused to bill the current service, instead of using each tariff strategy one by one and step by step for billing. Multiplexing the historical charging results to charge the current service can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

优选的,为了加快业务计费装置采用当前业务的计费因子匹配预先存储的历史计费结果的匹配速度,提高匹配效率,本发明实施例中业务计费装置可以采用序列化算法对上述计费因子(包括精确计费因子、复杂计费因子和阶梯计费因子)进行序列化,为每一个计费因子分配一个可以唯一标识该计费因子的序列化特征值。Preferably, in order to speed up the matching speed of the service charging device using the charging factor of the current service to match the pre-stored historical charging results and improve the matching efficiency, the service charging device in the embodiment of the present invention can use a serialization algorithm to perform the above-mentioned charging Factors (including precise billing factors, complex billing factors and step billing factors) are serialized, and each billing factor is assigned a serialized characteristic value that can uniquely identify the billing factor.

对应的,上述历史计费结果中包含计费因子以及与该计费因子存在对应关系的计费结果,具体可以为:历史计费结果中包含待匹配序列化特征值以及与该待匹配序列化特征值存在对应关系的计费结果,一个待匹配序列化特征值用于唯一标识一个计费因子。Correspondingly, the above-mentioned historical billing results include billing factors and billing results corresponding to the billing factors. Specifically, the historical billing results include serialized feature values to be matched and serialized There is a corresponding billing result for the feature value, and a serialized feature value to be matched is used to uniquely identify a billing factor.

此时,S104可以替换为S104′:At this point, S104 can be replaced by S104':

S104′业务计费装置采用当前业务的计费因子对应的序列化特征值匹配预先存储的待匹配序列化特征值。S104' The service charging device uses the serialized characteristic value corresponding to the charging factor of the current service to match the pre-stored serialized characteristic value to be matched.

其中,当当前业务的计费因子对应的序列化特征值等于一待匹配序列化特征值时,当前业务的计费因子与该待匹配序列化特征值对应的计费结果匹配。Wherein, when the serialized characteristic value corresponding to the charging factor of the current service is equal to a serialized characteristic value to be matched, the charging factor of the current service matches the charging result corresponding to the serialized characteristic value to be matched.

进一步的,如图4所示,本发明实施例的方法还可以包括S106:Further, as shown in FIG. 4, the method in this embodiment of the present invention may also include S106:

S106、若不存在与当前业务的计费因子匹配的历史计费结果,业务计费装置则分别采用用户为所述当前业务订购的资费策略中的每一个资费策略,为当前业务计费,以获得当前业务的计费结果。S106. If there is no historical charging result matching the charging factor of the current service, the service charging device adopts each of the charging strategies ordered by the user for the current service to charge the current service, and Obtain the billing result of the current business.

需要说明的是,业务计费装置则分别采用用户为当前业务订购的资费策略中的每一个资费策略,为当前业务计费,以获得当前业务的计费结果的方法与现有技术中分别采用用户为所述当前业务订购的资费策略中的每一个资费策略,为当前业务计费的方法类似,本实施例这里不再赘述。It should be noted that the service charging device adopts each tariff strategy in the tariff strategy ordered by the user for the current service to charge the current service, and the method for obtaining the charging result of the current service is the same as that used in the prior art. For each of the tariff policies subscribed by the user for the current service, the charging method for the current service is similar, and will not be repeated here in this embodiment.

本发明实施例提供的业务计费方法,当不存在与当前业务的计费因子匹配的历史计费结果时,则可以分别采用用户为所述当前业务订购的资费策略中的每一个资费策略,为当前业务计费。如此,无论是否存在与当前业务的计费因子匹配的历史计费结果,通过本方案均可以为当前业务计费,获得当前业务的计费结果。In the service charging method provided by the embodiment of the present invention, when there is no historical charging result matching the charging factor of the current service, each of the charging policies subscribed by the user for the current service may be adopted respectively, Bill for current business. In this way, no matter whether there is a historical charging result matching the charging factor of the current service, the current service can be charged through this solution, and the charging result of the current service can be obtained.

进一步的,为了减少下次对类似业务(与上述当前业务相同或者相近的业务)进行计费时的计算量,简化计费过程,如图5所示,在图3所示的S106之后,本发明实施例的方法还可以包括S107:Further, in order to reduce the calculation amount when charging similar services (the same or similar services as the above-mentioned current services) next time, simplify the charging process, as shown in Figure 5, after S106 shown in Figure 3, this The method of the embodiment of the invention may also include S107:

S107、业务计费装置保存当前业务的计费因子与当前业务的计费结果之间的对应关系。S107. The service charging device stores the corresponding relationship between the charging factor of the current service and the charging result of the current service.

可以想到的是,保存当前业务的计费因子与当前业务的计费结果之间的对应关系后,下次对类似业务进行计费时,则可以直接复用本次保存的与当前业务的计费因子存在对应关系的计费结果,则不需要按照第五种可能的实现方式中所述的计费方式对类似业务进行计费,从而可以减少上述类似业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。It is conceivable that after saving the corresponding relationship between the billing factor of the current business and the billing result of the current business, the next time the similar business is billed, the saved calculation of the current business can be directly reused. If there is a charging result corresponding to the fee factor, it is not necessary to charge similar services according to the charging method described in the fifth possible implementation mode, thereby reducing the amount of calculation in the charging process of the above-mentioned similar services, simplifying The billing process can reduce the consumption of system performance.

优选的,为了避免不常用(即使用频率较低)的计费因子以及与其存在对应关系的计费结果对计费系统存储空间的占用,影响系统性能,S106具体可以为S106′:Preferably, in order to avoid infrequently used (i.e. low frequency of use) billing factors and billing results corresponding thereto occupying the storage space of the billing system and affecting system performance, S106 may specifically be S106':

S106′、若当前业务的计费因子的使用频率高于第一频率阈值,业务计费装置则保存当前业务的计费因子与当前业务的计费结果之间的对应关系。S106'. If the usage frequency of the charging factor of the current service is higher than the first frequency threshold, the service charging device stores the corresponding relationship between the charging factor of the current service and the charging result of the current service.

并且,为了进一步避免不常用(即使用频率较低)的计费因子以及与其存在对应关系的计费结果对计费系统存储空间的占用,可选的,本发明实施例的方法还可以包括:若当前业务的计费因子的使用频率低于第二频率阈值,业务计费装置则删除当前业务的计费因子与当前业务的计费结果之间的对应关系。其中,第一频率阈值高于第二频率阈值。And, in order to further avoid the storage space of the charging system occupied by the charging factors that are not commonly used (that is, with low frequency of use) and the charging results corresponding to them, optionally, the method in the embodiment of the present invention may also include: If the usage frequency of the charging factor of the current service is lower than the second frequency threshold, the service charging device deletes the corresponding relationship between the charging factor of the current service and the charging result of the current service. Wherein, the first frequency threshold is higher than the second frequency threshold.

本发明实施例提供一种业务计费方法,可以采用层级式的匹配方式,依次精确计费因子、复杂计费因子(或者精确计费因子、复杂计费因子以及阶梯计费因子)匹配历史计费结果,对当前业务进行计费,如图6或图7所示,该业务计费方法可以包括:The embodiment of the present invention provides a service charging method, which can use a hierarchical matching method to match historical accounting factors with precise charging factors and complex charging factors (or precise charging factors, complex charging factors, and ladder charging factors) sequentially. According to the charging result, the current service is charged, as shown in Figure 6 or Figure 7, the service charging method may include:

S201、业务计费装置获取一用户的当前业务的业务使用信息。S201. The service charging device acquires service usage information of a user's current service.

需要说明的是,业务计费装置获取一用户的当前业务的业务使用信息的具体方法可以参考上述实施例中的相关描述,本发明实施例这里不再赘述。It should be noted that, for a specific method for the service charging apparatus to obtain service usage information of a user's current service, reference may be made to relevant descriptions in the foregoing embodiments, and details are not repeated here in the embodiments of the present invention.

S202、业务计费装置确定用户为当前业务订购的资费策略,并从用户为当前业务订购的资费策略中,确定出当前业务的计费因子。S202. The service charging device determines the charging policy subscribed by the user for the current service, and determines the charging factor of the current service from the charging policy subscribed by the user for the current service.

需要说明的是,业务计费装置确定用户为当前业务订购的资费策略,并从用户为当前业务订购的资费策略中,确定出当前业务的计费因子的具体方法可以参考上述实施例中的相关描述,本发明实施例这里不再赘述。It should be noted that the service charging device determines the charging policy subscribed by the user for the current service, and the specific method of determining the charging factor of the current service from the charging policy subscribed by the user for the current service can refer to the related description, the embodiments of the present invention will not be repeated here.

示例性的,在本发明实施例的一种应用场景中,假设当前业务的计费因子包括:精确计费因子和复杂计费因子,此时业务计费装置可以采用层级式的匹配方式,依次精确计费因子、复杂计费因子匹配预先存储的历史计费结果,以便于在匹配成功后可以直接复用匹配成功的历史计费结果。具体的,如图6所示,本发明实施例的方法还可以包括S203-S206:Exemplarily, in an application scenario of the embodiment of the present invention, it is assumed that the charging factors of the current service include: precise charging factors and complex charging factors, at this time, the service charging device can adopt a hierarchical matching method, and Precise billing factors and complex billing factors match the pre-stored historical billing results, so that the matched historical billing results can be directly reused after the matching is successful. Specifically, as shown in FIG. 6, the method of the embodiment of the present invention may also include S203-S206:

S203、业务计费装置采用精确计费因子匹配第一计费结果,第一计费结果为历史计费结果。S203. The service charging device uses the precise charging factor to match the first charging result, where the first charging result is a historical charging result.

S204、若存在第二计费结果,业务计费装置则采用复杂计费因子匹配第二计费结果,第二计费结果为第一计费结果中与精确计费因子匹配的计费结果。S204. If there is a second charging result, the service charging device uses a complex charging factor to match the second charging result, and the second charging result is a charging result that matches the precise charging factor in the first charging result.

S205、若存在第三计费结果,业务计费装置则采用第三计费结果,根据当前业务的业务使用信息为当前业务计费,第三计费结果为第二计费结果中与复杂计费因子匹配的计费结果,以获得当前业务的计费结果。S205. If there is a third charging result, the service charging device adopts the third charging result, charges the current service according to the service usage information of the current service, and the third charging result is the combination of the second charging result and the complicated calculation result. The charging result matched by the fee factor is used to obtain the charging result of the current service.

需要说明的是,业务计费装置采用精确计费因子匹配第一计费结果,采用复杂计费因子匹配第二计费结果的具体方法可以参考上述采用当前业务的计费因子匹配历史计费结果的方法,本实施例这里不再赘述。It should be noted that the service charging device uses accurate charging factors to match the first charging results, and uses complex charging factors to match the second charging results. The method of this embodiment will not be repeated here.

进一步的,若不存在第二计费结果或者不存在第三计费结果,则继续执行S206:Further, if there is no second charging result or no third charging result, continue to execute S206:

S206、业务计费装置分别采用用户为当前业务订购的资费策略中的每一个资费策略,为当前业务计费,以获得当前业务的计费结果。S206. The service charging device adopts each of the charging policies subscribed by the user for the current service to charge the current service, so as to obtain a charging result of the current service.

优选的,为了加快采用当前业务的计费因子匹配预先存储的历史计费结果的匹配速度,提高匹配效率,本发明实施例中精确计费因子中还可以包含该精确计费因子的序列化特征值,复杂计费因子中还可以包含该复杂计费因子的序列化特征值。Preferably, in order to speed up the matching speed of using the billing factor of the current service to match the pre-stored historical billing results and improve the matching efficiency, the precise billing factor in the embodiment of the present invention may also include the serialization feature of the precise billing factor value, and the complex billing factor can also include the serialized characteristic value of the complex billing factor.

其中,业务计费装置则可以采用当前业务的每一个精确计费因子对应的序列化特征值分别匹配预先存储的待匹配序列化特征值,当当前业务的一个精确计费因子对应的序列化特征值等于一待匹配序列化特征值时,业务计费装置则可以确定该精确计费因子与该待匹配序列化特征值对应的计费结果匹配。同样的,业务计费装置也可以采用当前业务的每一个复杂计费因子对应的序列化特征值分别匹配预先存储的待匹配序列化特征值,当当前业务的一个复杂计费因子对应的序列化特征值等于一待匹配序列化特征值时,业务计费装置则可以确定该复杂计费因子与该待匹配序列化特征值对应的计费结果匹配。Among them, the service charging device can use the serialized characteristic value corresponding to each accurate charging factor of the current service to match the pre-stored serialized characteristic value to be matched respectively, when the serialized characteristic value corresponding to an accurate charging factor of the current service When the value is equal to a serialized characteristic value to be matched, the service charging device may determine that the precise charging factor matches the charging result corresponding to the serialized characteristic value to be matched. Similarly, the service charging device can also use the serialized characteristic value corresponding to each complex charging factor of the current service to match the pre-stored serialized characteristic value to be matched respectively. When the serialized characteristic value corresponding to a complex charging factor of the current service When the characteristic value is equal to a serialized characteristic value to be matched, the service charging device may determine that the complex charging factor matches the charging result corresponding to the serialized characteristic value to be matched.

示例性的,结合表1,如表5所示,为本发明实施例提供的精确计费因子实例,表5所示的精确计费因子中包含可以唯一标识每一个精确计费因子的序列化特征值。Exemplarily, in conjunction with Table 1, as shown in Table 5, it is an example of the precise billing factor provided by the embodiment of the present invention. The precise billing factor shown in Table 5 includes a serialization that can uniquely identify each precise billing factor Eigenvalues.

表5table 5

示例性的,结合表2,如表6所示,为本发明实施例提供的复杂计费因子实例,表6所示的复杂计费因子中包含可以唯一标识每一个复杂计费因子的序列化特征值。Exemplarily, in combination with Table 2, as shown in Table 6, it is an example of a complex billing factor provided by the embodiment of the present invention. The complex billing factor shown in Table 6 includes a serialization that can uniquely identify each complex billing factor Eigenvalues.

表6Table 6

示例性的,结合表3,如表7所示,为本发明实施例提供的复杂计费因子实例,表7所示的复杂计费因子中包含可以唯一标识每一个复杂计费因子的序列化特征值。Exemplarily, in combination with Table 3, as shown in Table 7, it is an example of a complex billing factor provided by the embodiment of the present invention. The complex billing factor shown in Table 7 includes a serialization that can uniquely identify each complex billing factor Eigenvalues.

表7Table 7

其中,本发明实施例中采用序列化算法对计费因子进行序列化,以得到计费因子的序列化特征值的相关方法可以参考现有技术中的详细描述,本实施例这里不再赘述。Wherein, in the embodiment of the present invention, the serialization algorithm is used to serialize the billing factor to obtain the related method of the serialized characteristic value of the billing factor, which can refer to the detailed description in the prior art, and will not be repeated here in this embodiment.

示例性的,假设业务计费装置确定出当前业务的计费因子包括:精确计费因子和复杂计费因子;其中,精确计费因子包括:语音业务、长途、网外和资费组合(P4+P5+P6+P7);复杂计费因子包括:定向呼叫。Exemplarily, it is assumed that the service charging device determines that the charging factors of the current service include: precise charging factors and complex charging factors; wherein, the precise charging factors include: voice service, long distance, off-network and tariff combination (P4+ P5+P6+P7); complex charging factors include: directed calls.

如此,业务计费装置便可以确定当前业务的计费因子中精确计费因子的序列化特征值分别为:Key 11、Key 22、Key 32和Key 42;复杂计费因子的序列化特征值为:Key 53。In this way, the service charging device can determine that the serialized characteristic values of the accurate charging factors in the charging factors of the current service are respectively: Key 11, Key 22, Key 32 and Key 42; the serialized characteristic values of the complex charging factors are : Key 53.

需要强调的是,本发明实施例中,历史计费结果中包含计费因子以及与计费因子存在对应关系的计费结果,具体可以为:历史计费结果中包含待匹配序列化特征值以及与待匹配序列化特征值存在对应关系的计费结果,一个待匹配序列化特征值用于唯一标识一个计费因子。It should be emphasized that, in the embodiment of the present invention, the historical billing results include billing factors and billing results corresponding to the billing factors. Specifically, the historical billing results include serialized feature values to be matched and The billing result that has a corresponding relationship with the serialized feature value to be matched, and a serialized feature value to be matched is used to uniquely identify a billing factor.

可以想到的是,本发明实施例中,历史计费结果中包含待匹配序列化特征值采用与上述同样的序列化算法对对应的计费因子进行序列化得到的。It is conceivable that, in the embodiment of the present invention, the historical billing result includes serialized characteristic values to be matched, which are obtained by serializing the corresponding billing factors using the same serialization algorithm as above.

示例性的,本发明实施例中可以采用表格方式给出本发明实施中的历史计费结果实例,如表8所示,为本发明实施例提供的一种历史计费结果实例:Exemplarily, in the embodiment of the present invention, the example of the historical billing result in the implementation of the present invention can be given in the form of a table, as shown in Table 8, which is an example of the historical billing result provided by the embodiment of the present invention:

表8Table 8

结合上述实例,若业务计费装置确定当前业务的计费因子中精确计费因子的序列化特征值分别为:Key 11、Key 22、Key 32和Key 42;复杂计费因子的序列化特征值为:Key 53;那么业务计费装置从历史计费结果中匹配得到的第三计费结果中则可以包含如表8所示的计费结果1(对应于Key 11)、计费结果5(对应于Key 22)、计费结果7(对应于Key 32)、计费结果9(对应于Key 42)和计费结果12(对应于Key 53)。In conjunction with the above example, if the service charging device determines that the serialization eigenvalues of the accurate charging factors in the charging factors of the current service are respectively: Key 11, Key 22, Key 32 and Key 42; the serialization eigenvalues of the complex charging factors is: Key 53; then the third charging result that the service charging device matches from the historical charging results can include charging result 1 (corresponding to Key 11), charging result 5 ( corresponding to Key 22), accounting result 7 (corresponding to Key 32), accounting result 9 (corresponding to Key 42), and accounting result 12 (corresponding to Key 53).

可以想到的是,业务计费装置可以在匹配得到上述计费结果1、计费结果5、计费结果7、计费结果9和计费结果12后,便可以根据当前业务的业务使用信息直接复用匹配得到的计费结果,对当前业务进行计费。It is conceivable that, after matching and obtaining the above-mentioned charging result 1, charging result 5, charging result 7, charging result 9 and charging result 12, the service charging device can directly Multiplex the charging result obtained through matching to charge the current service.

本发明实施例中,由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高。In the embodiment of the present invention, since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result. Therefore, it can be seen that the accurate billing factor is easier to match the historical billing results than the complex billing factor, that is, the precise billing factor is more likely to directly reuse the historical billing results.

如此,若当前业务的计费因子包括精确计费因子和复杂计费因子,优先采用精确计费因子匹配历史计费结果(第一计费结果),然后再采用复杂计费因子匹配与精确计费因子匹配的历史计费结果(第二计费结果),则可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, if the billing factors of the current service include precise billing factors and complex billing factors, the precise billing factor is first used to match the historical billing result (the first billing result), and then the complex billing factor is used to match the precise billing factor. The historical charging result (second charging result) matched by the fee factor can improve the possibility of successful matching and the possibility of reusing the historical charging result.

进一步的,在本发明实施例的另一种应用场景中,假设当前业务的计费因子包括:精确计费因子、复杂计费因子和阶梯计费因子,此时业务计费装置可以采用层级式的匹配方式,依次精确计费因子、复杂计费因子以及阶梯计费因子匹配预先存储的历史计费结果,以便于在匹配成功后可以直接复用匹配成功的历史计费结果。具体的,如图7所示,本发明实施例的方法还可以包括S203、S204、S206-S208:Further, in another application scenario of the embodiment of the present invention, it is assumed that the billing factors of the current service include: precise billing factors, complex billing factors, and step billing factors, at this time, the service billing device can adopt a hierarchical According to the matching method, accurate billing factor, complex billing factor, and step billing factor are used to match the pre-stored historical billing results, so that the historical billing results that have been successfully matched can be directly reused after the matching is successful. Specifically, as shown in FIG. 7, the method of the embodiment of the present invention may also include S203, S204, S206-S208:

S207、若存在第三计费结果,则采用阶梯计费因子匹配第三计费结果,第三计费结果为第二计费结果中与复杂计费因子匹配的计费结果。S207. If there is a third charging result, match the third charging result with a step charging factor, where the third charging result is a charging result matching the complex charging factor in the second charging result.

示例性的,结合表4,如表9所示,为本发明实施例提供的阶梯计费因子实例,表9所示的复杂计费因子中包含可以唯一标识每一个阶梯计费因子的序列化特征值。Exemplarily, in conjunction with Table 4, as shown in Table 9, it is an example of the step billing factor provided by the embodiment of the present invention. The complex billing factor shown in Table 9 contains a serialization that can uniquely identify each step billing factor Eigenvalues.

表9Table 9

示例性的,假设业务计费装置确定出当前业务的计费因子包括:精确计费因子、复杂计费因子和阶梯计费因子;其中,精确计费因子包括:语音业务、长途、网外和资费组合(P4+P5+P6+P7);复杂计费因子包括:定向呼叫;阶梯计费因子包括:分档资费。Exemplarily, it is assumed that the service charging device determines that the charging factors of the current service include: precise charging factors, complex charging factors and stepped charging factors; wherein, the precise charging factors include: voice services, long distance, off-network and Tariff combination (P4+P5+P6+P7); complex billing factors include: directed call; step billing factors include: tiered tariffs.

如此,业务计费装置便可以确定当前业务的计费因子中精确计费因子的序列化特征值分别为:Key 11、Key 22、Key 32和Key 4n;复杂计费因子的序列化特征值分别为:Key 53;阶梯计费因子的序列化特征值分别为:Key 71。In this way, the service charging device can determine that the serialized characteristic values of the accurate charging factors in the charging factors of the current service are respectively: Key 11, Key 22, Key 32 and Key 4n; the serialized characteristic values of the complex charging factors are respectively It is: Key 53; the serialized characteristic values of the step billing factors are: Key 71.

示例性的,如表10所示,为本发明实施例提供的一种历史计费结果实例:Exemplarily, as shown in Table 10, it is an example of a historical charging result provided by the embodiment of the present invention:

表10Table 10

S208、若存在第四计费结果,则采用第四计费结果,根据当前业务的业务使用信息为当前业务计费,第四计费结果为第三计费结果中与阶梯计费因子匹配的计费结果,以获得当前业务的计费结果。S208. If there is a fourth charging result, use the fourth charging result, and charge the current service according to the service usage information of the current service, and the fourth charging result is the third charging result that matches the step charging factor Billing result to obtain the billing result of the current service.

进一步的,若不存在第四计费结果,则可以继续执行S206。Further, if there is no fourth charging result, S206 may continue to be executed.

结合上述实例,若业务计费装置确定当前业务的计费因子的序列化特征值分别为:Key 11、Key 22、Key 32和Key 42、Key 53和Key 71;那么业务计费装置从历史计费结果中匹配得到的第四计费结果中则可以包含如表8所示的计费结果1(对应于Key 11)、计费结果5(对应于Key 22)、计费结果7(对应于Key 32)、计费结果9(对应于Key 42)、计费结果12(对应于Key 53)和计费结果14(对应于Key 71)。In conjunction with the foregoing examples, if the service charging device determines that the serialization characteristic value of the charging factor of the current service is respectively: Key 11, Key 22, Key 32 and Key 42, Key 53 and Key 71; The fourth charging result matched in the charging result may include charging result 1 (corresponding to Key 11), charging result 5 (corresponding to Key 22) and charging result 7 (corresponding to Key 22) as shown in Table 8. Key 32), accounting result 9 (corresponding to Key 42), accounting result 12 (corresponding to Key 53), and accounting result 14 (corresponding to Key 71).

可以想到的是,业务计费装置可以在匹配得到上述计费结果1、计费结果5、计费结果7、计费结果9、计费结果12和计费结果14后,便可以根据当前业务的业务使用信息直接复用匹配得到的计费结果,对当前业务进行计费。It is conceivable that the service charging device can obtain the above charging result 1, charging result 5, charging result 7, charging result 9, charging result 12 and charging result 14 according to the current service The billing result obtained through direct multiplexing and matching of the service usage information is charged for the current service.

进一步的,本发明实施例中的历史计费结果中包含的与计费因子存在对应关系的计费结果(如表9所示的计费结果1-14)可以包含:历史计费公式和业务计费结果中的至少一项。Further, the charging results (charging results 1-14 shown in Table 9) included in the historical charging results in the embodiment of the present invention and have a corresponding relationship with the charging factors may include: historical charging formulas and service At least one of the billing results.

其中,历史计费公式为在历史计费过程中归纳总结得到的与计费因子对应的用于计费计算的数学公式。Wherein, the historical charging formula is a mathematical formula used for charging calculation and corresponding to the charging factor obtained through induction and summary in the historical charging process.

示例性的,以上述阶梯计费因子的历史计费结果为例,基于表9所示的分档资费的计费结果,在表9所示的分档资费中,语音资费按照时间阶梯可以分为三档:通话时长(0,3]分钟,其资费为0.1元/分钟;通话时长(3,5]分钟,其资费为0.08元/分钟;通话时长(5,∞)分钟,其资费为0.05元/分钟。Exemplarily, taking the historical billing results of the above step billing factors as an example, based on the billing results of the graded tariffs shown in Table 9, in the graded tariffs shown in Table 9, the voice tariff can be divided according to the time ladder There are three levels: call duration (0, 3] minutes, the tariff is 0.1 yuan/minute; call duration (3, 5] minutes, the tariff is 0.08 yuan/minute; call duration (5, ∞) minutes, the tariff is 0.05 yuan/minute.

由于在大多数语音通话场景中,其通话时长均在5分钟以上,因此,为了减少语音通信业务计费过程中的计算量,提高计费效率,上述分档资费的历史计费结果具体可以包含如表11所示的与计费因子对应的用于计费计算的数学公式:Since in most voice call scenarios, the call duration is more than 5 minutes, in order to reduce the amount of calculation in the billing process of voice communication services and improve billing efficiency, the historical billing results of the above-mentioned tiered tariffs can specifically include Mathematical formulas for billing calculations corresponding to billing factors as shown in Table 11:

表11Table 11

业务计费结果可以为在历史计费过程中归纳总结得到的与计费因子对应的计费金额。例如,若当前业务为数据流量包业务,那么此时该数据流量包业务的计费因子所对应的计费结果则可以为办理该数据流量包所要支付的计费金额(如10M数据流量包的计费金额为3元)。The service charging result may be the charging amount corresponding to the charging factor summed up in the historical charging process. For example, if the current service is a data flow packet service, then the billing result corresponding to the billing factor of the data flow packet service can be the billing amount to be paid for handling the data flow packet (such as the 10M data flow packet The billing amount is 3 yuan).

优选的,本发明实施例中还可以采用如图8所示的树形因子结构,进行当前业务的计费因子与历史计费结果的匹配。如图8所示,业务计费装置可以依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果。Preferably, in the embodiment of the present invention, the tree factor structure as shown in FIG. 8 can also be used to match the charging factor of the current service with the historical charging result. As shown in FIG. 8 , the service charging device may sequentially use precise charging factors, complex charging factors, and stepped charging factors to match historical charging results.

可以想到的是,由于阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子;因此可知复杂计费因子相较于阶梯计费因子,更容易匹配历史计费结果,即复杂计费因子复用历史计费结果的可能性高于阶梯计费因子复用历史计费结果的可能性。It is conceivable that since the step billing factor is a billing factor whose value range is not enumerable, it can be converted into the precise billing factor after being regulated by a mathematical formula, and mapped; It is easier to match historical billing results with the cost factor, that is, the possibility of reusing historical billing results with complex billing factors is higher than that of ladder billing factors.

如此,若当前业务的计费因子包括精确计费因子、复杂计费因子和阶梯计费因子,依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果,可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, if the billing factors of the current service include precise billing factors, complex billing factors, and step billing factors, the precise billing factors, complex billing factors, and step billing factors are used in turn to match the historical billing results, which can improve the matching Likelihood of success and the possibility of reusing historical billing results.

本发明实施例提供的业务计费方法,可以从用户为当前业务订购的资费策略中,确定出当前业务的计费因子,然后采用当前业务的计费因子匹配历史计费结果,存在与当前业务的计费因子匹配的历史计费结果,则可以直接复用该历史计费结果对当前业务进行计费,而不是逐个、循序渐进的采用每一个资费策略分别进行计费。复用历史计费结果对当前业务进行计费可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。The service charging method provided by the embodiment of the present invention can determine the charging factor of the current service from the charging policy ordered by the user for the current service, and then use the charging factor of the current service to match the historical charging results. If the historical billing result matched by the billing factor is used, the historical billing result can be directly reused to bill the current service, instead of using each tariff strategy one by one and step by step for billing. Multiplexing the historical charging results to charge the current service can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

并且,由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子,阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高;复杂计费因子相较于阶梯计费因子,更容易匹配历史计费结果,即复杂计费因子复用历史计费结果的可能性高于阶梯计费因子复用历史计费结果的可能性。Moreover, since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, and the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result, the ladder The billing factor is a billing factor whose value range is not enumerable, regularized by mathematical formula, and can be converted into the precise billing factor after mapping; therefore, it can be seen that the precise billing factor is easier to match the history than the complex billing factor Billing results, that is, accurate billing factors are more likely to directly reuse historical billing results; complex billing factors are easier to match historical billing results than ladder billing factors, that is, complex billing factors reuse history The possibility of billing results is higher than the possibility of multiplexing historical billing results by step billing factors.

如此,当当前业务的计费因子包括精确计费因子、复杂计费因子和阶梯计费因子时,依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果,可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, when the billing factors of the current service include precise billing factors, complex billing factors, and step billing factors, matching historical billing results with precise billing factors, complex billing factors, and step billing factors can improve The probability of successful matching and the possibility of reusing historical billing results.

本发明实施例提供一种业务计费装置,所述业务计费装置用于执行上述实施例提供的业务计费方法。所述业务计费装置可以包括上述实施例提供的业务计费方法相应步骤所对应的模块。示例的,如图9所示,所述业务计费装置可以包括:获取单元21、确定单元22、匹配单元23和计费单元24。An embodiment of the present invention provides a service charging device, and the service charging device is used to execute the service charging method provided in the above embodiments. The service charging device may include modules corresponding to corresponding steps in the service charging method provided in the above embodiments. Exemplarily, as shown in FIG. 9 , the service charging apparatus may include: an acquiring unit 21 , a determining unit 22 , a matching unit 23 and a charging unit 24 .

获取单元21,用于获取一用户的当前业务的业务使用信息。The obtaining unit 21 is configured to obtain service usage information of a user's current service.

确定单元22,用于确定所述用户为所述当前业务订购的资费策略,并从所述用户为所述当前业务订购的资费策略中,确定出所述当前业务的计费因子。The determination unit 22 is configured to determine the tariff policy subscribed by the user for the current service, and determine the billing factor of the current service from the tariff policy subscribed by the user for the current service.

匹配单元23,用于采用所述确定单元22确定的所述当前业务的计费因子匹配预先存储的历史计费结果,所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果。A matching unit 23, configured to use the charging factor of the current service determined by the determining unit 22 to match a pre-stored historical charging result, where the historical charging result includes a charging factor and exists with the charging factor The billing result of the corresponding relationship.

计费单元24,用于若所述匹配单元23确定存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述获取单元21获取的所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果。The charging unit 24 is configured to use the historical charging result matching the charging factor of the current service if the matching unit 23 determines that there is a historical charging result matching the charging factor of the current service, according to The service usage information of the current service acquired by the acquiring unit 21 is charged for the current service, so as to obtain the charging result of the current service.

进一步的,所述当前业务的计费因子包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项。Further, the charging factor of the current service includes: at least one of a precise charging factor, a complex charging factor and a stepped charging factor.

其中,所述精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子;所述复杂计费因子为经过函数运算后的运算结果影响计费结果的计费因子;所述阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子。Wherein, the precise billing factor is a billing factor whose value range is limited and whose direct value affects the billing result; the complex billing factor is a billing factor whose calculation result after the function operation affects the billing result ; The step billing factor is a billing factor whose value range is non-enumerable, regularized by a mathematical formula, and can be converted into the precise billing factor after mapping.

进一步的,所述精确计费因子包括:精确因子标识和精确因子取值;所述复杂计费因子包括:复杂因子标识、复杂因子函数和复杂因子参数;所述阶梯计费因子包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。Further, the precise charging factor includes: precise factor identification and precise factor value; the complex charging factor includes: complex factor identification, complex factor function and complex factor parameters; the step charging factor includes: step factor ID, Step Factor Function, Step Tariff ID, and Step Factor Parameters.

进一步的,所述历史计费结果中包含的与所述计费因子存在对应关系的计费结果包括:历史计费公式和业务计费结果中的至少一项。Further, the charging results included in the historical charging results and corresponding to the charging factors include: at least one of historical charging formulas and service charging results.

所述历史计费公式为在历史计费过程中归纳总结得到的与所述计费因子对应的用于计费计算的数学公式;所述业务计费结果为在历史计费过程中归纳总结得到的与所述计费因子对应的计费金额。The historical charging formula is a mathematical formula for charging calculation corresponding to the charging factor obtained by summarizing and summarizing in the historical charging process; the service charging result is obtained by summarizing and summarizing in the historical charging process The billing amount corresponding to the billing factor.

可选的,在本发明实施例的一种应用场景中,所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子。Optionally, in an application scenario of the embodiment of the present invention, the charging factor of the current service includes: the precise charging factor and the complex charging factor.

在这种应用场景中,所述匹配单元23,具体用于:In this application scenario, the matching unit 23 is specifically used for:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果。If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor Billing result.

所述计费单元24,具体用于若所述匹配单元23确定存在第三计费结果,则采用所述第三计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果,以获得所述当前业务的计费结果。The charging unit 24 is specifically configured to use the third charging result if the matching unit 23 determines that there is a third charging result, and charge the current service according to the service usage information of the current service , the third charging result is the charging result matching the complex charging factor in the second charging result, so as to obtain the charging result of the current service.

优选的,在本发明实施例的另一种应用场景中,所述当前业务的计费因子包括:所述精确计费因子、所述复杂计费因子和所述阶梯计费因子。Preferably, in another application scenario of the embodiment of the present invention, the billing factors of the current service include: the precise billing factor, the complex billing factor, and the stepped billing factor.

在这种应用场景中,所述匹配单元23,具体用于:In this application scenario, the matching unit 23 is specifically used for:

采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result;

若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result;

若存在第三计费结果,则采用所述阶梯计费因子匹配所述第三计费结果,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果。If there is a third charging result, matching the third charging result with the stepped charging factor, where the third charging result is the second charging result that matches the complex charging factor Billing result.

所述计费单元24,具体用于若所述匹配单元23确定存在第四计费结果,则采用所述第四计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第四计费结果为所述第三计费结果中与所述阶梯计费因子匹配的计费结果,以获得所述当前业务的计费结果。The charging unit 24 is specifically configured to use the fourth charging result if the matching unit 23 determines that there is a fourth charging result, and charge the current service according to the service usage information of the current service , the fourth charging result is a charging result matching the step charging factor in the third charging result, so as to obtain the charging result of the current service.

优选的,所述当前业务的计费因子中包含所述当前业务的计费因子对应的序列化特征值,该序列化特征值用于唯一标识该计费因子。Preferably, the charging factor of the current service includes a serialized characteristic value corresponding to the charging factor of the current service, and the serialized characteristic value is used to uniquely identify the charging factor.

所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果,具体为:所述历史计费结果中包含待匹配序列化特征值以及与所述待匹配序列化特征值存在对应关系的计费结果,一个所述待匹配序列化特征值用于唯一标识一个计费因子。The historical billing results include billing factors and billing results corresponding to the billing factors, specifically: the historical billing results include the serialized feature values to be matched and the There is a charging result corresponding to the serialized characteristic value, and one serialized characteristic value to be matched is used to uniquely identify a charging factor.

进一步的,所述匹配单元23,具体用于采用所述当前业务的计费因子对应的序列化特征值匹配预先存储的待匹配序列化特征值。Further, the matching unit 23 is specifically configured to use the serialized characteristic value corresponding to the charging factor of the current service to match the pre-stored serialized characteristic value to be matched.

其中,当所述当前业务的计费因子对应的序列化特征值等于一待匹配序列化特征值时,所述当前业务的计费因子与该待匹配序列化特征值对应的计费结果匹配。Wherein, when the serialized characteristic value corresponding to the charging factor of the current service is equal to a serialized characteristic value to be matched, the charging factor of the current service matches the charging result corresponding to the serialized characteristic value to be matched.

进一步的,所述计费单元24,还用于若所述匹配单元23确定不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果。Further, the charging unit 24 is further configured to use the user to subscribe for the current service if the matching unit 23 determines that there is no historical charging result matching the charging factor of the current service. Each tariff policy in the tariff policy is charged for the current service, so as to obtain the charging result of the current service.

进一步的,如图10所示,所述业务计费装置,还可以包括:保存单元25。Further, as shown in FIG. 10 , the service charging apparatus may further include: a saving unit 25 .

保存单元25,用于在所述计费单元24分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果之后,保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。The storage unit 25 is configured to use each of the tariff policies subscribed by the user for the current service in the charging unit 24 to charge the current service, so as to obtain the charging policy for the current service. After the charging result is obtained, the corresponding relationship between the charging factor of the current service and the charging result of the current service is saved.

优选的,所述保存单元25,具体用于若所述当前业务的计费因子的使用频率高于第一频率阈值,则保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。Preferably, the saving unit 25 is specifically configured to save the charging factor of the current service and the charging result of the current service if the usage frequency of the charging factor of the current service is higher than a first frequency threshold Correspondence between.

进一步的,所述业务计费装置,还可以包括:删除单元。Further, the service charging device may further include: a deleting unit.

删除单元,用于若所述当前业务的计费因子的使用频率低于第二频率阈值,则删除所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。A deleting unit, configured to delete the correspondence between the charging factor of the current service and the charging result of the current service if the usage frequency of the charging factor of the current service is lower than a second frequency threshold.

需要说明的是,本实施例提供的业务计费装置的详细描述可以参考本发明方法实施例中的相关内容,本实施例这里不再赘述。It should be noted that, for the detailed description of the service charging device provided in this embodiment, reference may be made to relevant content in the method embodiments of the present invention, and details are not repeated here in this embodiment.

本发明实施例提供的业务计费装置,可以从用户为当前业务订购的资费策略中,确定出当前业务的计费因子,然后采用当前业务的计费因子匹配历史计费结果,存在与当前业务的计费因子匹配的历史计费结果,则可以直接复用该历史计费结果对当前业务进行计费,而不是逐个、循序渐进的采用每一个资费策略分别进行计费。复用历史计费结果对当前业务进行计费可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。The service charging device provided by the embodiment of the present invention can determine the charging factor of the current service from the charging policy ordered by the user for the current service, and then use the charging factor of the current service to match the historical charging results. If the historical billing result matched by the billing factor is used, the historical billing result can be directly reused to bill the current service, instead of using each tariff strategy one by one and step by step for billing. Multiplexing the historical charging results to charge the current service can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

并且,由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子,阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高;复杂计费因子相较于阶梯计费因子,更容易匹配历史计费结果,即复杂计费因子复用历史计费结果的可能性高于阶梯计费因子复用历史计费结果的可能性。Moreover, since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, and the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result, the ladder The billing factor is a billing factor whose value range is not enumerable, regularized by mathematical formula, and can be converted into the precise billing factor after mapping; therefore, it can be seen that the precise billing factor is easier to match the history than the complex billing factor Billing results, that is, accurate billing factors are more likely to directly reuse historical billing results; complex billing factors are easier to match historical billing results than ladder billing factors, that is, complex billing factors reuse history The possibility of billing results is higher than the possibility of multiplexing historical billing results by step billing factors.

如此,当当前业务的计费因子包括精确计费因子、复杂计费因子和阶梯计费因子时,依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果,可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, when the billing factors of the current service include precise billing factors, complex billing factors, and step billing factors, matching historical billing results with precise billing factors, complex billing factors, and step billing factors can improve The probability of successful matching and the possibility of reusing historical billing results.

如图11所示,本发明实施例提供一种业务计费装置,所述业务计费装置包括:As shown in Figure 11, an embodiment of the present invention provides a service charging device, the service charging device includes:

一个或多个处理器30、存储器31、总线系统32、收发器33以及一个或多个应用程序,所述一个或多个处理器、所述存储器31和所述收发器33通过所述总线系统32相连。One or more processors 30, memory 31, bus system 32, transceiver 33 and one or more application programs, said one or more processors, said memory 31 and said transceiver 33 are connected via said bus system 32 connected.

所述一个或多个应用程序存储在所述存储器31中,所述一个或多个应用程序包括指令,当所述业务计费装置的处理器30执行所述指令时,所述业务计费装置执行上述方法实施例中所述的业务计费方法。具体的业务计费方法可以参见上述方法实施例中的相关描述,此处不再赘述。The one or more application programs are stored in the memory 31, the one or more application programs include instructions, and when the processor 30 of the service charging device executes the instructions, the service charging device Execute the service charging method described in the above method embodiment. For a specific service charging method, reference may be made to relevant descriptions in the foregoing method embodiments, and details are not repeated here.

本实施例还提供一种计算机可读存储介质,所述计算机可读存储介质中存储有一个或多个程序,所述一个或多个程序包括指令,当所述业务计费装置的处理器30执行所述指令时,所述业务计费装置执行如图3-图7中任一附图所示的业务计费方法。This embodiment also provides a computer-readable storage medium, wherein one or more programs are stored in the computer-readable storage medium, and the one or more programs include instructions. When the processor 30 of the service charging device When executing the instruction, the service charging device executes the service charging method as shown in any one of Fig. 3-Fig. 7 .

所述一个或多个处理器30可以为中央处理器(英文:central processing unit,缩写:CPU)。所述一个或多个处理器30还可以为其他通用处理器、数字信号处理器(英文:digital signal processing,简称DSP)、专用集成电路(英文:applicationspecific integrated circuit,简称ASIC)、现场可编程门阵列(英文:field-programmablegate array,简称FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。The one or more processors 30 may be a central processing unit (English: central processing unit, abbreviation: CPU). The one or more processors 30 can also be other general-purpose processors, digital signal processors (English: digital signal processing, DSP for short), application specific integrated circuits (English: applicationspecific integrated circuit, ASIC for short), field programmable gates, etc. Array (English: field-programmable gate array, FPGA for short) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor, or the processor may be any conventional processor, or the like.

所述一个或多个处理器30可以为专用处理器,该专用处理器可以包括NFC处理芯片、基带处理芯片、射频处理芯片等中的至少一个。进一步地,该专用处理器还可以包括具有便携式电子设备其他专用处理功能的芯片。The one or more processors 30 may be special-purpose processors, and the special-purpose processors may include at least one of an NFC processing chip, a baseband processing chip, a radio frequency processing chip, and the like. Further, the dedicated processor may also include a chip with other dedicated processing functions of the portable electronic device.

所述存储器31可以包括易失性存储器(英文:volatile memory),例如随机存取存储器(英文:random-access memory,缩写:RAM);所述存储器31也可以包括非易失性存储器(英文:non-volatile memory),例如只读存储器(英文:read-onlymemory,缩写:ROM),快闪存储器(英文:flash memory),硬盘(英文:hard diskdrive,缩写:HDD)或固态硬盘(英文:solid-state drive,缩写:SSD);所述存储器31还可以包括上述种类的存储器的组合。The memory 31 may include a volatile memory (English: volatile memory), such as a random-access memory (English: random-access memory, abbreviated as RAM); the memory 31 may also include a non-volatile memory (English: non-volatile memory), such as read-only memory (English: read-onlymemory, abbreviation: ROM), flash memory (English: flash memory), hard disk (English: hard diskdrive, abbreviation: HDD) or solid state drive (English: solid -state drive, abbreviation: SSD); the storage 31 may also include a combination of the above-mentioned types of storage.

所述总线系统32可以包括数据总线、电源总线、控制总线和信号状态总线等。本实施例中为了清楚说明,在图11中将各种总线示意为总线系统32。The bus system 32 may include a data bus, a power bus, a control bus, a signal status bus, and the like. In this embodiment, for the sake of clarity, various buses are shown as a bus system 32 in FIG. 11 .

所述收发器33具体可以是便携式电子设备上的收发器。该收发器可以为无线收发器。例如,无线收发器可以是便携式电子设备的天线等。所述一个或多个处理器30通过所述收发器33与其他设备或者数据库(例如,用户数据库)之间进行数据的收发。The transceiver 33 may specifically be a transceiver on a portable electronic device. The transceiver may be a wireless transceiver. For example, a wireless transceiver may be an antenna of a portable electronic device or the like. The one or more processors 30 transmit and receive data with other devices or databases (eg, user databases) through the transceiver 33 .

需要说明的是,本实施例提供的业务计费装置的详细描述可以参考本发明方法实施例中的相关内容,本实施例这里不再赘述。It should be noted that, for the detailed description of the service charging device provided in this embodiment, reference may be made to relevant content in the method embodiments of the present invention, and details are not repeated here in this embodiment.

本发明实施例提供的业务计费装置,可以从用户为当前业务订购的资费策略中,确定出当前业务的计费因子,然后采用当前业务的计费因子匹配历史计费结果,存在与当前业务的计费因子匹配的历史计费结果,则可以直接复用该历史计费结果对当前业务进行计费,而不是逐个、循序渐进的采用每一个资费策略分别进行计费。复用历史计费结果对当前业务进行计费可以减少业务计费过程中的计算量,简化计费过程,进而可以降低对系统性能的消耗。The service charging device provided by the embodiment of the present invention can determine the charging factor of the current service from the charging policy ordered by the user for the current service, and then use the charging factor of the current service to match the historical charging results. If the historical billing result matched by the billing factor is used, the historical billing result can be directly reused to bill the current service, instead of using each tariff strategy one by one and step by step for billing. Multiplexing the historical charging results to charge the current service can reduce the calculation amount in the service charging process, simplify the charging process, and further reduce the consumption of system performance.

并且,由于精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子,而复杂计费因子为经过逻辑运算后的运算结果影响计费结果的计费因子,阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子;因此可知精确计费因子相较于复杂计费因子,更容易匹配历史计费结果,即精确计费因子直接复用历史计费结果的可能性更高;复杂计费因子相较于阶梯计费因子,更容易匹配历史计费结果,即复杂计费因子复用历史计费结果的可能性高于阶梯计费因子复用历史计费结果的可能性。Moreover, since the precise billing factor is a billing factor with a limited value range and its direct value affects the billing result, and the complex billing factor is a billing factor whose calculation result after logical operation affects the billing result, the ladder The billing factor is a billing factor whose value range is not enumerable, regularized by mathematical formula, and can be converted into the precise billing factor after mapping; therefore, it can be seen that the precise billing factor is easier to match the history than the complex billing factor Billing results, that is, accurate billing factors are more likely to directly reuse historical billing results; complex billing factors are easier to match historical billing results than ladder billing factors, that is, complex billing factors reuse history The possibility of billing results is higher than the possibility of multiplexing historical billing results by step billing factors.

如此,当当前业务的计费因子包括精确计费因子、复杂计费因子和阶梯计费因子时,依次采用精确计费因子、复杂计费因子以及阶梯计费因子匹配历史计费结果,可以提高匹配成功的可能性以及复用历史计费结果的可能性。In this way, when the billing factors of the current service include precise billing factors, complex billing factors, and step billing factors, matching historical billing results with precise billing factors, complex billing factors, and step billing factors can improve The probability of successful matching and the possibility of reusing historical billing results.

通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本发明可借助软件加必需的通用硬件的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在可读取的存储介质中,如计算机的软盘,硬盘或光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be realized by means of software plus necessary general-purpose hardware, and of course also by hardware, but in many cases the former is a better embodiment . Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product is stored in a readable storage medium, such as a floppy disk of a computer , a hard disk or an optical disk, etc., including several instructions for enabling a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments of the present invention.

本领域普通技术人员将会理解,本发明的各个方面、或各个方面的可能实现方式可以被具体实施为系统、方法或者计算机程序产品。因此,本发明的各方面、或各个方面的可能实现方式可以采用完全硬件实施例、完全软件实施例(包括固件、驻留软件等等),或者组合软件和硬件方面的实施例的形式,在这里都统称为“电路”、“模块”或者“系统”。此外,本发明的各方面、或各个方面的可能实现方式可以采用计算机程序产品的形式,计算机程序产品是指存储在计算机可读介质中的计算机可读程序代码。Those of ordinary skill in the art will understand that various aspects of the present invention, or possible implementations of various aspects, may be embodied as systems, methods or computer program products. Accordingly, aspects of the present invention, or possible implementations of various aspects, may take the form of an entirely hardware embodiment, an entirely software embodiment (including firmware, resident software, etc.), or an embodiment combining software and hardware aspects, described in These are collectively referred to herein as "circuits," "modules," or "systems." In addition, aspects of the present invention, or possible implementations of various aspects, may take the form of computer program products, and computer program products refer to computer-readable program codes stored in computer-readable media.

计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质。计算机可读存储介质包含但不限于电子、磁性、光学、电磁、红外或半导体系统、设备或者装置,或者前述的任意适当组合,如随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或者快闪存储器)、光纤、便携式只读存储器(CD-ROM)。The computer readable medium may be a computer readable signal medium or a computer readable storage medium. Computer-readable storage media include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or devices, or any suitable combination of the foregoing, such as random access memory (RAM), read-only memory (ROM), Erase Programmable Read-Only Memory (EPROM or Flash), Fiber Optic, Portable Read-Only Memory (CD-ROM).

计算机中的处理器读取存储在计算机可读介质中的计算机可读程序代码,使得处理器能够执行在流程图中每个步骤、或各步骤的组合中规定的功能动作;生成实施在框图的每一块、或各块的组合中规定的功能动作的装置。The processor in the computer reads the computer-readable program code stored in the computer-readable medium, so that the processor can execute the functional actions specified in each step in the flow chart, or a combination of steps; A device that performs functional actions specified in each block or a combination of blocks.

计算机可读程序代码可以完全在用户的计算机上执行、部分在用户的计算机上执行、作为单独的软件包、部分在用户的计算机上并且部分在远程计算机上,或者完全在远程计算机或者服务器上执行。也应该注意,在某些替代实施方案中,在流程图中各步骤、或框图中各块所注明的功能可能不按图中注明的顺序发生。例如,依赖于所涉及的功能,接连示出的两个步骤、或两个块实际上可能被大致同时执行,或者这些块有时候可能被以相反顺序执行。The computer readable program code may execute entirely on the user's computer, partly on the user's computer, as a separate software package, partly on the user's computer and partly on a remote computer, or entirely on the remote computer or server . It should also be noted that, in some alternative implementations, the functions noted at the steps in the flowcharts or blocks in the block diagrams may occur out of the order noted in the figures. For example, two steps, or two blocks shown in succession, may in fact be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved.

显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的精神和范围。这样,倘若本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也意图包含这些改动和变型在内。Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and equivalent technologies thereof, the present invention also intends to include these modifications and variations.

Claims (17)

1.一种业务计费方法,其特征在于,包括:1. A service charging method, characterized in that, comprising: 获取一用户的当前业务的业务使用信息;Obtaining service usage information of a user's current service; 确定所述用户为所述当前业务订购的资费策略,并从所述用户为所述当前业务订购的资费策略中,确定出所述当前业务的计费因子;determining the tariff policy ordered by the user for the current service, and determining the billing factor of the current service from the tariff policy subscribed by the user for the current service; 采用所述当前业务的计费因子匹配预先存储的历史计费结果,所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果;Using the charging factor of the current service to match the pre-stored historical charging result, the historical charging result includes the charging factor and the charging result corresponding to the charging factor; 若存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果。If there is a historical charging result that matches the charging factor of the current service, then adopt the historical charging result that matches the charging factor of the current service, and calculate the current service for the current service according to the service usage information of the current service Charging, to obtain the charging result of the current service. 2.根据权利要求1所述的方法,其特征在于,所述当前业务的计费因子包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项;2. The method according to claim 1, wherein the billing factor of the current service comprises: at least one of a precise billing factor, a complex billing factor, and a stepped billing factor; 其中,所述精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子;Wherein, the precise billing factor is a billing factor whose value range is limited and whose value directly affects the billing result; 所述复杂计费因子为经过函数运算后的运算结果影响计费结果的计费因子;The complex billing factor is a billing factor whose calculation result after the function operation affects the billing result; 所述阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子。The step billing factor is a billing factor whose value range cannot be enumerated, is regulated by a mathematical formula, and can be converted into the precise billing factor after mapping. 3.根据权利要求2所述的方法,其特征在于,所述精确计费因子包括:精确因子标识和精确因子取值;3. The method according to claim 2, wherein the precise billing factor comprises: a precise factor identifier and a precise factor value; 所述复杂计费因子包括:复杂因子标识、复杂因子函数和复杂因子参数;The complex charging factors include: complex factor identification, complex factor functions and complex factor parameters; 所述阶梯计费因子包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。The step charging factor includes: a step factor identifier, a step factor function, a step tariff identifier and a step factor parameter. 4.根据权利要求1-3中任一项所述的方法,其特征在于,所述历史计费结果中包含的与所述计费因子存在对应关系的计费结果包括:历史计费公式和业务计费结果中的至少一项;4. The method according to any one of claims 1-3, wherein the charging results included in the historical charging results and corresponding to the charging factors include: historical charging formulas and At least one of the business charging results; 所述历史计费公式为在历史计费过程中归纳总结得到的与所述计费因子对应的用于计费计算的数学公式;The historical billing formula is a mathematical formula for billing calculation corresponding to the billing factor obtained by summarizing the historical billing process; 所述业务计费结果为在历史计费过程中归纳总结得到的与所述计费因子对应的计费金额。The service charging result is the charging amount corresponding to the charging factor summed up in the historical charging process. 5.根据权利要求2或3所述的方法,其特征在于,所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子;5. The method according to claim 2 or 3, wherein the billing factor of the current service comprises: the precise billing factor and the complex billing factor; 所述采用所述当前业务的计费因子匹配预先存储的历史计费结果,包括:The matching of the pre-stored historical charging results using the charging factor of the current service includes: 采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result; 若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result; 所述若存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果,包括:If there is a historical charging result matching the charging factor of the current service, then adopting the historical charging result matching the charging factor of the current service, according to the service usage information of the current service for the Current service charging, to obtain the charging result of the current service, including: 若存在第三计费结果,则采用所述第三计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果,以获得所述当前业务的计费结果。If there is a third charging result, adopt the third charging result, charge the current service according to the service usage information of the current service, and the third charging result is the second charging result The charging result matched with the complex charging factor in order to obtain the charging result of the current service. 6.根据权利要求1-3中任一项所述的方法,其特征在于,所述当前业务的计费因子中包含所述当前业务的计费因子对应的序列化特征值,该序列化特征值用于唯一标识该计费因子;6. The method according to any one of claims 1-3, wherein the charging factor of the current service includes a serialized feature value corresponding to the charging factor of the current service, and the serialized feature The value is used to uniquely identify the charging factor; 所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果,具体为:The historical billing results include billing factors and billing results corresponding to the billing factors, specifically: 所述历史计费结果中包含待匹配序列化特征值以及与所述待匹配序列化特征值存在对应关系的计费结果,一个所述待匹配序列化特征值用于唯一标识一个计费因子。The historical charging results include serialized characteristic values to be matched and charging results corresponding to the serialized characteristic values to be matched, and one serialized characteristic value to be matched is used to uniquely identify a charging factor. 7.根据权利要求1-3中任一项所述的方法,其特征在于,所述方法还包括:7. The method according to any one of claims 1-3, wherein the method further comprises: 若不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果。If there is no historical charging result matching the charging factor of the current service, each of the charging strategies subscribed by the user for the current service is adopted to charge the current service, so that Obtain the charging result of the current service. 8.根据权利要求7所述的方法,其特征在于,在所述若不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果之后,所述方法还包括:8. The method according to claim 7, wherein, if there is no historical charging result matching the charging factor of the current service, the user subscribed for the current service is used respectively. Each tariff strategy in the tariff strategy is charged for the current service, and after obtaining the charging result of the current service, the method further includes: 保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。The corresponding relationship between the charging factor of the current service and the charging result of the current service is stored. 9.一种业务计费装置,其特征在于,包括:9. A service charging device, characterized in that it comprises: 获取单元,用于获取一用户的当前业务的业务使用信息;an acquisition unit, configured to acquire service use information of a user's current service; 确定单元,用于确定所述用户为所述当前业务订购的资费策略,并从所述用户为所述当前业务订购的资费策略中,确定出所述当前业务的计费因子;A determining unit, configured to determine the charging policy subscribed by the user for the current service, and determine the charging factor of the current service from the charging policy subscribed by the user for the current service; 匹配单元,用于采用所述确定单元确定的所述当前业务的计费因子匹配预先存储的历史计费结果,所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果;A matching unit, configured to use the charging factor of the current service determined by the determining unit to match a pre-stored historical charging result, where the historical charging result includes a charging factor and has a corresponding relationship with the charging factor the billing result; 计费单元,用于若所述匹配单元确定存在与所述当前业务的计费因子匹配的历史计费结果,则采用与所述当前业务的计费因子匹配的历史计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,以获得所述当前业务的计费结果。The charging unit is configured to adopt the historical charging result matching the charging factor of the current service if the matching unit determines that there is a historical charging result matching the charging factor of the current service, according to the The service usage information of the current service charges the current service, so as to obtain the charging result of the current service. 10.根据权利要求9所述的装置,其特征在于,所述当前业务的计费因子包括:精确计费因子、复杂计费因子以及阶梯计费因子中的至少一项;10. The device according to claim 9, wherein the billing factor of the current service includes: at least one of a precise billing factor, a complex billing factor, and a stepped billing factor; 其中,所述精确计费因子为取值范围有限、且其直接取值影响计费结果的计费因子;Wherein, the precise billing factor is a billing factor whose value range is limited and whose value directly affects the billing result; 所述复杂计费因子为经过函数运算后的运算结果影响计费结果的计费因子;The complex billing factor is a billing factor whose calculation result after the function operation affects the billing result; 所述阶梯计费因子为取值范围不可枚举、通过数学公式规整、映射后可转换为所述精确计费因子的计费因子。The step billing factor is a billing factor whose value range cannot be enumerated, is regulated by a mathematical formula, and can be converted into the precise billing factor after mapping. 11.根据权利要求10所述的装置,其特征在于,所述精确计费因子包括:精确因子标识和精确因子取值;11. The device according to claim 10, wherein the precise billing factor comprises: a precise factor identifier and a precise factor value; 所述复杂计费因子包括:复杂因子标识、复杂因子函数和复杂因子参数;The complex charging factors include: complex factor identification, complex factor functions and complex factor parameters; 所述阶梯计费因子包括:阶梯因子标识、阶梯因子函数、阶梯资费标识和阶梯因子参数。The step charging factor includes: a step factor identifier, a step factor function, a step tariff identifier and a step factor parameter. 12.根据权利要求9-11中任一项所述的装置,其特征在于,所述历史计费结果中包含的与所述计费因子存在对应关系的计费结果包括:历史计费公式和业务计费结果中的至少一项;12. The device according to any one of claims 9-11, wherein the charging results included in the historical charging results and corresponding to the charging factors include: historical charging formulas and At least one of the business charging results; 所述历史计费公式为在历史计费过程中归纳总结得到的与所述计费因子对应的用于计费计算的数学公式;The historical billing formula is a mathematical formula for billing calculation corresponding to the billing factor obtained by summarizing the historical billing process; 所述业务计费结果为在历史计费过程中归纳总结得到的与所述计费因子对应的计费金额。The service charging result is the charging amount corresponding to the charging factor summed up in the historical charging process. 13.根据权利要求10或11所述的装置,其特征在于,所述当前业务的计费因子包括:所述精确计费因子和所述复杂计费因子;13. The device according to claim 10 or 11, wherein the charging factor of the current service comprises: the precise charging factor and the complex charging factor; 所述匹配单元,具体用于:The matching unit is specifically used for: 采用所述精确计费因子匹配第一计费结果,所述第一计费结果为所述历史计费结果;Matching a first charging result by using the precise charging factor, where the first charging result is the historical charging result; 若存在第二计费结果,则采用所述复杂计费因子匹配所述第二计费结果,所述第二计费结果为所述第一计费结果中与所述精确计费因子匹配的计费结果;If there is a second charging result, matching the second charging result with the complex charging factor, where the second charging result is the first charging result that matches the precise charging factor billing result; 所述计费单元,具体用于:The billing unit is specifically used for: 若所述匹配单元确定存在第三计费结果,则采用所述第三计费结果,根据所述当前业务的业务使用信息为所述当前业务计费,所述第三计费结果为所述第二计费结果中与所述复杂计费因子匹配的计费结果,以获得所述当前业务的计费结果。If the matching unit determines that there is a third charging result, the third charging result is adopted, and the current service is charged according to the service usage information of the current service, and the third charging result is the A charging result matching the complex charging factor in the second charging result to obtain the charging result of the current service. 14.根据权利要求9-11中任一项所述的装置,其特征在于,所述当前业务的计费因子中包含所述当前业务的计费因子对应的序列化特征值,该序列化特征值用于唯一标识该计费因子;14. The device according to any one of claims 9-11, wherein the billing factor of the current service includes a serialized feature value corresponding to the billing factor of the current service, and the serialized feature The value is used to uniquely identify the charging factor; 所述历史计费结果中包含计费因子以及与所述计费因子存在对应关系的计费结果,具体为:The historical billing results include billing factors and billing results corresponding to the billing factors, specifically: 所述历史计费结果中包含待匹配序列化特征值以及与所述待匹配序列化特征值存在对应关系的计费结果,一个所述待匹配序列化特征值用于唯一标识一个计费因子。The historical charging results include serialized characteristic values to be matched and charging results corresponding to the serialized characteristic values to be matched, and one serialized characteristic value to be matched is used to uniquely identify a charging factor. 15.根据权利要求9-11中任一项所述的装置,其特征在于,所述计费单元,还用于:15. The device according to any one of claims 9-11, wherein the billing unit is further used for: 若所述匹配单元确定不存在与所述当前业务的计费因子匹配的历史计费结果,则分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果。If the matching unit determines that there is no historical charging result that matches the charging factor of the current service, each tariff policy in the tariff policies ordered by the user for the current service is respectively adopted to provide the current Service charging, to obtain the charging result of the current service. 16.根据权利要求15所述的装置,其特征在于,还包括:16. The device of claim 15, further comprising: 保存单元,用于在所述计费单元分别采用所述用户为所述当前业务订购的资费策略中的每一个资费策略,为所述当前业务计费,以获得所述当前业务的计费结果之后,保存所述当前业务的计费因子与所述当前业务的计费结果之间的对应关系。A storage unit, configured to use each of the tariff policies subscribed by the user for the current service in the charging unit to charge the current service, so as to obtain the charging result of the current service Afterwards, the corresponding relationship between the charging factor of the current service and the charging result of the current service is saved. 17.一种业务计费装置,其特征在于,所述业务计费装置包括:17. A service charging device, characterized in that the service charging device comprises: 一个或多个处理器、存储器、总线系统、收发器以及一个或多个应用程序,所述一个或多个处理器、所述存储器和所述收发器通过所述总线系统相连;one or more processors, memory, bus system, transceiver and one or more application programs, said one or more processors, said memory and said transceiver being connected via said bus system; 所述一个或多个应用程序存储在所述存储器中,所述一个或多个应用程序包括指令,当所述业务计费装置的处理器执行所述指令时,所述业务计费装置执行如权利要求1-8中任一项所述的业务计费方法。The one or more application programs are stored in the memory, the one or more application programs include instructions, and when the processor of the service charging device executes the instructions, the service charging device performs the following steps: The service charging method described in any one of claims 1-8.
CN201511028652.7A 2015-12-31 2015-12-31 Service charging method and device Active CN106936601B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201511028652.7A CN106936601B (en) 2015-12-31 2015-12-31 Service charging method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201511028652.7A CN106936601B (en) 2015-12-31 2015-12-31 Service charging method and device

Publications (2)

Publication Number Publication Date
CN106936601A true CN106936601A (en) 2017-07-07
CN106936601B CN106936601B (en) 2020-02-14

Family

ID=59441069

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201511028652.7A Active CN106936601B (en) 2015-12-31 2015-12-31 Service charging method and device

Country Status (1)

Country Link
CN (1) CN106936601B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108009806A (en) * 2017-12-18 2018-05-08 深圳市快付通金融网络科技服务有限公司 Charging regulation collocation method, data system for settling account and computer-readable recording medium
CN108833123A (en) * 2018-04-11 2018-11-16 无锡华云数据技术服务有限公司 Based on according to quantity cloud host charging method and device
CN108898446A (en) * 2018-07-18 2018-11-27 北京百度网讯科技有限公司 Method and apparatus for output information

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1848737A (en) * 2005-04-14 2006-10-18 华为技术有限公司 Charging method
US20070226354A1 (en) * 2004-09-30 2007-09-27 Kt Corporation Apparatus and method for integrated billing management by real-time session management in wire/wireless integrated service network
US7499890B1 (en) * 2003-10-14 2009-03-03 At&T Mobility Ii Llc Cellsite budgetmaster
CN101673385A (en) * 2009-09-28 2010-03-17 百度在线网络技术(北京)有限公司 Consumption preliminary estimate method and device thereof
CN102388564A (en) * 2011-05-06 2012-03-21 华为技术有限公司 Method for rating group processing, method for data service charging, and related device and system
JP2015153039A (en) * 2014-02-12 2015-08-24 株式会社コナミデジタルエンタテインメント Settlement system, privilege management method thereof, and computer program

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7499890B1 (en) * 2003-10-14 2009-03-03 At&T Mobility Ii Llc Cellsite budgetmaster
US20070226354A1 (en) * 2004-09-30 2007-09-27 Kt Corporation Apparatus and method for integrated billing management by real-time session management in wire/wireless integrated service network
CN1848737A (en) * 2005-04-14 2006-10-18 华为技术有限公司 Charging method
CN101673385A (en) * 2009-09-28 2010-03-17 百度在线网络技术(北京)有限公司 Consumption preliminary estimate method and device thereof
CN102388564A (en) * 2011-05-06 2012-03-21 华为技术有限公司 Method for rating group processing, method for data service charging, and related device and system
JP2015153039A (en) * 2014-02-12 2015-08-24 株式会社コナミデジタルエンタテインメント Settlement system, privilege management method thereof, and computer program

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108009806A (en) * 2017-12-18 2018-05-08 深圳市快付通金融网络科技服务有限公司 Charging regulation collocation method, data system for settling account and computer-readable recording medium
CN108833123A (en) * 2018-04-11 2018-11-16 无锡华云数据技术服务有限公司 Based on according to quantity cloud host charging method and device
CN108898446A (en) * 2018-07-18 2018-11-27 北京百度网讯科技有限公司 Method and apparatus for output information

Also Published As

Publication number Publication date
CN106936601B (en) 2020-02-14

Similar Documents

Publication Publication Date Title
CN102811135B (en) Traffic notifying system and method
CN110557729B (en) A roaming charging method and device
CN107295594A (en) Network switching method, device and mobile terminal
JP4964951B2 (en) Intra-area call area determination in wireless networks
CN101110877B (en) A method and system for realizing integrated billing
EP3095261B1 (en) Method, apparatus, online charging system, computer program and computer program product for subscription adaptation
CN110417561B (en) A distributed charging method, device and system based on blockchain
CN106936601B (en) Service charging method and device
CN102137205A (en) Account recharging method and device and charging method, device and system
CN102761851B (en) Charging method and device based on divided detail records
WO2019184632A1 (en) Rating method and apparatus
CN106982126B (en) Resource sharing charging method and charging device, and memory bank
CN110381222A (en) The determination method and apparatus of Information Mobile Service state
CN106714128A (en) Automatic fee-paying method and terminal
CN105813046A (en) Bandwidth control method, device and system
US20120284208A1 (en) Systems and/or Methods For Delivering Notifications On A Communications Network
US20160366575A1 (en) Mobile digital cellular telecommunication system with advanced functionality for rating correction
CN104202738A (en) Policy control method and system and gateway
CN101754159A (en) Charging method, charging server and charging system
CN106921502A (en) The method of charging and policy control, PCRF and OCS
CN104602239A (en) Mobile communication copy card determination method and system
CN101309332A (en) Charging method and system
CN115994756A (en) Ticket processing method, ticket processing device, electronic equipment and readable storage medium
CN102142968B (en) Charging method, device and system
WO2021121176A1 (en) Method and device for updating status information of sim card, and server

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载