CN102254037B - Menu interactive processing method applied to unstructured supplementary service data (USSD) system - Google Patents

Menu interactive processing method applied to unstructured supplementary service data (USSD) system Download PDF

Info

Publication number
CN102254037B
CN102254037B CN 201110229400 CN201110229400A CN102254037B CN 102254037 B CN102254037 B CN 102254037B CN 201110229400 CN201110229400 CN 201110229400 CN 201110229400 A CN201110229400 A CN 201110229400A CN 102254037 B CN102254037 B CN 102254037B
Authority
CN
China
Prior art keywords
menu
array
submenu
ussd
ussd system
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.)
Expired - Fee Related
Application number
CN 201110229400
Other languages
Chinese (zh)
Other versions
CN102254037A (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.)
BEIJING BEIWEI COMMUNICATION SCIENCE AND TECHNOLOGY Co Ltd
Original Assignee
BEIJING BEIWEI COMMUNICATION SCIENCE AND TECHNOLOGY 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 BEIJING BEIWEI COMMUNICATION SCIENCE AND TECHNOLOGY Co Ltd filed Critical BEIJING BEIWEI COMMUNICATION SCIENCE AND TECHNOLOGY Co Ltd
Priority to CN 201110229400 priority Critical patent/CN102254037B/en
Publication of CN102254037A publication Critical patent/CN102254037A/en
Application granted granted Critical
Publication of CN102254037B publication Critical patent/CN102254037B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a menu interactive processing method applied to an unstructured supplementary service data (USSD) system. The method comprises the following steps of: establishing and storing a menu record in a database in the USSD system, wherein the menu record comprises a menu sequence number identity (ID), a parent menu ID, a menu title and a menu sequence number; reading the menu record and establishing a menu array in a memory by the USSD system, wherein the menu array comprises a menu ID, the parent menu ID, the menu title and an array subscript; establishing parent menu and submenu relationship information linked list arrays in the USSD system by using the menu array, wherein elements of each parent menu and submenu relationship information linked list comprises the menu ID, the parent menu ID, the array subscript, the number of submenu and a subscript list of the submenu; and receiving requests by the USSD system, and traversing and retrieving the parent menu and submenu relationship information linked list arrays according to the menu ID and a pointer so as to acquire menu information corresponding to the parent menu ID, the array subscript and the number of the submenu. By the method, the menu retrieval processing ability in the USSD system can be greatly improved; and the menu interactive speed and the processing capacity of unit time can be increased.

Description

