CN101808161B - Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number - Google Patents
Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number Download PDFInfo
- Publication number
- CN101808161B CN101808161B CN2010101396900A CN201010139690A CN101808161B CN 101808161 B CN101808161 B CN 101808161B CN 2010101396900 A CN2010101396900 A CN 2010101396900A CN 201010139690 A CN201010139690 A CN 201010139690A CN 101808161 B CN101808161 B CN 101808161B
- Authority
- CN
- China
- Prior art keywords
- information
- jump
- card
- home location
- portable terminal
- 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
Links
Images
Landscapes
- Mobile Radio Communication Systems (AREA)
Abstract
The invention relates to a method and a device for inquiring the area to which a phone number is attributed and the type of an SIM card for the phone number. The information that whether the phone number is the mobile phone number or the fixed phone number can be inquired and the area to which the phone number is attributed and the type of the SIM card for the telephone number can be also inquired by judging the information on the initial number, the second number, the third number and the length of the phone number and looking up the domestic area code table, the international area code table, the mobile phone number section information table and the domestic characteristic service telephone number table, thus more information can be provided for the mobile terminal user, and the mobile terminal user can use the phone number more conveniently.
Description
Technical field
The present invention relates to communication field, particularly relate to the method and apparatus of a kind of enquiring telephone number ownership place and type.
Background technology
At present; Continuous development along with mobile communication technology; Portable terminal (comprising that mobile phone, PDA etc. have the small hand-held formula mobile communication equipment of wireless communication function) has been deep in people's the life; It occupies an important position in user's life as the instrument of daily life and business.
Usually, the communication service chamber of commerce provides incoming call display function for user's portable terminal, promptly when receiving phone or short message, shows the other side's telephone number.The telephone number of user during for the incoming call number that has obtained, telephone number that oneself has been transferred to or the short breath of transmitting-receiving can deposit it in address list, and add relevant informations such as the other side's name, address, so that directly call when using next time.
But portable terminal of the prior art can not show the other side's number attribution, information such as the SIM type of using when incoming call, dialing or transmitting-receiving new information, limited the understanding of user to above-mentioned information.Therefore, be necessary to provide the method for a kind of ability enquiring telephone number information of home location and Card Type, for mobile phone users provides more convenience.
Summary of the invention
To defective that exists in the prior art and deficiency, the objective of the invention is to propose the method and the device of a kind of enquiry number information of home location and Card Type, can more information be provided for the user, user-friendly.
In order to achieve the above object, the present invention proposes the method for a kind of enquiring telephone number ownership place and type, comprising:
Step 1: judge whether bebinning character is "+": if then jump to step 2; If not, then jump to step 3;
Step 2: judge whether second and the 3rd be " 86 ", if, then remove number front three "+86 ", and get seven item segment informations, in cell-phone number segment information table, search information of home location, jump to step 8 then; If not, then "+" changed into " 00 ", and in international area code table, search area code information, jump to step 8 then;
Step 3: judge that whether number satisfies length is 1 greater than 13 and bebinning character,, jump to step 4 after removing the first five IP Number for access if then number is the IP Number for access; If not, then jump to step 4;
Step 4: whether judge number length greater than 6 and less than 9, if then the ownership place of this number is " local number "; If not, then jump to step 5;
Step 5: whether judge number length greater than 6, if then jump to step 6; If not, then search number information in the special service directory at home, and jump to step 8;
Step 6: judge whether initial number is 0, if then jump to step 7; If not, then get seven item segment informations, in cell-phone number segment information table, search information of home location, and jump to step 8;
Step 7: the numeral of judging the second item sign indicating number: if 0, then in international area code table, search area code information, jump to 8 then; If 1 or 2, then get three area codes, and search information of home location in the area code table at home, jump to 8 then; If other numerals are then got four area codes, and search information of home location in the area code table at home, jump to 8 then;
Step 8: judge whether number attribution information exists, if then obtain the information of home location and the Card Type of this number; If not, then the ownership place of this number is " unknown number ".
Preferred as technique scheme, said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone.
Preferred as technique scheme, said cell-phone number segment information table, international area code table, domestic area code table, domestic special service directory are stored in the portable terminal with text, in text file, are added with the different files head before the data of each table; And having file index, when in above-mentioned table, searching relevant information, traversal is stored in the data file in the portable terminal; Each file header is read in the array, and the comparison document head is searched the file at number place; Open this document, file index is read, find corresponding data field; The content of data field is read internal memory, carry out binary chop, find and promptly obtain corresponding information behind the number.
A kind of portable terminal comprises:
Telephone number is handled and the ownership place enquiry module, is used for extracting telephone number and obtains the information of home location and the Card Type of this telephone number according to any described method of claim 1-3;
The incoming call interface module is used on the incoming call window of portable terminal, showing the information of home location and the Card Type of caller ID, caller ID.
Preferred as technique scheme also comprises the electric interface module, be used for portable terminal go show information of home location and the Card Type that removes electric number, removes electric number on the electric window.
Preferred as technique scheme, said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone.
Preferred as technique scheme, said portable terminal has the transmitting-receiving SMS.
Preferred as technique scheme; Also comprise and upgrade the short message module; When being used for the mobile phone users transmission or receiving note, be updated to outbox and inbox to the information of home location of the telephone number of recipient or transmit leg, said telephone number and Card Type.
Preferred as technique scheme also comprises the unread short messages module, is used for when the user has new information arrival, at the information of home location and the Card Type of the telephone number of message notifying frame display message transmit leg.
Preferred as technique scheme, said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone, Personal Handyphone System.
The enquiring telephone number information of home location that the present invention proposes and the method and apparatus of Card Type; When the user has incoming call, dialing or transmitting-receiving new information; Portable terminal (for example mobile phone) can show the information of home location and the Card Type of the other side's telephone number; And information of home location is updated in user's the message registration and note record, has made things convenient for user's inquiry and use.
Below in conjunction with accompanying drawing, specific embodiments of the invention is done further to specify.For the person of ordinary skill in the field, from detailed description of the invention, above-mentioned and other purposes of the present invention, feature and advantage will be obvious.
Description of drawings
The sketch map of first preferred embodiment of the enquiring telephone number information of home location that Fig. 1 proposes for the present invention and the method for Card Type.
Embodiment
First preferred embodiment of the enquiring telephone number information of home location that below proposes for the present invention and the method for Card Type, as shown in Figure 1, comprising:
Step 1: judge whether bebinning character is "+": if then jump to step 2; If not, then jump to step 3;
Step 2: judge whether second and the 3rd be " 86 ", if, then remove number front three "+86 ", and get seven item segment informations, in cell-phone number segment information table, search information of home location, jump to step 8 then; If not, then "+" changed into " 00 ", and in international area code table, search area code information, jump to step 8 then;
Step 3: judge that whether number satisfies length is 1 greater than 13 and bebinning character,, jump to step 4 after removing the first five IP Number for access if then number is the IP Number for access; If not, then jump to step 4;
Step 4: whether judge number length greater than 6 and less than 9, if then the information of home location of this number is " local number "; If not, then jump to step 5;
Step 5: whether judge number length greater than 6, if then jump to step 6; If not, then search number information in the special service directory at home, and jump to step 8;
Step 6: judge whether initial number is 0, if then jump to step 7; If not, then get seven item segment informations, in cell-phone number segment information table, search information of home location, and jump to step 8;
Step 7: the numeral of judging the second item sign indicating number: if 0, then in international area code table, search area code information, jump to 8 then; If 1 or 2, then get three area codes, and search information of home location in the area code table at home, jump to 8 then; If other numerals are then got four area codes, and search information of home location in the area code table at home, jump to 8 then;
Step 8: judge whether number attribution information exists, if then obtain the information of home location and the Card Type of this number; If not, then the information of home location of this number is " unknown number ".
Wherein, Card Type should mainly comprise: move card, UNICOM's card, telecommunications card and landline telephone.
In the above-described embodiments; Said cell-phone number segment information table, international area code table, domestic area code table, domestic special service directory are stored in the portable terminal with text; Be each table data just each number segment file formatd; In each number segment file, be added with the different files head, and data area structure body words, file index added.For example, file file (* .txt file) size is 10000 line items (domestic fixedly area codes with world segment file are less than 500 line items), with the * .txt document copying of each ten thousand line items formation to the mobile terminal stores card.
Sending a telegram here, remove electricity, when receiving and sending messages, in above-mentioned table, searching relevant informations such as information of home location and Card Type, concrete operations are:
Traversal is stored in the data file in the portable terminal, each file header is read in the array comparison document head; Search the file at number place, open this document, file index is read; Find corresponding data field; The content of data field is read internal memory, carry out binary chop, find and just obtain corresponding information behind the number.
A kind of first preferred embodiment of portable terminal, it has the module that realizes said method, and the information that this module is obtained shows.Particularly, include in this portable terminal:
Telephone number is handled and the ownership place enquiry module, is used to extract telephone number and obtains the information of home location and the Card Type of this telephone number according to said method; The transmission number of the short message that this telephone number can be caller ID, remove electric number, receive, send the other side's number of short message etc.;
The incoming call interface module is used on the incoming call window of portable terminal, showing the information of home location and the Card Type of caller ID, caller ID.
Wherein, Card Type mainly comprises: move card, UNICOM's card, telecommunications card, landline telephone.
For example:
For the mobile phone of double-card dual-standby, during incoming call, can be in the incoming information frame first row shows incoming call is SIM 1, or SIM 2;
Show the incoming call number at incoming information frame second row,, then show the title in the address list if caller ID is the number in the address list; Show homing address of calling number at incoming information frame the third line, and Card Type is to move card, UNICOM's card or telecommunications card;
If caller ID is landline telephone or Personal Handyphone System, and when having shown the incoming call area code, then show homing address of calling number information, and Card Type is shown as " landline telephone ";
If can't inquire the information of home location of number, then information of home location is shown as " unknown number ", and Card Type does not show;
If the caller is landline telephone or Personal Handyphone System, and belong to same ownership place with the side's that answers the call phone number, can not show caller's area code sometimes in the caller ID, then information of home location is shown as " local number ", and Card Type does not show;
If caller ID is an international number, then information of home location is shown as the incoming call country name, and Card Type does not show;
If caller ID is domestic special service number, then information of home location is shown as service name, and Card Type does not show.
The user can select the correspondent button of portable terminal to answer or refusing to receive telephone.Perhaps the user can select " option " in the portable terminal, and the calling system option page carries out other operations to incoming call.
The demonstration of number attribution information and Card Type probably is that before these information showed, information of home location was shown as " unknown number " in 3 seconds because need inquiry possibly need a period of time during this period of time in the present embodiment, and Card Type does not show.
Second preferred embodiment of the portable terminal that the present invention proposes is on the basis of first preferred embodiment, to have increased to go the electric interface module, be used for portable terminal go show information of home location and the Card Type that removes electric number, removes electric number on the electric window.
For example, for the mobile phone of double-card dual-standby, what go electrical information frame first row to show to remove electricity is SIM 1, or SIM 2.Go electrical information frame second row to show the telephone number that removes electricity,, then show the title in the address list if telephone number is kept in the address list.
Go electrical information frame the third line to show removing electric number attribution, Card Type is to move card, UNICOM's card or telecommunications card.If removing electric number is landline telephone or Personal Handy-phone System number, and have area code, then show institute's dialing sign indicating number information of home location, Card Type is shown as " landline telephone ".If institute's dialing sign indicating number is landline telephone or Personal Handyphone System, but be not with area code, then information of home location is shown as " local number ", and Card Type does not show.
If can't inquire the information of home location of electric number, then show " unknown number ".
If institute's dialing sign indicating number is an international number, then information of home location is shown as national title, and Card Type does not show.
If institute's dialing sign indicating number is domestic special service number, then information of home location is shown as service name, and Card Type does not show.
The user can hang up the telephone through the option of selecting portable terminal.Behind the closing of the circuit, the calling system call interface.
In number pulled out through journey, the demonstration of ownership place and Card Type needed a period of time, was within 3 seconds, and during this period of time, information of home location is shown as " unknown number ", and Card Type does not show.
In the 3rd preferred embodiment of the portable terminal that the present invention proposes; If this portable terminal has the mobile phone of SMS; This portable terminal also comprises renewal short message module; When being used for cellphone subscriber's transmission or receiving note, be updated to outbox and inbox to the information of home location of the telephone number of recipient or transmit leg, said telephone number and Card Type.
For example, show number attribution information behind the phone number of the short message in inbox, form is " 13412345678-Shenzhen "; If there is this number in the address list, then display format is " Zhang San-Shenzhen ".
Behind the phone number of the short message of outbox, show number attribution information, form is " 13412345678-Shenzhen "; If there is this number in the address list, then display format is " Zhang San-Shenzhen "; If the information in the outbox is that the user preserves, or does not send information of successful, then can need not to show information of home location behind the number.
If can't inquire the information of home location of phone number, show that then lattice are shown " 13412345678-unknown number "; If there is this number in the address list, then display format is " Zhang San-unknown number ".
Be positioned at information record when lasting when height is bright, do not show as if delegation, then this information of roll display.
In the 4th preferred embodiment of the portable terminal that the present invention proposes, also comprise the unread short messages module, be used for when the user has new information arrival, at the information of home location and the Card Type of the telephone number of message notifying frame display message transmit leg.
For example, for double card double standby mobile phone, message notifying frame first row shows that receiving new information is SIM 1, or SIM 2.The message notifying frame second row display message transmit leg phone number if telephone number is kept in the address list, then shows the title in the address list.Message notifying frame the third line display message transmit leg home zone of mobile phone number, Card Type are to move card, UNICOM's card or telecommunications card.
If information is from Personal Handyphone System, then Card Type shows " Personal Handyphone System ".
If information is from international number, then ownership place shows national title, and Card Type does not show.
The program search segment information needs the time, and the time is within 3 seconds, and during this period of time, information of home location is shown as " unknown number ", and Card Type does not show.
If the information that information is sent from Fetion, then information of home location shows the home zone of mobile phone number information of transmit leg, and Card Type shows " moving ", and the phone number form that Fetion sends is: the 12520+ phone number.
If can't inquire home zone of mobile phone number information, then show " unknown number ".
Do not show as if ownership place and Card Type information delegation, then roll display.
The user can carry out corresponding short message reading operation and return.
In third and fourth preferred embodiment, Card Type comprises: move card, UNICOM's card, telecommunications card and Personal Handyphone System.
Though; The present invention clearly demonstrates through above embodiment and accompanying drawing thereof; Yet under the situation that does not deviate from spirit of the present invention and essence thereof; The person of ordinary skill in the field works as can make various corresponding variations and correction according to the present invention, but these corresponding variations and correction all should belong to the protection range of claim of the present invention.
Claims (10)
1. the method for enquiring telephone number ownership place and type is characterized in that, comprising:
Step 1: judge whether bebinning character is "+": if then jump to step 2; If not, then jump to step 3;
Step 2: judge whether second and the 3rd be " 86 ", if, then remove number front three "+86 ", and get seven item segment informations, in cell-phone number segment information table, search information of home location, jump to step 8 then; If not, then "+" changed into " 00 ", and in international area code table, search area code information, jump to step 8 then;
Step 3: judge that whether number satisfies length is 1 greater than 13 and bebinning character,, jump to step 4 after removing the first five IP Number for access if then number is the IP Number for access; If not, then jump to step 4;
Step 4: whether judge number length greater than 6 and less than 9, if then the ownership place of this number is " local number "; If not, then jump to step 5;
Step 5: whether judge number length greater than 6, if then jump to step 6; If not, then search number information in the special service directory at home, and jump to step 8;
Step 6: judge whether initial number is 0, if then jump to step 7; If not, then get seven item segment informations, in cell-phone number segment information table, search information of home location, and jump to step 8;
Step 7: the numeral of judging the second item sign indicating number: if 0, then in international area code table, search area code information, jump to 8 then; If 1 or 2, then get three area codes, and search information of home location in the area code table at home, jump to 8 then; If other numerals are then got four area codes, and search information of home location in the area code table at home, jump to 8 then;
Step 8: judge whether number attribution information exists, if then obtain the information of home location and the Card Type of this number; If not, then the ownership place of this number is " unknown number ";
Above-mentioned steps 1 to step 8 handles through telephone number and the ownership place enquiry module is realized.
2. method according to claim 1 is characterized in that, said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone.
3. method according to claim 2 is characterized in that, said cell-phone number segment information table, international area code table, domestic area code table, domestic special service directory are stored in the portable terminal with text; In text file, be added with the different files head before the data of each table, and have file index; When in above-mentioned table, searching relevant information, traversal is stored in the data file in the portable terminal, and each file header is read in the array; The comparison document head is searched the file at number place, opens this document; File index is read, find corresponding data field, the content of data field is read internal memory; Carry out binary chop, find and promptly obtain corresponding information behind the number.
4. a portable terminal is characterized in that, comprising:
Telephone number is handled and the ownership place enquiry module, is used for extracting telephone number and obtains the information of home location and the Card Type of this telephone number according to any described method of claim 1-3;
The incoming call interface module is used on the incoming call window of portable terminal, showing the information of home location and the Card Type of caller ID, caller ID.
5. portable terminal according to claim 4 is characterized in that, also comprises the electric interface module, is used for removing on the electric window to show information of home location and the Card Type that removes electric number, removes electric number at portable terminal.
6. portable terminal according to claim 5 is characterized in that, said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone.
7. portable terminal according to claim 5 is characterized in that said portable terminal has the transmitting-receiving SMS.
8. portable terminal according to claim 7; It is characterized in that; Also comprise and upgrade the short message module; When being used for the mobile phone users transmission or receiving note, be updated to outbox and inbox to the information of home location of the telephone number of recipient or transmit leg, said telephone number and Card Type.
9. portable terminal according to claim 8 is characterized in that, also comprises the unread short messages module, is used for when the user has new information to arrive, at the information of home location and the Card Type of the telephone number of message notifying frame display message transmit leg.
10. according to Claim 8 or 9 described portable terminals, it is characterized in that said Card Type comprises: move card, UNICOM's card, telecommunications card, landline telephone, Personal Handyphone System.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101396900A CN101808161B (en) | 2010-03-24 | 2010-03-24 | Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101396900A CN101808161B (en) | 2010-03-24 | 2010-03-24 | Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101808161A CN101808161A (en) | 2010-08-18 |
CN101808161B true CN101808161B (en) | 2012-09-05 |
Family
ID=42609776
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2010101396900A Expired - Fee Related CN101808161B (en) | 2010-03-24 | 2010-03-24 | Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101808161B (en) |
Families Citing this family (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102917341B (en) * | 2012-09-26 | 2019-10-25 | 贵阳朗玛信息技术股份有限公司 | The storage of mobile phone and its cell-phone number attaching information and lookup method |
CN104253894A (en) * | 2013-06-25 | 2014-12-31 | 富泰华工业(深圳)有限公司 | Incoming call prompt system and method |
CN105791605B (en) * | 2014-12-25 | 2021-03-26 | 北京奇虎科技有限公司 | Number information query method and device |
CN109510902B (en) * | 2015-06-15 | 2021-07-23 | 北京奇虎科技有限公司 | Method and device for information interaction between calling parties |
CN105721680B (en) * | 2016-01-21 | 2019-05-10 | 青岛海信移动通信技术股份有限公司 | A kind of processing method and processing device of short message session |
CN108600972A (en) * | 2018-04-26 | 2018-09-28 | 南通大学 | SMS possession is analyzed and method for visualizing |
CN111836249B (en) * | 2020-06-29 | 2023-04-21 | 广州三星通信技术研究有限公司 | Method and equipment for determining attribution of telephone number for electronic terminal |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101076050A (en) * | 2006-06-12 | 2007-11-21 | 腾讯科技(深圳)有限公司 | Access terminal and method for inquiring telephone-number atribute in access terminal |
CN101409878A (en) * | 2008-11-21 | 2009-04-15 | 闻泰集团有限公司 | Information block for telephone number dependency name and method for querying dependency of incoming call |
-
2010
- 2010-03-24 CN CN2010101396900A patent/CN101808161B/en not_active Expired - Fee Related
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101076050A (en) * | 2006-06-12 | 2007-11-21 | 腾讯科技(深圳)有限公司 | Access terminal and method for inquiring telephone-number atribute in access terminal |
CN101409878A (en) * | 2008-11-21 | 2009-04-15 | 闻泰集团有限公司 | Information block for telephone number dependency name and method for querying dependency of incoming call |
Also Published As
Publication number | Publication date |
---|---|
CN101808161A (en) | 2010-08-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101808161B (en) | Method and device for inquiring area to which phone number is attributed and type of SIM card for phone number | |
CN101304575B (en) | Method and communication terminal capable of automatically matching incoming call number or note number | |
CN102447771B (en) | The method of display caller information and the communication terminal of application the method | |
CN101909118B (en) | Method for setting short message prompt tones of mobile communication terminal | |
CN101640727A (en) | Method and terminal for intelligent dialing | |
CN101179619A (en) | Mobile phone and automatic answer method thereof | |
EP1686773A3 (en) | Mobile terminal for performing call and method therefor | |
CN101577761A (en) | Mobile terminal and method for inquiring and adding information of telephone number in short message thereof | |
CN104602242A (en) | Method and device for preventing voice phishing | |
CN102625001A (en) | System and method for acquiring weather situation of home location of calling/called party based on cell phone communication | |
CN102427495A (en) | Mobile terminal, number storage method and apparatus thereof | |
CN103118162B (en) | A kind of method of automatic display of calling information on called mobile phone | |
CN101351000A (en) | Method for showing information and communication terminal | |
CN103209249A (en) | Method and system for providing communication records in mobile communication terminal | |
CN101521705A (en) | System and method for realizing communication based on on-line telephone book mode | |
CN101674371A (en) | Method and device for processing phone numbers in short messages | |
JP2004178294A (en) | Mobile terminal displaying related e-mail, method of displaying e-mail, and program | |
CN103249016A (en) | Method and device for displaying short message and mobile terminal | |
CN104378489A (en) | Information display method and device based on missed call | |
CN103533150A (en) | Method and device for sending electronic business card | |
CN101022574A (en) | Method for changing MMS to speech | |
CN102769688A (en) | Display method for telephone numbers and mobile terminal | |
CN101977258A (en) | Method for storing mobile phone numbers and system thereof | |
CN101951596A (en) | Method and system for importing information of mobile communication terminal | |
CN101662522A (en) | Method for dialing fixed telephone number in short message and terminal thereof |
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 | ||
C17 | Cessation of patent right | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20120905 Termination date: 20140324 |