Specific implementation mode
In order to keep technical problems, technical solutions and advantages to be solved clearer, clear, tie below
Drawings and examples are closed, the present invention will be described in further detail.It should be appreciated that specific embodiment described herein is only
To explain the present invention, it is not intended to limit the present invention.
Fig. 2 is in the embodiment of the present invention, and the network architecture schematic diagram of short message charging method, SMSC is needed to message sink
When side sends short message, home location register (HLR, Home Location Register) query messages recipient is first passed through
It is presently in the network information of network and is presently in the area information in region, if the message receiver is advanced charge
The network information determined and area information are then sent to prepayment charging system, then the letter of the network by inquiring by family
Breath and the corresponding MSC of area information, are sent to message receiver by short message, if sending successfully, notify prepaid accounting
System carries out charging to message receiver.
As shown in figure 3, being short message charging method flow chart of the embodiment of the present invention, specific process flow is as follows:
Step 31, when SMSC needs to send short message to message receiver, determine that message receiver is presently in network
The network information and the area information for being presently in region;
SMSC receives message sender and needs to be sent to after the short message of message receiver, first determines message receiver
It is presently in the network information of network and is presently in the area information in region, wherein SMSC can inquire this from HLR and disappear
Breath recipient is presently in the MSC identification informations of MSC, can determine that message receiver is presently according to MSC identification informations
The network information and message receiver of network are presently in the area information in region, specifically:The identification information of MSC is using pre-
If coding rule encoded after obtain, after SMSC obtains the identification information of MSC, by the preset coding rule,
It can determine that message receiver is presently in the network information of network and message receiver is presently in the area information in region.
Step 32, if the message receiver is prepaid user, by the network information determined and area information
It is sent to prepayment charging system;
SMSC inquires the message receiver and is presently in after the MSC identification informations of MSC, if the message receiver is pre-
The MSC identification informations are then sent to prepayment charging system by paying customer, and prepayment charging system is according to the MSC received
Identification information determines that message receiver is presently in the network information of network and is presently in the area information in region.
The network information determined and area information are sent to prepayment charging system to can be, but not limited under including
State two kinds of situations:
The network information determined and area information directly can be sent to prepaid accounting by the first situation, SMSC
System, in correspondence of the prepayment charging system between the network information, area information and charging rate, lookup receives
The network information and the corresponding charging rate of area information calculate and need from message then according to the charging rate that finds
The expense deducted in the account of recipient, prepayment charging system judge whether the expense in the account of message receiver is not less than
The expense deducted is needed, if judging to be not less than, is sent a notification message to SMSC, SMSC, which is received, to send a notification message
Afterwards, short message is sent to message receiver, if judging to be less than, sends arrearage notification message to SMSC, SMSC is received
After arrearage notification message, terminate the transmission flow of the short message, if SMSC is successfully transmitted the short message, to prepaid accounting system
System sends charging request message, after prepayment charging system receives the charging request message of SMSC transmissions, according to calculated
Expense carries out charging to message receiver.
The second situation, when calculating the expense for needing to deduct in order to avoid prepayment charging system, message receiver
Expense in account is not less than the expense for needing to deduct, but when carrying out charging to message receiver, the account of message receiver
Expense in family is less than the expense for needing to deduct, i.e. message receiver arrearage, can will be true in this regard, the embodiment of the present invention proposes
The network information and area information made carry in expense freeze request message, are sent to prepayment charging system, prepay
Take in correspondence of the charge system between the network information, area information and charging rate, searches the network letter received
Breath and the corresponding charging rate of area information are calculated and are needed from message receiver then according to the charging rate found
The expense deducted in account, prepayment charging system judge whether the expense in the account of message receiver is not less than and need to deduct
Expense the expense determined is carried out freezing to handle if judging to be not less than, prevent from subsequently counting message receiver
Time-consuming, then which sends expense to SMSC and freezes response message, and SMSC, which receives expense, to be freezed response and disappear
After breath, short message is sent to message receiver, if judging to be less than, expense is sent to SMSC and freezes failed message, SMSC
After the expense of receiving freezes failed message, terminate the transmission flow of the short message.
Step 33, short message is sent to the message receiver;
SMSC receive prepayment charging system transmission send a notification message (the first above-mentioned situation) or expense is freezed
After response message (above-mentioned the second situation), short message is sent to message receiver.
Step 34, after sending successfully, charging request message is sent to the prepayment charging system, indicates the prepayment
Expense charge system counts the message receiver according to the corresponding charging rate of the network information and location information received
Take.
For the first above-mentioned situation, after prepayment charging system receives charging request message, taken according to calculated
With to message receiver progress charging;
For above-mentioned the second situation, after prepayment charging system receives charging request message, for the expense freezed
Carry out charging processing.
If SMSC sends failure, SMSC retransmits short message to message receiver, until sending successfully or short disappearing
The sending time length of breath has been more than that preset effective time length or transmission times have reached preset number, if short message
Final to send failure, then SMSC sends expense defrosting request message to prepayment charging system, and prepayment charging system is receiving
To after expense defrosting request message, defrosting processing is carried out to the expense freezed.
If prepayment charging system does not receive charging request message in predetermined time interval or expense is thawed and asked
Message then can carry out defrosting processing to the expense freezed automatically.
Preferably, in order to reduce the quantity of the message of interaction between SMSC and prepayment charging system, reduce pre-payment meter
The processing load of charge system, the embodiment of the present invention propose that SMSC is sending expense freeze request message to prepayment charging system
Before, it can first judge whether the network information this time determined is consistent with the network information that the last time is determined, and this time
Whether the area information determined is consistent with the area information that the last time is determined, if judging result is to be, not to prepayment
Take charge system and send expense freeze request message, otherwise executes the network information that will be determined and area information is carried in expense
With the operation for being sent to prepayment charging system in freeze request message.
SMSC can also first judge that the message connects before sending expense freeze request message to prepayment charging system
Whether the terminal that debit uses is in off-mode, if the determination result is YES, does not then send expense to prepayment charging system and freezes
Request message is tied, the network information that will be determined otherwise is executed and area information carrying is sent in expense freeze request message
To the operation of prepayment charging system.
When prepaid billing system is to message receiver charging, the network information and area information that are received according to the last time
Corresponding charging rate determines the expense for needing to be deducted from the account of message receiver.
By above-mentioned processing procedure it is found that in the embodiment of the present application technical solution, SMSC needs to send to message receiver short
When message, determine that message receiver is presently in the network information of network and is presently in the area information in region, if described
Message receiver is prepaid user, then the network information determined and area information is sent to prepayment charging system,
Short message is sent to the message receiver by SMSC, and after sending successfully, and charging is sent to the prepayment charging system
Request message indicates the prepayment charging system according to the corresponding charging rate pair of the network information and location information received
The message receiver carries out charging.Therefore in technical solution of the embodiment of the present invention, after short message is sent successfully,
SMSC just notifies prepayment charging system to carry out charging, and prepayment charging system is to be presently in net according to message receiver
It network and is presently in region and carries out charging, therefore avoid since message receiver carries out inter-network roaming or interregional
The problem of charging inaccuracy, is effectively improved the accuracy to message receiver charging caused by roaming.
More detailed embodiment is given below.
As shown in figure 4, in the embodiment of the present invention, short message charging method specific implementation flow chart, specific processing stream
Journey is as follows:
Step 41, SMSC acquisitions message sender needs the short message for being sent to message receiver;
Step 42, SMSC inquires the MSC identification informations that the message receiver is presently in MSC from HLR;
Step 43, if message receiver is prepaid user, SMSC judges whether the terminal that message receiver uses is located
In open state, if the determination result is YES, then step 44 is gone to, if judging result is no, goes to step 411;
Step 44, whether the MSC identification informations that the MSC identification informations that SMSC judgements this time inquire are inquired with the last time
It is identical, if judging result is no, step 45 is gone to, if the determination result is YES, then goes to step 411;
Step 45, SMSC carries the MSC identification informations inquired in expense freeze request message, is sent to pre-payment
Charge system;
Step 46, prepayment charging system searches corresponding charging rate;
Step 47, prepayment charging system calculates the account needed from message receiver according to the charging rate found
The expense of middle deduction;
Step 48, whether prepayment charging system judges the expense in the account of message receiver not less than needing to deduct
Expense if the determination result is YES then goes to step 49, if judging result is no, goes to step 418;
Step 49, the expense determined is carried out freezing to handle by prepayment charging system;
Step 410, prepayment charging system sends expense freeze request message to SMSC;
Step 411, short message is sent to message receiver by SMSC;
Step 412, SMSC judges whether to send successfully, if the determination result is YES, then goes to step 413, if judging result
It is no, then goes to step 415;
Step 413, SMSC sends charging request message to prepayment charging system;
Step 414, it after prepayment charging system receives charging request message, is carried out at charging for the expense freezed
Reason, then goes to step 418;
Step 415, judge whether to need to retry, if the determination result is YES, then go to step 41, if judging result is no,
Then go to step 416;
Step 416, SMSC sends expense defrosting request message to prepayment charging system;
Step 417, prepayment charging system carries out defrosting processing to the expense freezed;
Step 418, terminate the transmission flow of short message.
Correspondingly, the embodiment of the present invention also provides a kind of SMSC, structure is as shown in figure 5, include:
Information determination unit 51, for when needing to send short message to message receiver, determining that message receiver is current
The network information of residing network and the area information for being presently in region;
Information transmitting unit 52 is used for when the message receiver is prepaid user, and information determination unit 51 is true
The network information and area information made are sent to prepayment charging system;
Short message transmission unit 53, for short message to be sent to the message receiver;
Charging request message transmission unit 54 is used for after short message transmission unit 53 is sent successfully, to the pre-payment
Charge system sends charging request message, indicates the prepayment charging system according to the network information and location information received
Corresponding charging rate carries out charging to the message receiver.
Preferably, information determination unit 51 is specifically used for, determine that message receiver is presently in the MSC identification informations of MSC;
Information transmitting unit 52 is specifically used for, and the MSC identification informations that information determination unit 51 is determined are sent to prepayment
Take charge system.
Preferably, information transmitting unit 52 is specifically used for, the network information that information determination unit 51 is determined and area
Domain information carries in expense freeze request message, is sent to prepayment charging system;
The SMSC further includes that expense freezes response message receiving unit, in short message transmission unit 53 by short message
It is sent to before the message receiver, receives the expense that prepayment charging system is sent and freeze response message.
More preferably, the SMSC further includes information judging unit, in information transmitting unit 52 by information determination unit
51 network informations determined and area information carrying be sent in expense freeze request message prepayment charging system it
Before, judge whether the network information that information determination unit 51 is this time determined is consistent with the network information that the last time is determined, with
And whether the area information this time determined is consistent with the area information that the last time is determined;
Information transmitting unit 52 is specifically used for, when the judging result of described information judging unit is to be, not to prepayment
Take charge system and sends expense freeze request message, the network information for otherwise determining information determination unit 51 and region letter
Breath carries and is sent to prepayment charging system in expense freeze request message.
More preferably, the SMSC further includes condition adjudgement unit, in information transmitting unit 52 by information determination unit
51 network informations determined and area information carrying be sent in expense freeze request message prepayment charging system it
Before, judge whether the terminal that the message receiver uses is in off-mode;
Information transmitting unit 52 is specifically used for, when the judging result of described information judging unit is to be, not to pre-payment
Charge system sends expense freeze request message, the network information for otherwise determining information determination unit 51 and area information
Carrying is sent to prepayment charging system in expense freeze request message.
Correspondingly, the embodiment of the present invention also provides a kind of prepayment charging system, structure is as shown in fig. 6, include:
Information receiving unit 61 is presently in the net of network for receiving SMSC transmissions, short message message receiver
Network information and the area information for being presently in region;
Charging request message receiving unit 62, the charging request message sent for receiving the SMSC;
Charging Detail Record unit 63, for after charging request message receiving unit 62 receives charging request message, according to information
The corresponding charging rate of the network information and location information that receiving unit 61 receives carries out charging to message receiver.
Preferably, information receiving unit 61 specifically includes:
Identification information receiving subelement is presently in the MSC marks of MSC for receiving SMSC is sent, message receiver
Information;
Information determination subelement, the MSC identification informations for being received according to identification information receiving subelement, determines message
Recipient is presently in the network information of network and is presently in the area information in region.
Preferably, information receiving unit 61 is specifically used for, the expense freeze request message that SMSC is sent, the expense are received
Message receiver is carried in freeze request message to be presently in the network information of network and be presently in the region letter in region
Breath;
The prepayment charging system further includes:
Expense determination unit disappears for receiving the accounting request that the SMSC is sent in charging request message receiving unit 62
Before breath, the network information and area information received according to information receiving unit 61 determines the account needed from message receiver
The expense deducted in family;
Expense freezing unit, the expense for determining expense determination unit carry out freezing to handle;
Expense freezes response message transmission unit, freezes response message for sending expense to the SMSC;
Charging Detail Record unit 63 is specifically used for, and the expense freezed for expense freezing unit carries out charging processing.
More preferably, expense determination unit is specifically used for, and is believed according to the network that 61 the last time of information receiving unit receives
Breath and area information determine the expense for needing to be deducted from the account of message receiver.
A preferred embodiment of the present invention has shown and described in above description, but as previously described, it should be understood that the present invention
Be not limited to form disclosed herein, be not to be taken as excluding other embodiments, and can be used for various other combinations,
Modification and environment, and the above teachings or related fields of technology or knowledge can be passed through in the scope of the invention is set forth herein
It is modified.And changes and modifications made by those skilled in the art do not depart from the spirit and scope of the present invention, then it all should be in this hair
In the protection domain of bright appended claims.