Be applied to the menu mutual disposal route of unstructured supplementary data traffic system
Technical field
The present invention relates to the mobile communication service field, specifically, the present invention relates to a kind of menu mutual disposal route that is applied to unstructured supplementary data traffic (USSD, Unstructured Supplementary Service Data) system.
Background technology
Present implementation commonly used is that the menu level relation is stored in the database, comprise frequently-used data storehouses such as SqlServer, Oracle, associated menu information by SQL statement retrieval certain menu ID realize the downward rank of menu or upwards level other is mutual, though this is a kind of universal method, but a large amount of menu informations of storage and carry out a large number of users concurrent mutual, when needing quick retrieval process, data base method efficient is lower.
For example, the following menu essential information of storage in the database
Menu ID (sequence number) Father's menu ID Menu header The menu sequence number
1 0 Root menu 0
2 1 One-level menu A 1
3 1 One-level menu B 2
4 2 Second-level menu A1 1
5 2 Second-level menu A2 2
6 3 Second-level menu B1 1
7 3 Second-level menu B2 2
8 3 Second-level menu B3 3
When 1, the user was mutual first, business platform issued the one-level menu to the user, as:
The processing mode of business platform is to be the menu content that all record combinations of 1 obtain by father's menu in the SQL searching database;
2, after the user selected " 1 one-level menu A ", business platform issued next rank (being secondary) menu to the user, as:
Figure BSA00000555037100021
The processing mode of business platform is:
(1) by the SQL searching database obtain that father's menu is 1, the menu sequence number is 1 menu ID, namely menu ID is 2;
(2) obtaining father's menu by the SQL searching database is all record combinations of 2, obtains two rank menu contents.
3, the user selects " 9 return the higher level ", and business platform issues not (being one-level) menu of upper level to the user, as:
Figure BSA00000555037100022
The processing mode of business platform is:
(1) obtaining menu ID by the SQL searching database is that father's menu ID of 2 is 1;
(2) obtaining father's menu ID by the SQL searching database is that all record combinations of 1 obtain upper level (being one-level) menu content.
As can be seen, each menu or make progress when mutual all needs to carry out SQL retrieval 1 or 2 time downwards, when a lot of for the very big or concurrent mutual user of menu quantity, certainly will occur the bottleneck of database retrieval easily from above-mentioned example.
Summary of the invention
Technical matters to be solved by this invention is to adopt dynamic array and linked list array technology, a kind of menu mutual disposal route that is applied to the unstructured supplementary data traffic system is provided, can't carries out quick retrieval process and the relatively lower problem of efficient to solve database commonly used.
For solving the problems of the technologies described above, the invention provides a kind of menu mutual disposal route that is applied to unstructured supplementary data traffic USSD system, comprising:
Database in described USSD system is set up and the storage menu record, and this menu record comprises: menu sequence number ID, father's menu ID, menu header and menu sequence number;
Described USSD system reads described menu record and set up the menu array in internal memory, and this menu array comprises: menu ID, father's menu ID, menu header and array index;
In described USSD system, utilize described menu array to set up menu set membership information chained list array, wherein, the element in each menu set membership information chained list comprises: menu ID, father's menu ID, array index, submenu number and submenu subscript list;
Described USSD system receives request, and by described menu ID and the described menu set membership information chained list array of pointer traversal retrieval, obtains the menu information of father's menu ID, array index and the submenu number of correspondence.
Further, wherein, described menu set membership information chained list array is made up of n menu set membership information chained list, and described linked list array length n is more than or equal to 2.
Further, wherein, the element in described each menu set membership information chained list further comprises: the next node pointer.
Further, wherein, described submenu subscript list is supported 64 sub-menu information at most.
Further, wherein, the form of described menu ID, father's menu ID and array index all adopts 8 bytes.
Further, wherein, the form of described submenu number adopts 4 bytes.
Compared with prior art, the method for the invention can improve menu retrieval process ability in the unstructured supplementary data traffic system significantly, and then improves menu mutual speed and the processing capacity of unit interval.By dynamic menu storage of array menu information, can realize navigating to concrete menu information fast by array index; The subscript of menu set membership information in linked list array is that modular arithmetic obtains to linked list array length according to menu ID, adopts the mode that increases chained list node to append storage when subscript is identical, can improve the memory capacity of menu relation information greatly; By pointer chained list storage of array menu relation information, can realize retrieving fast by menu ID the related information of menu, the number and the subscript information of submenu in dynamic menu array that comprise the subscript of menu in dynamic array, father's menu ID, submenu, and then can retrieve the information of father's menu in linked list array fast, also can retrieve menu information and sub-menu information by the menu dynamic array; By above-mentioned menu retrieval mode, comprise by menu ID and determine menu set membership information, determine menu information by array index, can finish custom menu mutual function fast.
Description of drawings
Fig. 1 is the described schematic flow sheet that is applied to the menu mutual disposal route of unstructured supplementary data traffic system of the embodiment of the invention.
Embodiment
Main thought of the present invention is to solve database commonly used can't carry out quick menu retrieval process and the relatively lower problem of efficient.The menu mutual disposal route that is applied to the unstructured supplementary data traffic system of the present invention.Below embodiment is described in detail, but not as a limitation of the invention.
USSD involved in the present invention (Unstructured Supplementary Service Data, unstructured supplementary data traffic) system is a kind of based on GSM (Global System of Mobile communication; Global system for mobile communications) the interactive data business of network.The menu of described USSD has obtained using very widely as the conventional means of service platform and user interactions in the USSD business.
As shown in Figure 1, the embodiment of the invention one described menu mutual disposal route that is applied to the USSD system, in the Database Systems that are applied to use always, this method comprises the steps:
Step 101, the database in described USSD system are set up and the storage menu record, and this menu record comprises: menu ID (Identity, sequence number), father's menu ID, menu header and menu sequence number;
Step 102, described USSD system read the menu record and set up the menu array in internal memories, and this menu array comprises: menu ID (Identity, sequence number), father's menu ID, menu header and array index;
Step 103, in described USSD system, utilize described menu array to set up menu set membership information chained list array, wherein, the element in each menu set membership information chained list comprises: menu ID, father's menu ID, array index, submenu number, submenu subscript list and next node pointer;
Step 104, described USSD system receives request, and by menu ID and pointer traversal search menu set membership information chained list array, obtains corresponding menu informations such as father's menu ID, array index and submenu number.
Wherein, step 101 is specially:
Database in described USSD system is set up and the storage menu record, and this menu record comprises: menu ID (Identity, sequence number), father's menu ID, menu header and menu sequence number.Because the quantity of menu is variable in the menu record, thereby the array length of storage menu record also is variable, and the storage essential information of menu record is as follows:
Menu ID Father's menu ID Menu header The menu sequence number
1 0 Root menu 0
2 1 One-level menu A 1
3 1 One-level menu B 2
4 2 Second-level menu A1 1
5 2 Second-level menu A2 2
6 3 Second-level menu B1 1
7 3 Second-level menu B2 2
8 3 Second-level menu B3 3
Step 102 is specially:
Described USSD system reads the menu record and set up the menu array in internal memory, and described menu array comprises: menu ID (Identity, sequence number), father's menu ID, menu header and array index; The storage essential information of menu array is as follows:
Menu ID Father's menu ID Menu header Array index
1 0 Root menu 0
2 1 One-level menu A 1
3 1 One-level menu B 2
4 2 Second-level menu A1 3
5 2 Second-level menu A2 4
6 3 Second-level menu B1 5
7 3 Second-level menu B2 6
8 3 Second-level menu B3 7
Step 103 is specially:
In described USSD system, utilize described menu array to set up menu set membership information chained list array, wherein, the element in each menu set membership information chained list comprises: menu ID, father's menu ID, array index, submenu number, submenu subscript list and next node pointer.Following content:
Menu set membership information chained list array adopts the storage of array (the chained list array length adopts 4 in this example, just 4 chained lists) of regular length, and wherein each menu set membership information chained list element comprises following field:
Figure BSA00000555037100051
Each field length is as follows in the foregoing:
Menu ID: 8 bytes;
Father's menu ID: 8 bytes;
Array index: 8 bytes;
Submenu number: 4 bytes;
Submenu subscript list: 8 byte * 64 (this submenu subscript list can be supported 64 sub-menu information);
Next node pointer: address pointer (the address word joint number is decided on different concrete conditions)
Be the structure that this routine Chinese food Shanfu subrelation information chained list array adopts 4 chained lists below:
Linked list array subscript 0:
Linked list array subscript 1:
Figure BSA00000555037100072
Linked list array subscript 2:
Figure BSA00000555037100073
Linked list array subscript 3:
Step 104 is specially:
Described USSD system receives request, and by menu ID and pointer traversal search menu set membership information chained list array, obtains corresponding menu informations such as father's menu ID, array index and submenu number.Specifically:
Between USSD system and user, take place when mutual for the first time, reply the one-level menu information of root menu correspondence by menu ID, the ID that the search menu array obtains root menu is 1, the linked list array length 4 of root menu ID is carried out modular arithmetic and is obtained 1, just menu information is stored in down and is designated as in 1 the linked list array element, array index in the pointer traversal search menu set membership information chained list array be 1 data to obtain menu ID be 1 two submenus to be arranged, be respectively 1 and 2 in the corresponding submenu subscript list; It is that 1 and 2 menu data is formed the one-level menu information that the USSD system obtains the menu array index, replies to the user to be:
Upgrading the current menu position of user simultaneously is that menu ID is 1.
Another embodiment, can also be when choice menus option in the USSD system " 1 one-level menu A ", be 1 according to the current set of menu ID, menu ID is carried out modular arithmetic to menu set membership information chained list array length 4 and is obtained 1, and the array index in the pointer traversal search menu set membership information chained list array is that to obtain menu ID be to be designated as 1 and 2 under the 1 corresponding submenu for 1 data; When selecting 1, then enter subordinate's menu of first option, just be designated as subordinate's menu of 1 down, get in the menu array and time to be designated as 1 menu data to obtain menu ID be 2; Menu ID is carried out modular arithmetic to menu set membership information chained list array length 4 and is obtained 2, and the array index in the pointer traversal search menu set membership information chained list array is that to obtain menu ID be that the submenu that is designated as under the 2 corresponding submenus is subscript 3 and 4 for 2 data; It is 3 and 4 menu information that the USSD system obtains the menu array index, forms menu content and replies to the user and be:
Figure BSA00000555037100081
Upgrading the current menu position of user simultaneously is that menu ID is 2.
Further, the elected uniterming " 9 return the higher level " of triming vegetables for cooking, be 2 according to user's the current set of menu ID, menu ID is carried out modular arithmetic to menu set membership information chained list array length 4 and is obtained 2, and pointer traversal search menu set membership information chained list array index is that to obtain menu ID be that 2 corresponding father's menu ID are 1 for 2 data; Father's menu ID is carried out modular arithmetic to menu set membership information chained list array length 4 and is obtained 1, and pointer traversal search menu set membership information chained list array index is that to obtain menu ID be that 1 corresponding submenu array index is 1 and 2 for 1 data; It is 1 and 2 menu information that the USSD system obtains the menu array index, forms menu content and replies to the user and be:
Figure BSA00000555037100082
Description by above-described embodiment, the menu mutual disposal route that is applied to the unstructured supplementary data traffic system of the present invention is carried out menu retrieval, interaction process according to the characteristics of menu mutual mode, menu relation and menu information structure, the method of the dynamic array of integrated use and linked list array provides a kind of and retrieves the interaction process ability fast at a large amount of menus.
The difference of the database table retrieval in the method for the invention and the general data storehouse system is:
1, menu information is stored in the menu array, directly navigates to concrete menu information by array index, retrieval rate is much higher than the search processing method of menu in the system of general data storehouse;
2, menu set membership information is stored in the linked list array, by the retrieval to menu ID, obtain relevant menu subscript information, and then can from the menu array, retrieve concrete menu information according to the menu subscript, the speed of directly locating by subscript is higher than the retrieval mode that the general data storehouse is shown far away, particularly under the very big situation of menu amount;
3, with the storage mode of menu set membership information in linked list array, be according to menu ID linked list array length to be carried out modular arithmetic, obtain the memory location subscript of menu, the menu relation information that subscript is identical adopts the mode of appending chained list node to store, thereby can improve the memory capacity of menu relation information greatly;
4, method of the present invention goes for the interaction process of man-machine interaction menu in the conventional system.
Compared with prior art, the present invention can improve menu mutual retrieval process ability in the USSD system significantly, and then improves menu mutual speed and the processing capacity of unit interval.By dynamic menu storage of array menu information, can realize navigating to concrete menu information fast by array index; The subscript of menu set membership information in linked list array is that modular arithmetic obtains to linked list array length according to menu ID, adopts the mode that increases chained list node to append storage when subscript is identical, can improve the memory capacity of menu relation information greatly; By pointer chained list storage of array menu relation information, can realize retrieving fast by menu ID the related information of menu, the number and the subscript information of submenu in dynamic menu array that comprise the subscript of menu in dynamic array, father's menu ID, submenu, and then can retrieve the information of father's menu in linked list array fast, also can retrieve menu information and sub-menu information by the menu dynamic array; By above-mentioned menu retrieval mode, comprise by menu ID and determine menu set membership information, determine menu information by array index, can finish custom menu mutual function fast.
Certainly; the present invention also can have other various embodiments; under the situation that does not deviate from spirit of the present invention and essence thereof; those of ordinary skill in the art can make various corresponding changes and distortion according to the present invention, but these corresponding changes and distortion all should belong to the protection domain of the appended claim of the present invention.

Claims (6)

1. a menu mutual disposal route that is applied to unstructured supplementary data traffic USSD system is characterized in that, comprising:
Database in described USSD system is set up and the storage menu record, and this menu record comprises: menu sequence number ID, father's menu ID, menu header and menu sequence number;
Described USSD system reads described menu record and set up the menu array in internal memory, and this menu array comprises: menu ID, father's menu ID, menu header and array index;
In described USSD system, utilize described menu array to set up menu set membership information chained list array, wherein, the element in each menu set membership information chained list comprises: menu ID, father's menu ID, array index, submenu number and submenu subscript list;
Described USSD system receives request, and by described menu ID and the described menu set membership information chained list array of pointer traversal retrieval, obtains the menu information of father's menu ID, array index and the submenu number of correspondence.
2. the menu mutual disposal route that is applied to the USSD system as claimed in claim 1 is characterized in that, described menu set membership information chained list array is made up of n menu set membership information chained list, and described linked list array length n is more than or equal to 2.
3. the menu mutual disposal route that is applied to the USSD system as claimed in claim 1 or 2 is characterized in that, the element in described each menu set membership information chained list further comprises: the next node pointer.
4. the menu mutual disposal route that is applied to the USSD system as claimed in claim 3 is characterized in that, described submenu subscript list is supported 64 sub-menu information at most.
5. the menu mutual disposal route that is applied to the USSD system as claimed in claim 1 is characterized in that, the form of described menu ID, father's menu ID and array index all adopts 8 bytes.
6. the menu mutual disposal route that is applied to the USSD system as claimed in claim 5 is characterized in that the form of described submenu number adopts 4 bytes.
CN 201110229400 2011-08-11 2011-08-11 Menu interactive processing method applied to unstructured supplementary service data (USSD) system Expired - Fee Related CN102254037B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201110229400 CN102254037B (en) 2011-08-11 2011-08-11 Menu interactive processing method applied to unstructured supplementary service data (USSD) system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201110229400 CN102254037B (en) 2011-08-11 2011-08-11 Menu interactive processing method applied to unstructured supplementary service data (USSD) system

Publications (2)

Publication Number Publication Date
CN102254037A CN102254037A (en) 2011-11-23
CN102254037B true CN102254037B (en) 2013-07-03

Family

ID=44981301

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201110229400 Expired - Fee Related CN102254037B (en) 2011-08-11 2011-08-11 Menu interactive processing method applied to unstructured supplementary service data (USSD) system

Country Status (1)

Country Link
CN (1) CN102254037B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106599210A (en) * 2016-12-15 2017-04-26 北京小米移动软件有限公司 Information processing method and apparatus
CN107992610A (en) * 2017-12-15 2018-05-04 泰康保险集团股份有限公司 A kind of automatic question-answering method, device, equipment and storage medium
CN110879871B (en) * 2019-11-26 2022-09-27 杭州迪普科技股份有限公司 Page menu configuration method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101126978A (en) * 2007-09-25 2008-02-20 康佳集团股份有限公司 Multi-stage menu implement method
CN101510207A (en) * 2009-02-26 2009-08-19 中兴通讯股份有限公司 Tree menu dynamic maintenance method and apparatus based on web page

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2009135175A2 (en) * 2008-05-01 2009-11-05 Starscriber Corporation Mobile communications facilitated by interactive menus

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101126978A (en) * 2007-09-25 2008-02-20 康佳集团股份有限公司 Multi-stage menu implement method
CN101510207A (en) * 2009-02-26 2009-08-19 中兴通讯股份有限公司 Tree menu dynamic maintenance method and apparatus based on web page

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
李敏通,张战国.一种建立单片机应用系统菜单的新方法.《计算机工程》.2006,第32卷(第16期),259-260,273. *

Also Published As

Publication number Publication date
CN102254037A (en) 2011-11-23

Similar Documents

Publication Publication Date Title
CN106528787B (en) query method and device based on multidimensional analysis of mass data
CN104281701B (en) Multiscale Distributed Spatial data query method and system
CN103020281B (en) A kind of data storage and retrieval method based on spatial data numerical index
US8364689B2 (en) Methods and apparatus for providing a location based search
CN101944124B (en) Distributed file system management method, device and corresponding file system
CN102930060B (en) A kind of method of database quick indexing and device
CN102456055B (en) Method and device for retrieving interest points
CN104135715B (en) The implementation method of location-based service, a device, and system
US20140096032A1 (en) Centralized media handling
CN103473230A (en) Service range determining method, logistics service provider recommending method and corresponding device
CN101727502A (en) Data query method, data query device and data query system
CN106649633A (en) Name method and system of desktop folder
CN104111935A (en) Server and microblog pushing method and system
CN102467521A (en) Easily-extensible multi-level classification search method and system
CN103747047A (en) CDN file storage method, file distribution control center and system thereof
KR101794883B1 (en) Method for generating and storing high speed diatributed index of massive spatial data in data-distributed processing
CN102254037B (en) Menu interactive processing method applied to unstructured supplementary service data (USSD) system
CN106503196A (en) The structure and querying method of extensible storage index structure in cloud environment
CN107766433A (en) A kind of range query method and device based on Geo BTree
KR102153806B1 (en) Data processing method and device
CN104486777A (en) Method and device for processing data
CN103559209A (en) Method for querying nearest neighbor of efficient space combined by Voronoi Diagram and virtual grids
CN101963993B (en) Method for fast searching database sheet table record
CN108776666A (en) It is a kind of to fall to arrange spatial key word querying method and device with Trie based on keyword
CN113468080B (en) Caching method, system and related device for full-flash metadata

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20130703

Termination date: 20210811