WO2015117407A1 - Processing method and device for terminal information - Google Patents

Processing method and device for terminal information Download PDF

Info

Publication number
WO2015117407A1
WO2015117407A1 PCT/CN2014/089393 CN2014089393W WO2015117407A1 WO 2015117407 A1 WO2015117407 A1 WO 2015117407A1 CN 2014089393 W CN2014089393 W CN 2014089393W WO 2015117407 A1 WO2015117407 A1 WO 2015117407A1
Authority
WO
WIPO (PCT)
Prior art keywords
information
decoding
mode
encoding
character
Prior art date
Application number
PCT/CN2014/089393
Other languages
French (fr)
Chinese (zh)
Inventor
贾鑫
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2015117407A1 publication Critical patent/WO2015117407A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/12Messaging; Mailboxes; Announcements
    • H04W4/14Short messaging services, e.g. short message services [SMS] or unstructured supplementary service data [USSD]

Definitions

  • the present invention relates to the field of communications, and in particular, to a method and an apparatus for processing terminal information.
  • PDU Protocol Data Unit
  • SMS Short Message Service
  • 3 types of encoding can be used in the PDU Mode to encode the transmitted content. They are 7-bit, 8-bit, and USC2 encoded. 7-bit encoding is used to send ordinary ASCII characters. It converts 8-bit ASCII encoding (American Standard Code for Information Interchange) (highest bit is 0) into 7-bit encoding, ie every 8 characters can be compressed. Into seven.
  • Bit8 of the ASCII 8-bit code is removed, and the next few bits of the next 7-bit code are sequentially moved to the front to form a new 8-bit code.
  • UCS2 encoding is used to send Unicode characters.
  • the maximum size of the user information segment of the PDU string is 140 bytes, so the maximum number of short messages that can be sent in the three coding modes is 160, 140, and 70, respectively.
  • the 7-bit encoding method is adopted, so that the length of each short message can be up to 160 characters, and for the short message containing Chinese characters, only USC2 encoding can be used, and the length of one short message is reduced to 70 characters. If the content of the short message is greater than 70 characters, it can only be split into multiple transmissions. This method increases the number of short messages sent, and correspondingly increases the communication cost, which also imposes a burden on the service provider.
  • the embodiment of the invention provides a method and a device for processing terminal information, so as to at least solve the problem of a relatively simple information coding mode in the related art.
  • a method for processing terminal information includes: determining a type of information to be processed; and selecting a single coding mode or a hybrid coding mode from a preset plurality of coding modes according to the type, The processing information is encoded; and the encoded information to be processed is processed.
  • the selecting the single coding mode or the hybrid coding mode according to the type, and encoding the processing information includes: when determining that the type is a combination of multiple content types, adopting a hybrid coding manner to The to-be-processed information of the content type is encoded to obtain a first number of encoded bytes; and the to-be-processed information combined by the plurality of content types is encoded by a single encoding manner to obtain a a number of two encoded bytes; comparing the number of the first encoded bytes and the number of the second encoded bytes, determining an encoding mode corresponding to the number of less encoded bytes; using the determined encoding manner to process the information Encode.
  • the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: the USC2 coding mode and the 7-bit A hybrid coding method in which a bit coding method is combined, a hybrid coding method in which the USC2 coding method and an 8-bit coding method are combined.
  • the to-be-processed information that is combined by the multiple content types is encoded by using a hybrid coding manner, and the number of the first encoded bytes is obtained: when the type of the to-be-processed information is Chinese characters and ASCII.
  • the Chinese character in the information to be processed is encoded by using the USC2 coding mode in the hybrid coding mode; and the 7-bit or 8-bit coding mode in the hybrid coding mode is used.
  • the ASCII characters and the Chinese characters after encoding are encoded.
  • encoding the Chinese characters in the to-be-processed information by using the USC2 encoding manner in the hybrid encoding manner includes: adding a identifying character to the beginning and end of the character string obtained by encoding the Chinese character Different from other ASCII characters.
  • a method for processing terminal information including: determining a type of information to be processed; and selecting a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, Decoding the to-be-processed information; processing the decoded-to-be-supplied Information.
  • the determining the type of the information to be processed includes: identifying whether the to-be-processed information includes an identifier character, where the identifier character is used to indicate that the to-be-processed information includes a Chinese character.
  • the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, and a USC2 decoding mode;
  • the hybrid decoding mode includes one of the following: the USC2 decoding mode and the 7-bit A hybrid decoding method in which a bit decoding method is combined, a hybrid decoding method in which the USC2 decoding method and an 8-bit decoding method are combined.
  • the single decoding mode or the hybrid decoding mode is selected from the preset multiple decoding modes according to the type, and the to-be-processed information is decoded, including: determining that the to-be-processed information carries the identifier In the case of characters, the hybrid decoding mode is selected to decode the to-be-processed information.
  • selecting the hybrid decoding mode to decode the to-be-processed information including: decoding the to-be-processed information by using the 7-bit or 8-bit decoding manner, and obtaining the to-be-processed information corresponding to
  • the ASCII character is obtained by using the USC2 decoding mode to obtain the Chinese character carried in the ASCII character, and the character information carried by the ASCII character is obtained according to the ASCII comparison table, wherein the character information is composed of the Chinese character.
  • the ASCII character including: decoding the to-be-processed information by using the 7-bit or 8-bit decoding manner, and obtaining the to-be-processed information corresponding to
  • the ASCII character is obtained by using the USC2 decoding mode to obtain the Chinese character carried in the ASCII character, and the character information carried by the ASCII character is obtained according to the ASCII comparison table, wherein the character information is composed of the Chinese character.
  • the ASCII character including: decoding the to-be
  • a device for processing terminal information includes: a first determining module configured to determine a type of information to be processed; and an encoding module configured to preset a plurality of encodings according to the type The method selects a single coding mode or a hybrid coding mode, and encodes the processing information; and the processing module is configured to process the coded to-be-processed information.
  • the encoding module includes: a first encoding unit, configured to: when the determining that the type is a plurality of content type combinations, use the mixed encoding manner to combine the to-be-processed by the multiple content types
  • the information is encoded to obtain a first number of encoded bytes; and the to-be-processed information combined by the plurality of content types is encoded by a single encoding manner to obtain a second number of encoded bytes; and the comparing unit is set to Comparing the number of the first encoded bytes and the number of the second encoded bytes, determining an encoding mode corresponding to the number of less encoded bytes; and determining, configured to perform the processing information by using the determined encoding manner coding.
  • the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: the USC2 coding side.
  • a hybrid coding method in which a mixed coding method combined with the 7-bit coding method and the USC2 coding method and an 8-bit coding method are combined.
  • the first coding unit is further configured to: when the combination manner of the content type is a Chinese character and an ASCII character combination, use the USC2 coding mode in the hybrid coding mode to process information to be processed.
  • the Chinese characters are encoded; the ASCII characters and the Chinese characters after encoding are encoded by the 7-bit or 8-bit encoding in the hybrid encoding mode.
  • the first coding unit is further configured to add the identifier character to the beginning and end of the character string obtained by encoding the Chinese character in the USC2 encoding manner in the hybrid coding mode to distinguish it from other ASCII characters.
  • a device for processing terminal information includes: a second determining module configured to determine a type of information to be processed; and a decoding module configured to decode from a preset plurality of types according to the type In the mode, a single decoding mode or a hybrid decoding mode is selected, and the processing information is decoded; and the processing module is configured to process the decoded information to be processed.
  • the second determining module is further configured to: identify whether the information to be processed includes an identifier character indicating that the Chinese character is included in the information, and the identifier character is located at the beginning and the end of the encoded Chinese character.
  • the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, and a USC2 decoding mode;
  • the hybrid decoding mode includes one of the following: the USC2 decoding mode and the 7-bit A hybrid decoding method in which a bit decoding method is combined, a hybrid decoding method in which the USC2 decoding method and an 8-bit decoding method are combined.
  • the decoding module is further configured to: when determining that the to-be-processed information carries the identifier character, select the hybrid decoding mode to decode the to-be-processed information.
  • the decoding module is further configured to: when determining that the to-be-processed information carries the identifier character, decoding the to-be-processed information by using a hybrid decoding manner, including: using 7-bit or 8-bit
  • the decoding mode decodes the to-be-processed information to obtain an ASCII character corresponding to the to-be-processed information, and obtains the Chinese character carried in the ASCII character by using the USC2 decoding mode for the ASCII character, and obtains the Chinese character according to the ASCII comparison table.
  • the character information carried by the ASCII character wherein the character information and the Chinese character constitute the ASCII character.
  • the embodiment of the invention further provides a computer program and a carrier thereof, the computer program comprising program instructions, when the program instructions are executed by the terminal device, the encoding method of the terminal device can be implemented by the terminal device.
  • the embodiment of the invention further provides a computer program and a carrier thereof, the computer program comprising program instructions, when the program instruction is executed by the terminal device, the decoding method of the terminal device can be implemented by the terminal device.
  • the type of the information to be processed is determined; and the single encoding mode or the hybrid encoding mode is selected from the preset multiple encoding modes according to the type, and the processing information is encoded;
  • the to-be-processed information solves the problem of a relatively simple information coding method in the related art, thereby achieving the effect of improving the user experience.
  • FIG. 1 is a flowchart of a terminal information processing method according to an embodiment of the present invention.
  • FIG. 2 is a block diagram showing the structure of a terminal information processing apparatus according to an embodiment of the present invention.
  • FIG. 3 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention.
  • FIG. 4 is a flowchart of a terminal information processing method according to an embodiment of the present invention.
  • FIG. 5 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention.
  • FIG. 6 is a schematic diagram of codec decoding of a mobile terminal according to an embodiment of the present invention.
  • FIG. 7 is a flowchart of a method for encoding and decoding information of a mobile terminal according to an embodiment of the present invention.
  • FIG. 1 is a flowchart of a method for processing terminal information according to an embodiment of the present invention. As shown in FIG. 1, the method includes the following steps:
  • Step S102 determining the type of information to be processed
  • Step S104 Select a single coding mode or a hybrid coding mode from a preset plurality of coding modes according to the type, and encode the processing information.
  • Step S106 Processing the encoded information to be processed.
  • a single coding mode or a hybrid coding mode is selected according to a type according to a type, and the processing information is encoded, and the problem of a single information coding mode in the related technology is solved, thereby achieving Improve the user experience.
  • the single encoding mode or the hybrid encoding mode is selected according to the type, and the processing information is encoded, and when the determining type is a combination of multiple content types, the mixed encoding manner is used to combine the to-be-processed information composed of multiple content types.
  • the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: a combination of the USC2 coding mode and the 7-bit coding mode.
  • the information to be processed that is combined by the multiple content types is encoded by using a hybrid coding manner, and the number of the first encoded bytes is obtained: when the type of the information to be processed is a combination of Chinese characters and ASCII characters, the hybrid is adopted.
  • the USC2 coding mode in the coding mode encodes the Chinese characters in the information to be processed; the ASCII characters and the Chinese characters after the coding are encoded by the 7-bit or 8-bit coding mode in the hybrid coding mode.
  • the encoding of the Chinese characters in the processing information by using the USC2 encoding mode in the hybrid encoding mode includes: adding the identification characters at the beginning and the end of the character string obtained by encoding the Chinese characters to distinguish them from other ASCII characters.
  • An embodiment of the present invention further provides a device for processing terminal information, which is used to implement the foregoing embodiments, and details are not described herein.
  • the term "module” may implement a combination of software and/or hardware of a predetermined function.
  • the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is possible and constructed. Thought.
  • the device includes: a first determining module 22 configured to determine a type of information to be processed; and an encoding module 24 configured to The type selects a single coding mode or a hybrid coding mode from a plurality of preset coding modes to encode the processing information, and the processing module 26 is configured to process the coded to-be-processed information.
  • the encoding module 24 includes: a first encoding unit 242, configured to use when a determination type is a combination of multiple content types.
  • the hybrid coding method encodes the to-be-processed information composed of a plurality of content types to obtain the first number of encoded bytes, and encodes the to-be-processed information composed of the plurality of content types by using a single coding method to obtain the first The number of two encoded bytes; the comparing unit 244 is configured to compare the first number of encoded bytes and the second number of encoded bytes, and determine an encoding mode corresponding to the number of less encoded bytes; the determining unit 246 is configured to adopt the determined encoding The method encodes the processing information.
  • the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, or a USC2 coding mode;
  • the hybrid coding mode includes one of the following: a combination of a USC2 coding mode and a 7-bit coding mode.
  • the first coding unit 242 is further configured to: when the combination of the content type is a Chinese character and an ASCII character combination, use the USC2 coding mode in the hybrid coding mode to encode the Chinese character in the information to be processed;
  • the 7-bit or 8-bit encoding method in the hybrid encoding method encodes ASCII characters and Chinese characters after encoding.
  • the first encoding unit 242 is further configured to add the identifier character to the beginning and end of the character string obtained by encoding the Chinese character in the USC2 encoding manner in the hybrid encoding manner to distinguish it from other characters.
  • FIG. 4 is a flowchart of a terminal information processing method according to an embodiment of the present invention. As shown in FIG. 4, the method includes the following steps:
  • Step S402 determining the type of information to be processed
  • Step S404 Select a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, and decode the processing information;
  • Step S406 Processing the decoded information to be processed.
  • the coded information is decoded according to a manner in which a single decoding mode or a hybrid decoding mode is selected according to a type, and the processed information is decoded.
  • determining the type of the information to be processed includes: identifying whether the information to be processed includes an identifier character, where the identifier character is used to indicate that the information to be processed includes a Chinese character.
  • the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, or a USC2 decoding mode;
  • the hybrid decoding mode includes one of the following: a combination of a USC2 decoding mode and a 7-bit decoding mode.
  • the decoding method is a hybrid decoding method in which the USC2 decoding method and the 8-bit decoding method are combined.
  • the single decoding mode or the hybrid decoding mode is selected according to the type, and the processing information is decoded, including: when determining that the to-be-processed information carries the identifier character, selecting the hybrid decoding mode to be processed. The information is decoded.
  • the method for decoding the information to be processed is selected by the hybrid decoding mode, including: decoding the information to be processed by using a 7-bit or 8-bit decoding method, and obtaining an ASCII character corresponding to the information to be processed; and using the USC2 decoding method to obtain an ASCII character for the ASCII character.
  • the Chinese character carried in the character obtains the character information carried in the ASCII character according to the ASCII comparison table, wherein the character information and the Chinese character constitute an ASCII character.
  • FIG. 5 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention. As shown in FIG. 5, the method includes: a second determining module 52, configured to determine a type of information to be processed; and a decoding module 54 configured to Among the plurality of decoding modes, a single decoding mode or a hybrid decoding mode is selected to decode the processing information, and the processing module 56 is configured to process the decoded to-be-processed information.
  • a second determining module 52 configured to determine a type of information to be processed
  • a decoding module 54 configured to Among the plurality of decoding modes, a single decoding mode or a hybrid decoding mode is selected to decode the processing information
  • the processing module 56 is configured to process the decoded to-be-processed information.
  • the second determining module is further configured to: identify whether the information to be processed includes an identifier character indicating that the Chinese character is included in the information, and the identifier character is located at the beginning and the end of the encoded Chinese character.
  • the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, or a USC2 decoding mode;
  • the hybrid decoding mode includes one of the following: a USC2 decoding mode and a 7-bit decoding mode.
  • the decoding module 54 is further configured to: when determining that the to-be-processed information carries the identifier character, select the hybrid decoding mode to decode the processing information.
  • the decoding module 54 is further configured to: when determining that the to-be-processed information carries the identifier, the decoding of the information to be processed by using the hybrid decoding manner includes: decoding the information to be processed by using a 7-bit or 8-bit decoding manner, Obtaining the ASCII character corresponding to the information to be processed; using the USC2 decoding method to obtain the Chinese character carried in the ASCII character, and obtaining the non-Chinese character information carried in the ASCII character according to the ASCII comparison table, wherein the character information is Chinese characters form ASCII characters.
  • the preferred embodiment of the present invention provides an improved character adaptive coding method.
  • the invention of the preferred embodiment of the present invention is that when a user edits a short message, the terminal automatically determines the content of the short message to adopt the most economical coding scheme. If the content of the short message is all ASCII characters, the default 7-bit encoding is adopted; if the short message containing the Chinese characters and characters in the short message content is preprocessed, UCS2 encoding and ASCII encoding are respectively performed, and finally combined and then subjected to 7-bit compression encoding. The number of encoded bytes formed by the hybrid encoding is compared with the number of UCS2 encoded bytes used by the default terminal, and the terminal automatically selects the least number of bytes as the preferred encoding.
  • the preferred encoding is determined based on the content of the short message, and if all are ASCII characters, 7-bit encoding is employed. If there are Chinese characters and characters, there are two kinds of encoding possibilities: one of them requires a combination of UCS2 encoding and 7-bit encoding to form a mixed encoding. Chinese characters are pre-processed for UCS2 encoding, followed by 7-bit encoding along with other ASCII characters. In addition, the USC2 encoding is adopted by default.
  • the terminal adds a special character "#" before and after the character is converted to obtain the short message content "#converted character #" to be transmitted.
  • the preferred coding scheme is not only used for the short message module in the mobile, but also applicable to Other modules in the terminal that use character encoding schemes, such as MMS. String encoding is widely used in terminal communication.
  • the transmitting terminal sets the user information encoding mode (TP-DCS) in the PDU string for sending the short message, and if it is the UCS2 encoding, sets the 08 to the UCS2 encoding, and if it is the 7Bit encoding.
  • TP-DCS user information encoding mode
  • the receiver terminal decoding adopts a corresponding decoding scheme according to the user information encoding mode (TP-DCS) in the received PDU string, and 08 represents the UCS2 decoding mode. 00 is 7Bit coded.
  • Secondary decoding requires traversing the entire string.
  • UCS2 is decoded for the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol.
  • the preferred embodiment of the present invention further provides an information encoding and decoding apparatus, wherein the encoding apparatus comprises: an editing module configured to receive original characters input by a user; an encoding module configured to perform PDU encoding according to original characters; a comparison module, setting In order to calculate and compare the length of the encoded bytes after preprocessing of different schemes, the optimal coding scheme is finally determined.
  • the decoding device comprises: a display module, configured to output the user original character obtained by the interface; the decoding module is configured to perform PDU decoding according to the original character; and the determining module is configured to determine whether there is a special character after the first decoding and start secondary decoding. .
  • the editing module is visible to the user and belongs to a part of the terminal UI interaction, and the characters input by the user are passed to the encoding module for processing.
  • the encoding module uses four encoding methods to encode the transmitted content, which are 7-bit, 8-bit, USC2 encoding, and hybrid encoding.
  • ASCII is a coding specification used to represent English characters. Each ASCII character occupies 1 byte (8 bits). The 7-bit encoding converts 8-bit ASCII encoding (the highest bit is 0) into 7-bit encoding, that is, every 8 characters can be compressed into seven. Bit8 of the ASCII 8-bit code is removed, and the next few bits of the next 7-bit code are sequentially moved to the front to form a new 8-bit code.
  • UCS2 encoding is used for Unicode characters and is encoded with 2 bytes. Convert unicode encoding to UCS2 encoding. First of all, we know that UCS2 encoding converts a single character into a 16-bit wide character, that is, the unicode of this character is converted to hexadecimal, the upper two bits are complemented by 0, and the length of the string is 2-digit hexadecimal number, PDU mode. The length of the string is twice that of the original message. UCS2 encoding converts each character (1-2 bytes) into 16-bit Unicode according to ISO/IEC10646. Wide character. You can simply call the API function or look up the table to achieve encoding and decoding.
  • 8-bit encoding is usually used to send data messages, used to send and receive data messages, such as pictures or ring tones, ordinary text messages will not be used.
  • Hybrid coding if the content of the message contains Chinese character words, the pre-processing is performed, that is, the Chinese characters in the content are first converted into characters, and the single characters are converted into 16-bit wide characters, that is, the unicode of the character is converted into hexadecimal. And use the flag bit to distinguish it from other characters, and then send all characters (characters with Chinese character conversion) according to ASCII encoding and then send them using 7-bit compression encoding.
  • the comparison module is configured to compare the final byte lengths of different coding schemes, and if all are ASCII characters, the default 7-bit encoding is used, and the 7-bit encoded byte length is calculated; for the short message, the Chinese characters are also included.
  • UCS2 encoding and ASCII encoding are performed separately, and finally 7-bit compression encoding is performed.
  • the number of encoded bytes formed is compared with the number of UCS2 encoded bytes used by the default terminal, and the final terminal automatically selects Excellent coding scheme.
  • the receiving terminal decoding device is similar to the encoding device, and the receiving terminal performs decoding according to the setting of the user information encoding mode (TP-DCS) in the PDU string of the received short message, and if the UCS2 is decoded, the UCS2 decoding is started, if the 7Bit encoding is performed. Then, 7Bit decoding is started. After 7Bit decoding, it is necessary to determine whether there is a special character to determine whether secondary decoding is required, and if secondary decoding is required, UCS2 decoding for the converted character is started. That is, the characters converted by Chinese characters are decoded according to UCS2. Secondary decoding requires traversing the entire string. When a special symbol is encountered, UCS2 is decoded for the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol.
  • TP-DCS user information encoding mode
  • FIG. 6 is a schematic diagram of encoding and decoding information of a mobile terminal according to a preferred embodiment of the present invention, which is applied in a short message scenario.
  • A is a calling party mobile phone
  • B is a called party mobile phone.
  • the user edits a short message. If the content of the short message does not contain Chinese characters, no pre-processing is performed. The characters in the content are ASCII-encoded and then sent using 7-bit compression encoding. If the content of the short message contains Chinese characters, the pre-processing is performed first, that is, the Chinese characters in the content are first converted into characters, and the flag is distinguished from other characters, and then all characters (characters including Chinese characters converted) are used in accordance with ASCII encoding. Bit compression coding. The final number of encoded bytes is compared with the number of UCS2 encoded bytes used by the default terminal. The final terminal automatically selects the optimal coding scheme, assuming a hybrid coding scheme is employed.
  • the receiver After receiving the data packet, the receiver processes according to the inverse process of the sender code. If it is judged that the encoded data contains special characters, the first decoding is performed first, that is, 7-bit decoding, and hexadecimal ASCII characters are obtained, and then the hexadecimal ASCII characters are decoded second, and respectively obtained by UCS2 decoding. Chinese characters, using the ASCII comparison table to get the characters, that is, the original text messages sent by the sender. If it is judged that the encoded data does not contain special characters, it is processed according to the default decoding method.
  • FIG. 7 is a flowchart of a method for encoding and decoding information of a mobile terminal according to a preferred embodiment of the present invention, which is applied in a short message scenario.
  • the implementation architecture includes a user terminal, a communication network, and a short message center.
  • the user terminals include fixed phones, mobile phones, and other devices that can implement network interaction.
  • Communication networks include mobile telephone networks, fixed networks, and the Internet.
  • the user terminal system specifies a special symbol as # in order to distinguish between the original character and the Chinese character conversion character. As shown in FIG. 7, the method steps include:
  • Step S702 A new short message is input, and the short message content is input, and the content is assumed to be: “text message test123”.
  • Step S704 The system determines whether the content contains Chinese characters. If yes, step S706 is performed. If the Chinese characters are not included, then step S708 is performed.
  • Step S706 Pre-processing the Chinese characters in the short message content, specifically, traversing the short message content, if the Chinese character is encountered, the UCS2 encoding is performed, and each Chinese character is converted into a 2-byte character.
  • the Chinese characters “short” and “letter” are converted into “77ED” and “4FE1” according to the UCS2 code, and the original short message content "text test123” is converted into the string “4FE177EDtest123” after the traversal.
  • Add the special symbol # to the beginning and end of the conversion character, and the continuous Chinese character only needs to be added once.
  • the system adds the special character "#” before and after the "4FE177ED” string to get the short message content "#4FE177ED#test123" to be sent.
  • Step S708 Perform 7-bit encoding on the short message content.
  • the system encodes the string of “#4FE177ED#test123” into a string of “239AB118BBDD8AC411BD3CA7C76433” according to the 7-bit encoding mode.
  • Step S710 The comparison module compares the number of encoded bytes formed by the hybrid coding scheme with the number of encoded bytes that are UCS2 encoded by default, and the terminal automatically selects the minimum number of bytes scheme as the optimal coding scheme.
  • the number of encoded bytes formed by the hybrid coding scheme is 15 bytes, which is adopted by default.
  • the number of UCS2 encoded bytes is 18 bytes, and the final terminal automatically selects the hybrid coding optimal coding scheme, and sets the short message PDU string user information coding mode (TP-DCS) to 00 or 7Bit code.
  • TP-DCS short message PDU string user information coding mode
  • Step S712 A encapsulates the string into a short message data packet and sends it to B, and B receives the data packet sent by A.
  • Step S714 B performs 7-bit decoding on "239AB118BBDD8AC411BD3CA7C76433" to obtain a decoded character string "#4FE177ED#test123", and judges that the special character # is included, and then performs the second decoding, that is, traversing the character string and the special symbol # For comparison, if the same, the traversal is stopped and step S716 is performed, if not the same until the traversal is finished and the process proceeds to step S718.
  • Step S716 traversing the entire character string, and encountering the special symbol #, UCS2 decoding is performed on the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol.
  • the character string "4FE177ED" between the special symbols "#” is decoded into UCS2 as "SMS", and the other characters remain unchanged.
  • Step S718 The last obtained character string is the short message content sent by A.
  • the character string "text test123" obtained after two decodings is the actual short message content.
  • the number of sent short messages can be significantly reduced, thereby reducing the communication cost of the user, reducing the burden on the service provider, and improving the user experience.
  • modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device, such that they may be stored in a storage device by a computing device, or they may be fabricated into individual integrated circuit modules, or Multiple modules or steps are made into a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software.
  • the method and device for processing terminal information provided by the present invention first determines the type of information to be processed, and selects a single coding mode or a hybrid coding mode from a plurality of preset coding modes according to the type, and encodes and processes the processed information.
  • the encoded information to be processed solves the problem of a relatively simple information encoding method in the related art. For text messages containing Chinese characters, the number of messages sent can be significantly reduced, thereby reducing the communication cost of the user and improving the user experience.

Abstract

Provided are a processing method and device for terminal information. The method comprises: a type of information to be processed is determined; according to the type, a single encoding means or a mixed encoding means is selected from within a preset plurality of encoding means, and the information to be processed is encoded; the encoded information to be processed is processed. The present invention solves the problem in the relevant prior art of relatively singular information encoding means, thereby improving user experience.

Description

终端信息的处理方法及装置Terminal information processing method and device 技术领域Technical field
本发明涉及通信领域,具体而言,涉及一种终端信息的处理方法及装置。The present invention relates to the field of communications, and in particular, to a method and an apparatus for processing terminal information.
背景技术Background technique
随着科技的发展,目前对数据的处理方式是多种多样,就如手机短信而言,手机等移动终端发送短信一般采用PDU(Protocol Data Unit协议数据单元)字符串,在SMS(Short Message Service短信息服务)规范中,PDU Mode 中可以采用三种编码方式来对发送的内容进行编码,它们是7-bit、8-bit和USC2编码。7-bit编码用于发送普通的ASCII字符,它将8位ASCII编码(American Standard Code for Information Interchange美国信息交换标准代码)(最高位为0)转换为7位编码,即每8个字符可以压缩成7个。将ASCII8位编码的Bit8去掉,依次将下7位编码的后几位逐次移到前面,形成新的8位编码。而UCS2编码用于发送Unicode字符。PDU串的用户信息段最大容量是140字节,所以在3种编码方式下可以发送的短消息最大字符数分别是160、140和70。With the development of technology, the current data processing methods are various, such as mobile phone short messages, mobile phones and other mobile terminals generally use PDU (Protocol Data Unit) data string, SMS (Short Message Service) In the short message service specification, three types of encoding can be used in the PDU Mode to encode the transmitted content. They are 7-bit, 8-bit, and USC2 encoded. 7-bit encoding is used to send ordinary ASCII characters. It converts 8-bit ASCII encoding (American Standard Code for Information Interchange) (highest bit is 0) into 7-bit encoding, ie every 8 characters can be compressed. Into seven. Bit8 of the ASCII 8-bit code is removed, and the next few bits of the next 7-bit code are sequentially moved to the front to form a new 8-bit code. UCS2 encoding is used to send Unicode characters. The maximum size of the user information segment of the PDU string is 140 bytes, so the maximum number of short messages that can be sent in the three coding modes is 160, 140, and 70, respectively.
如果短信内容为英文符号或数字时采用7-bit编码方式,这样每条短信内容长度可达160个字符,而对于含有汉字的短信只能采用USC2编码,一条短信长度降低为70个字符。如果短信内容大于70个字符,只能拆分为多条发送,这种方式增加了短信的发送数量,相应的增加了通信费用,也给服务提供商带来了负担。If the content of the short message is English symbol or number, the 7-bit encoding method is adopted, so that the length of each short message can be up to 160 characters, and for the short message containing Chinese characters, only USC2 encoding can be used, and the length of one short message is reduced to 70 characters. If the content of the short message is greater than 70 characters, it can only be split into multiple transmissions. This method increases the number of short messages sent, and correspondingly increases the communication cost, which also imposes a burden on the service provider.
可见,现有技术中对数据的处理方式比较单一,而导致数据的处理方式不灵活。It can be seen that the processing method of the data in the prior art is relatively simple, and the processing method of the data is not flexible.
针对相关技术中对比较单一的信息编码方式的问题,目前尚未提出有效的解决方案。In view of the problem of relatively single information coding methods in the related art, no effective solution has been proposed yet.
发明内容 Summary of the invention
本发明实施例提供了一种终端信息的处理方法及装置,以至少解决相关技术中比较单一的信息编码方式的问题。The embodiment of the invention provides a method and a device for processing terminal information, so as to at least solve the problem of a relatively simple information coding mode in the related art.
根据本发明的一个方面,提供了一种终端信息的处理方法,包括:判断待处理信息的类型;根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述处理信息进行编码;处理编码后的所述待处理信息。According to an aspect of the present invention, a method for processing terminal information includes: determining a type of information to be processed; and selecting a single coding mode or a hybrid coding mode from a preset plurality of coding modes according to the type, The processing information is encoded; and the encoded information to be processed is processed.
可选地,所述根据所述类型选择单一编码方式或混合编码方式,对所述处理信息进行编码包括:在判定所述类型为多种内容类型组合时,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第二编码字节数量;比较所述第一编码字节数量和所述第二编码字节数量,确定较少编码字节数量所对应的编码方式;采用确定的所述编码方式对所述处理信息进行编码。Optionally, the selecting the single coding mode or the hybrid coding mode according to the type, and encoding the processing information includes: when determining that the type is a combination of multiple content types, adopting a hybrid coding manner to The to-be-processed information of the content type is encoded to obtain a first number of encoded bytes; and the to-be-processed information combined by the plurality of content types is encoded by a single encoding manner to obtain a a number of two encoded bytes; comparing the number of the first encoded bytes and the number of the second encoded bytes, determining an encoding mode corresponding to the number of less encoded bytes; using the determined encoding manner to process the information Encode.
可选地,所述单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式、USC2编码方式;所述混合编码方式包括以下之一:所述USC2编码方式与所述7-bit编码方式组合而成的混合编码方式、所述USC2编码方式与8-bit编码方式组合而成的混合编码方式。Optionally, the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: the USC2 coding mode and the 7-bit A hybrid coding method in which a bit coding method is combined, a hybrid coding method in which the USC2 coding method and an 8-bit coding method are combined.
可选地,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量包括:当所述待处理信息的类型为中文字符和ASCII字符组合时,采用所述混合编码方式中的所述USC2编码方式对所待处理信息中的中文字符进行编码;采用所述混合编码方式中的所述7-bit或8-bit编码方式对所述ASCII字符和编码之后的所述中文字符进行编码。Optionally, the to-be-processed information that is combined by the multiple content types is encoded by using a hybrid coding manner, and the number of the first encoded bytes is obtained: when the type of the to-be-processed information is Chinese characters and ASCII. When the characters are combined, the Chinese character in the information to be processed is encoded by using the USC2 coding mode in the hybrid coding mode; and the 7-bit or 8-bit coding mode in the hybrid coding mode is used. The ASCII characters and the Chinese characters after encoding are encoded.
可选地,采用所述混合编码方式中的所述USC2编码方式对所述待处理信息中的中文字符进行编码包括:在对所述中文字符进行编码后得到的字符串的首尾加入标识字符以区别于其它ASCII字符。Optionally, encoding the Chinese characters in the to-be-processed information by using the USC2 encoding manner in the hybrid encoding manner includes: adding a identifying character to the beginning and end of the character string obtained by encoding the Chinese character Different from other ASCII characters.
根据本发明的另一个方面,提供了一种终端信息的处理方法,包括:判断待处理信息的类型;根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述待处理信息进行解码;处理解码后的所述待处 理信息。According to another aspect of the present invention, a method for processing terminal information is provided, including: determining a type of information to be processed; and selecting a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, Decoding the to-be-processed information; processing the decoded-to-be-supplied Information.
可选地,所述判断待处理信息的类型包括:识别待处理信息中是否包含标识字符,该标识字符用于表示所述待处理信息中包括中文字符。Optionally, the determining the type of the information to be processed includes: identifying whether the to-be-processed information includes an identifier character, where the identifier character is used to indicate that the to-be-processed information includes a Chinese character.
可选地,所述单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式、USC2解码方式;所述混合解码方式包括以下之一:所述USC2解码方式与所述7-bit解码方式组合而成的混合解码方式、所述USC2解码方式与8-bit解码方式组合而成的混合解码方式。Optionally, the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, and a USC2 decoding mode; the hybrid decoding mode includes one of the following: the USC2 decoding mode and the 7-bit A hybrid decoding method in which a bit decoding method is combined, a hybrid decoding method in which the USC2 decoding method and an 8-bit decoding method are combined.
可选地,根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述待处理信息进行解码,包括:在判定所述待处理信息中携带有所述标识字符时,选择所述混合解码方式对所述待处理信息进行解码。Optionally, the single decoding mode or the hybrid decoding mode is selected from the preset multiple decoding modes according to the type, and the to-be-processed information is decoded, including: determining that the to-be-processed information carries the identifier In the case of characters, the hybrid decoding mode is selected to decode the to-be-processed information.
可选地,选择所述混合解码方式对所述待处理信息进行解码,包括:采用所述7-bit或8-bit解码方式对所述待处理信息进行解码,得到所述待处理信息对应的ASCII字符;对所述ASCII字符采用所述USC2解码方式得到所述ASCII字符中携带的中文字符,按照ASCII对照表得到所述ASCII字符携带的字符信息,其中,该字符信息与所述中文字符组成所述ASCII字符。Optionally, selecting the hybrid decoding mode to decode the to-be-processed information, including: decoding the to-be-processed information by using the 7-bit or 8-bit decoding manner, and obtaining the to-be-processed information corresponding to The ASCII character is obtained by using the USC2 decoding mode to obtain the Chinese character carried in the ASCII character, and the character information carried by the ASCII character is obtained according to the ASCII comparison table, wherein the character information is composed of the Chinese character. The ASCII character.
根据本发明的另一个方面,提供了一种终端信息的处理装置,包括:第一判断模块,设置为判断待处理信息的类型;编码模块,设置为根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述处理信息进行编码;处理模块,设置为处理编码后的所述待处理信息。According to another aspect of the present invention, a device for processing terminal information includes: a first determining module configured to determine a type of information to be processed; and an encoding module configured to preset a plurality of encodings according to the type The method selects a single coding mode or a hybrid coding mode, and encodes the processing information; and the processing module is configured to process the coded to-be-processed information.
可选地,所述编码模块包括:第一编码单元,设置为在判定所述类型为多种内容类型组合时,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第二编码字节数量;比较单元,设置为比较所述第一编码字节数量和所述第二编码字节数量,确定较少编码字节数量所对应的编码方式;确定单元,设置为采用确定的所述编码方式对所述处理信息进行编码。Optionally, the encoding module includes: a first encoding unit, configured to: when the determining that the type is a plurality of content type combinations, use the mixed encoding manner to combine the to-be-processed by the multiple content types The information is encoded to obtain a first number of encoded bytes; and the to-be-processed information combined by the plurality of content types is encoded by a single encoding manner to obtain a second number of encoded bytes; and the comparing unit is set to Comparing the number of the first encoded bytes and the number of the second encoded bytes, determining an encoding mode corresponding to the number of less encoded bytes; and determining, configured to perform the processing information by using the determined encoding manner coding.
可选地,所述单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式、USC2编码方式;所述混合编码方式包括以下之一:所述USC2编码方 式与所述7-bit编码方式组合而成的混合编码方式、所述USC2编码方式与8-bit编码方式组合而成的混合编码方式。Optionally, the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: the USC2 coding side. A hybrid coding method in which a mixed coding method combined with the 7-bit coding method and the USC2 coding method and an 8-bit coding method are combined.
可选地,所述第一编码单元还设置为,当所述内容类型的组合方式为中文字符和ASCII字符组合时,采用所述混合编码方式中的所述USC2编码方式对所待处理信息中的中文字符进行编码;采用所述混合编码方式中的所述7-bit或8-bit编码方式对所述ASCII字符和编码之后的所述中文字符进行编码。Optionally, the first coding unit is further configured to: when the combination manner of the content type is a Chinese character and an ASCII character combination, use the USC2 coding mode in the hybrid coding mode to process information to be processed. The Chinese characters are encoded; the ASCII characters and the Chinese characters after encoding are encoded by the 7-bit or 8-bit encoding in the hybrid encoding mode.
可选地,所述第一编码单元还设置为,在采用混合编码方式中的USC2编码方式对所述中文字符进行编码后得到的字符串的首尾加入标识字符以区别于其它ASCII字符。Optionally, the first coding unit is further configured to add the identifier character to the beginning and end of the character string obtained by encoding the Chinese character in the USC2 encoding manner in the hybrid coding mode to distinguish it from other ASCII characters.
根据本发明的另一个方面,提供了一种终端信息的处理装置,包括:第二判断模块,设置为判断待处理信息的类型;解码模块,设置为根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述处理信息进行解码;处理模块,设置为处理解码后的所述待处理信息。According to another aspect of the present invention, a device for processing terminal information includes: a second determining module configured to determine a type of information to be processed; and a decoding module configured to decode from a preset plurality of types according to the type In the mode, a single decoding mode or a hybrid decoding mode is selected, and the processing information is decoded; and the processing module is configured to process the decoded information to be processed.
可选地,所述第二判断模块还设置为,识别待处理信息中是否包含表示该信息中包括中文字符的标识字符,该标识字符位于编码后中文字符的首尾。Optionally, the second determining module is further configured to: identify whether the information to be processed includes an identifier character indicating that the Chinese character is included in the information, and the identifier character is located at the beginning and the end of the encoded Chinese character.
可选地,所述单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式、USC2解码方式;所述混合解码方式包括以下之一:所述USC2解码方式与所述7-bit解码方式组合而成的混合解码方式、所述USC2解码方式与8-bit解码方式组合而成的混合解码方式。Optionally, the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, and a USC2 decoding mode; the hybrid decoding mode includes one of the following: the USC2 decoding mode and the 7-bit A hybrid decoding method in which a bit decoding method is combined, a hybrid decoding method in which the USC2 decoding method and an 8-bit decoding method are combined.
可选地,所述解码模块还设置为,在判定所述待处理信息中携带有所述标识字符时,选择所述混合解码方式对所述待处理信息进行解码。Optionally, the decoding module is further configured to: when determining that the to-be-processed information carries the identifier character, select the hybrid decoding mode to decode the to-be-processed information.
可选地,所述解码模块还设置为,在判定所述待处理信息中携带有所述标识字符时,采用混合解码方式对所述待处理信息进行解码包括:采用7-bit或8-bit解码方式对所述待处理信息进行解码,得到所述待处理信息对应的ASCII字符;对所述ASCII字符采用所述USC2解码方式得到所述ASCII字符中携带的中文字符,按照ASCII对照表得到所述ASCII字符携带的字符信息,其中,该字符信息与所述中文字符组成所述ASCII字符。 Optionally, the decoding module is further configured to: when determining that the to-be-processed information carries the identifier character, decoding the to-be-processed information by using a hybrid decoding manner, including: using 7-bit or 8-bit The decoding mode decodes the to-be-processed information to obtain an ASCII character corresponding to the to-be-processed information, and obtains the Chinese character carried in the ASCII character by using the USC2 decoding mode for the ASCII character, and obtains the Chinese character according to the ASCII comparison table. The character information carried by the ASCII character, wherein the character information and the Chinese character constitute the ASCII character.
本发明实施例还提供一种计算机程序及其载体,该计算机程序包括程序指令,当该程序指令被终端设备执行时,使得该终端设备可实施上述终端信息的处理的编码方法。The embodiment of the invention further provides a computer program and a carrier thereof, the computer program comprising program instructions, when the program instructions are executed by the terminal device, the encoding method of the terminal device can be implemented by the terminal device.
本发明实施例还提供一种计算机程序及其载体,该计算机程序包括程序指令,当该程序指令被终端设备执行时,使得该终端设备可实施上述终端信息的处理的解码方法。The embodiment of the invention further provides a computer program and a carrier thereof, the computer program comprising program instructions, when the program instruction is executed by the terminal device, the decoding method of the terminal device can be implemented by the terminal device.
通过本发明实施例的技术方案,采用判断待处理信息的类型;根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述处理信息进行编码;处理编码后的所述待处理信息;解决了相关技术中比较单一的信息编码方式的问题,进而达到了提高用户体验的效果。According to the technical solution of the embodiment of the present invention, the type of the information to be processed is determined; and the single encoding mode or the hybrid encoding mode is selected from the preset multiple encoding modes according to the type, and the processing information is encoded; The to-be-processed information solves the problem of a relatively simple information coding method in the related art, thereby achieving the effect of improving the user experience.
附图概述BRIEF abstract
图1是根据本发明实施例的终端信息处理方法的流程图;1 is a flowchart of a terminal information processing method according to an embodiment of the present invention;
图2是根据本发明实施例的终端信息处理装置的结构框图;2 is a block diagram showing the structure of a terminal information processing apparatus according to an embodiment of the present invention;
图3是根据本发明实施例的终端信息处理装置的一种结构框图;FIG. 3 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention; FIG.
图4是根据本发明实施例的终端信息处理方法的流程图;4 is a flowchart of a terminal information processing method according to an embodiment of the present invention;
图5是根据本发明实施例的终端信息处理装置的结构框图;FIG. 5 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention; FIG.
图6是根据本发明实施例的移动终端信息编解码示意图;FIG. 6 is a schematic diagram of codec decoding of a mobile terminal according to an embodiment of the present invention; FIG.
图7是根据本发明实施例的移动终端信息编解码方法流程图。FIG. 7 is a flowchart of a method for encoding and decoding information of a mobile terminal according to an embodiment of the present invention.
本发明的较佳实施方式Preferred embodiment of the invention
下文中将结合附图对本发明的实施例进行详细说明。本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。本发明实施例提供了一种终端信息的处理方法,图1是根据本发明实施例的终端信息处理方法的流程图,如图1所示,包括如下的步骤:Embodiments of the present invention will be described in detail below with reference to the accompanying drawings. The illustrative embodiments of the present invention and the description thereof are intended to explain the present invention and are not intended to limit the invention. It should be noted that the embodiments in the present application and the features in the embodiments may be combined with each other without conflict. The embodiment of the present invention provides a method for processing terminal information. FIG. 1 is a flowchart of a method for processing terminal information according to an embodiment of the present invention. As shown in FIG. 1, the method includes the following steps:
步骤S102:判断待处理信息的类型; Step S102: determining the type of information to be processed;
步骤S104:根据类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对处理信息进行编码;Step S104: Select a single coding mode or a hybrid coding mode from a preset plurality of coding modes according to the type, and encode the processing information.
步骤S106:处理编码后的待处理信息。Step S106: Processing the encoded information to be processed.
通过本发明实施例,采用根据类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对处理信息进行编码方式,解决了相关技术中比较单一的信息编码方式的问题,进而达到了提高用户体验的效果。According to the embodiment of the present invention, a single coding mode or a hybrid coding mode is selected according to a type according to a type, and the processing information is encoded, and the problem of a single information coding mode in the related technology is solved, thereby achieving Improve the user experience.
可选地,根据类型选择单一编码方式或混合编码方式,对处理信息进行编码包括:在判定类型为多种内容类型组合时,采用混合编码方式对由多种内容类型组合而成的待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由多种内容类型组合而成的待处理信息进行编码,得到第二编码字节数量;比较第一编码字节数量和第二编码字节数量,确定较少编码字节数量所对应的编码方式;采用确定的编码方式对处理信息进行编码。Optionally, the single encoding mode or the hybrid encoding mode is selected according to the type, and the processing information is encoded, and when the determining type is a combination of multiple content types, the mixed encoding manner is used to combine the to-be-processed information composed of multiple content types. Encoding to obtain the first number of encoded bytes; and encoding a to-be-processed information composed of a plurality of content types by a single encoding method to obtain a second encoded byte number; comparing the first encoded byte number and the second The number of encoded bytes determines the encoding mode corresponding to the number of less encoded bytes; the processing information is encoded using the determined encoding method.
可选地,单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式、USC2编码方式;混合编码方式包括以下之一:USC2编码方式与7-bit编码方式组合而成的混合编码方式、USC2编码方式与8-bit编码方式组合而成的混合编码方式。Optionally, the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, and a USC2 coding mode; and the hybrid coding mode includes one of the following: a combination of the USC2 coding mode and the 7-bit coding mode. A hybrid coding method combining coding mode, USC2 coding mode and 8-bit coding mode.
可选地,采用混合编码方式对由多种内容类型组合而成的待处理信息进行编码,得到第一编码字节数量包括:当待处理信息的类型为中文字符和ASCII字符组合时,采用混合编码方式中的USC2编码方式对所待处理信息中的中文字符进行编码;采用混合编码方式中的7-bit或8-bit编码方式对ASCII字符和编码之后的中文字符进行编码。Optionally, the information to be processed that is combined by the multiple content types is encoded by using a hybrid coding manner, and the number of the first encoded bytes is obtained: when the type of the information to be processed is a combination of Chinese characters and ASCII characters, the hybrid is adopted. The USC2 coding mode in the coding mode encodes the Chinese characters in the information to be processed; the ASCII characters and the Chinese characters after the coding are encoded by the 7-bit or 8-bit coding mode in the hybrid coding mode.
可选地,采用混合编码方式中的USC2编码方式对待处理信息中的中文字符进行编码包括:在对中文字符进行编码后得到的字符串的首尾加入标识字符以区别于其它ASCII字符。Optionally, the encoding of the Chinese characters in the processing information by using the USC2 encoding mode in the hybrid encoding mode includes: adding the identification characters at the beginning and the end of the character string obtained by encoding the Chinese characters to distinguish them from other ASCII characters.
本发明的实施例还提供了一种终端信息的处理装置,该装置用于实现上述实施例,已经进行过说明的不再赘述。如以下所使用的,术语“模块”可以实现预定功能的软件和/或硬件的组合。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构 想的。An embodiment of the present invention further provides a device for processing terminal information, which is used to implement the foregoing embodiments, and details are not described herein. As used below, the term "module" may implement a combination of software and/or hardware of a predetermined function. Although the apparatus described in the following embodiments is preferably implemented in software, hardware, or a combination of software and hardware, is possible and constructed. Thought.
图2是根据本发明实施例的终端信息的处理装置的结构框图,如图2所示,该装置包括:第一判断模块22,设置为判断待处理信息的类型;编码模块24,设置为根据类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对处理信息进行编码;处理模块26,设置为处理编码后的待处理信息。2 is a structural block diagram of a device for processing terminal information according to an embodiment of the present invention. As shown in FIG. 2, the device includes: a first determining module 22 configured to determine a type of information to be processed; and an encoding module 24 configured to The type selects a single coding mode or a hybrid coding mode from a plurality of preset coding modes to encode the processing information, and the processing module 26 is configured to process the coded to-be-processed information.
图3是根据本发明实施例终端信息的处理装置的一种较佳结构框图,如图3,编码模块24包括:第一编码单元242,设置为在判定类型为多种内容类型组合时,采用混合编码方式对由多种内容类型组合而成的待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由多种内容类型组合而成的待处理信息进行编码,得到第二编码字节数量;比较单元244,设置为比较第一编码字节数量和第二编码字节数量,确定较少编码字节数量所对应的编码方式;确定单元246,设置为采用确定的编码方式对处理信息进行编码。3 is a block diagram of a preferred structure of a device for processing terminal information according to an embodiment of the present invention. As shown in FIG. 3, the encoding module 24 includes: a first encoding unit 242, configured to use when a determination type is a combination of multiple content types. The hybrid coding method encodes the to-be-processed information composed of a plurality of content types to obtain the first number of encoded bytes, and encodes the to-be-processed information composed of the plurality of content types by using a single coding method to obtain the first The number of two encoded bytes; the comparing unit 244 is configured to compare the first number of encoded bytes and the second number of encoded bytes, and determine an encoding mode corresponding to the number of less encoded bytes; the determining unit 246 is configured to adopt the determined encoding The method encodes the processing information.
可选地,单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式或USC2编码方式;混合编码方式包括以下之一:USC2编码方式与7-bit编码方式组合而成的混合编码方式或USC2编码方式与8-bit编码方式组合而成的混合编码方式。Optionally, the single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, or a USC2 coding mode; the hybrid coding mode includes one of the following: a combination of a USC2 coding mode and a 7-bit coding mode. A coding method or a combination of the USC2 coding method and the 8-bit coding method.
可选地,第一编码单元242还设置为,当内容类型的组合方式为中文字符和ASCII字符组合时,采用混合编码方式中的USC2编码方式对所待处理信息中的中文字符进行编码;采用混合编码方式中的7-bit或8-bit编码方式对ASCII字符和编码之后的中文字符进行编码。Optionally, the first coding unit 242 is further configured to: when the combination of the content type is a Chinese character and an ASCII character combination, use the USC2 coding mode in the hybrid coding mode to encode the Chinese character in the information to be processed; The 7-bit or 8-bit encoding method in the hybrid encoding method encodes ASCII characters and Chinese characters after encoding.
可选地,第一编码单元242还设置为,在采用混合编码方式中的USC2编码方式对中文字符进行编码后得到的字符串的首尾加入标识字符以区别于其它字符。Optionally, the first encoding unit 242 is further configured to add the identifier character to the beginning and end of the character string obtained by encoding the Chinese character in the USC2 encoding manner in the hybrid encoding manner to distinguish it from other characters.
本发明实施例还提供了一种终端信息的处理方法,图4是根据本发明实施例的终端信息处理方法的流程图,如图4所示,包括如下的步骤:The embodiment of the present invention further provides a method for processing terminal information. FIG. 4 is a flowchart of a terminal information processing method according to an embodiment of the present invention. As shown in FIG. 4, the method includes the following steps:
步骤S402:判断待处理信息的类型; Step S402: determining the type of information to be processed;
步骤S404:根据类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对待处理信息进行解码;Step S404: Select a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, and decode the processing information;
步骤S406:处理解码后的待处理信息。Step S406: Processing the decoded information to be processed.
通过本发明实施例,采用根据类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对待处理信息进行解码的方式,对上述编码后的信息进行了相应的解码。According to the embodiment of the present invention, the coded information is decoded according to a manner in which a single decoding mode or a hybrid decoding mode is selected according to a type, and the processed information is decoded.
可选地,判断待处理信息的类型包括:识别待处理信息中是否包含标识字符,该标识字符用于表示待处理信息中包括中文字符。Optionally, determining the type of the information to be processed includes: identifying whether the information to be processed includes an identifier character, where the identifier character is used to indicate that the information to be processed includes a Chinese character.
可选地,单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式或USC2解码方式;混合解码方式包括以下之一:USC2解码方式与7-bit解码方式组合而成的混合解码方式或USC2解码方式与8-bit解码方式组合而成的混合解码方式。Optionally, the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, or a USC2 decoding mode; the hybrid decoding mode includes one of the following: a combination of a USC2 decoding mode and a 7-bit decoding mode. The decoding method is a hybrid decoding method in which the USC2 decoding method and the 8-bit decoding method are combined.
可选地,根据类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对待处理信息进行解码,包括:在判定待处理信息中携带有标识字符时,选择混合解码方式对待处理信息进行解码。Optionally, the single decoding mode or the hybrid decoding mode is selected according to the type, and the processing information is decoded, including: when determining that the to-be-processed information carries the identifier character, selecting the hybrid decoding mode to be processed. The information is decoded.
可选地,选择混合解码方式对待处理信息进行解码,包括:采用7-bit或8-bit解码方式对待处理信息进行解码,得到待处理信息对应的ASCII字符;对ASCII字符采用USC2解码方式得到ASCII字符中携带的中文字符,按照ASCII对照表得到ASCII字符中携带的字符信息,其中,所述字符信息与所述中文字符组成ASCII字符。Optionally, the method for decoding the information to be processed is selected by the hybrid decoding mode, including: decoding the information to be processed by using a 7-bit or 8-bit decoding method, and obtaining an ASCII character corresponding to the information to be processed; and using the USC2 decoding method to obtain an ASCII character for the ASCII character. The Chinese character carried in the character obtains the character information carried in the ASCII character according to the ASCII comparison table, wherein the character information and the Chinese character constitute an ASCII character.
图5是根据本发明实施例的终端信息处理装置的结构框图,如图5所示,包括:第二判断模块52,设置为判断待处理信息的类型;解码模块54,设置为根据类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对处理信息进行解码;处理模块56,设置为处理解码后的待处理信息。FIG. 5 is a structural block diagram of a terminal information processing apparatus according to an embodiment of the present invention. As shown in FIG. 5, the method includes: a second determining module 52, configured to determine a type of information to be processed; and a decoding module 54 configured to Among the plurality of decoding modes, a single decoding mode or a hybrid decoding mode is selected to decode the processing information, and the processing module 56 is configured to process the decoded to-be-processed information.
可选地,第二判断模块还设置为,识别待处理信息中是否包含表示该信息中包括中文字符的标识字符,该标识字符位于编码后中文字符的首尾。Optionally, the second determining module is further configured to: identify whether the information to be processed includes an identifier character indicating that the Chinese character is included in the information, and the identifier character is located at the beginning and the end of the encoded Chinese character.
可选地,单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式或USC2解码方式;混合解码方式包括以下之一:USC2解码方式与7-bit解码 方式组合而成的混合解码方式或USC2解码方式与8-bit解码方式组合而成的混合解码方式。Optionally, the single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, or a USC2 decoding mode; the hybrid decoding mode includes one of the following: a USC2 decoding mode and a 7-bit decoding mode. A hybrid decoding method in which a combination of modes is combined, or a hybrid decoding method in which a USC2 decoding method and an 8-bit decoding method are combined.
可选地,解码模块54还设置为,在判定待处理信息中携带有标识字符时,选择混合解码方式对待处理信息进行解码。Optionally, the decoding module 54 is further configured to: when determining that the to-be-processed information carries the identifier character, select the hybrid decoding mode to decode the processing information.
可选地,解码模块54还设置为,在判定待处理信息中携带有标识字符时,采用混合解码方式对待处理信息进行解码包括:采用7-bit或8-bit解码方式对待处理信息进行解码,得到待处理信息对应的ASCII字符;对ASCII字符采用USC2解码方式得到ASCII字符中携带的中文字符,按照ASCII对照表得到ASCII字符中携带的非中文的字符信息,其中,所述字符信息与所述中文字符组成ASCII字符。Optionally, the decoding module 54 is further configured to: when determining that the to-be-processed information carries the identifier, the decoding of the information to be processed by using the hybrid decoding manner includes: decoding the information to be processed by using a 7-bit or 8-bit decoding manner, Obtaining the ASCII character corresponding to the information to be processed; using the USC2 decoding method to obtain the Chinese character carried in the ASCII character, and obtaining the non-Chinese character information carried in the ASCII character according to the ASCII comparison table, wherein the character information is Chinese characters form ASCII characters.
为了使本发明的技术方案和实现方法更加清楚,下面将结合本发明的较佳实施例对其实现过程进行详细描述。In order to make the technical solutions and implementation methods of the present invention clearer, the implementation process will be described in detail below in conjunction with the preferred embodiments of the present invention.
本发明较佳实施例提供了一种改进的字符自适应编码方法,本发明较佳实施例的发明思想为:用户在编辑短信时,终端会自动判断短信内容从而采用最节省的编码方案,如果短信内容全部为ASCII字符则采用默认的7-bit编码;如果短信内容中同时含有汉字和字符的短信则进行预处理后分别进行UCS2编码和ASCII编码,最后合并起来再进行7-bit压缩编码。将混合编码最后形成的编码字节数量和默认终端采用的UCS2编码字节数量进行比较,终端自动选择字节数最少的作为优选的编码方式。The preferred embodiment of the present invention provides an improved character adaptive coding method. The invention of the preferred embodiment of the present invention is that when a user edits a short message, the terminal automatically determines the content of the short message to adopt the most economical coding scheme. If the content of the short message is all ASCII characters, the default 7-bit encoding is adopted; if the short message containing the Chinese characters and characters in the short message content is preprocessed, UCS2 encoding and ASCII encoding are respectively performed, and finally combined and then subjected to 7-bit compression encoding. The number of encoded bytes formed by the hybrid encoding is compared with the number of UCS2 encoded bytes used by the default terminal, and the terminal automatically selects the least number of bytes as the preferred encoding.
在本发明的较佳实施例中,优选的编码方式是根据短信内容确定的,如果全部是ASCII字符则采用7-bit编码。如果含有中文和字符,则有两种编码可能:其中一种,需要UCS2编码和7-bit编码组合而成混合编码。先将中文字符进行预处理进行UCS2编码,之后在连同其它ASCII字符一起进行7-bit编码。另外一种,采用默认采用USC2编码。In a preferred embodiment of the invention, the preferred encoding is determined based on the content of the short message, and if all are ASCII characters, 7-bit encoding is employed. If there are Chinese characters and characters, there are two kinds of encoding possibilities: one of them requires a combination of UCS2 encoding and 7-bit encoding to form a mixed encoding. Chinese characters are pre-processed for UCS2 encoding, followed by 7-bit encoding along with other ASCII characters. In addition, the USC2 encoding is adopted by default.
在本发明较佳实施例的混合编码方案中,需要将特殊符号加入转换字符的首尾,连续中文只需添加一次。在本发明较佳实施例中,终端在转换字符前后加上特殊字符“#”从而得到要发送的短信内容“#转换字符#”。In the hybrid coding scheme of the preferred embodiment of the present invention, special symbols need to be added to the beginning and end of the conversion character, and continuous Chinese only needs to be added once. In the preferred embodiment of the present invention, the terminal adds a special character "#" before and after the character is converted to obtain the short message content "#converted character #" to be transmitted.
可选地,优选的编码方案不仅仅用于移动中的短信模块,还可以运用于 终端内其它凡是采用字符编码方案的其他模块,例如彩信等。字符串编码在终端通信中运用广泛。Optionally, the preferred coding scheme is not only used for the short message module in the mobile, but also applicable to Other modules in the terminal that use character encoding schemes, such as MMS. String encoding is widely used in terminal communication.
需要说明的是,接收方终端解码方案中,发送终端在发送短信的PDU字符串中设置用户信息编码方式(TP-DCS),如果是UCS2编码则设置为08为UCS2编码,如果是7Bit编码则设置为00为7Bit编码,如果是混合编码则设置为00为7Bit编码。接收方终端解码根据接收的PDU字符串中的用户信息编码方式(TP-DCS)采用相应的解码方案,08代表UCS2解码方式。00为7Bit编码。和现有技术有所不同的是,如果判断为7Bit解码后还有可能存在二次解码。二次解码需要遍历整个字符串,遇见特殊符号则对后面的字符进行UCS2解码,每2个字节得到一个汉字,直到下一个特殊符号为止。It should be noted that, in the receiver terminal decoding scheme, the transmitting terminal sets the user information encoding mode (TP-DCS) in the PDU string for sending the short message, and if it is the UCS2 encoding, sets the 08 to the UCS2 encoding, and if it is the 7Bit encoding. Set to 00 for 7Bit encoding, and if mixed encoding, set 00 to 7Bit encoding. The receiver terminal decoding adopts a corresponding decoding scheme according to the user information encoding mode (TP-DCS) in the received PDU string, and 08 represents the UCS2 decoding mode. 00 is 7Bit coded. Different from the prior art, if it is determined that 7Bit is decoded, there may be secondary decoding. Secondary decoding requires traversing the entire string. When a special symbol is encountered, UCS2 is decoded for the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol.
本发明较佳实施例还提供了一种信息编解码装置,其中该编码装置包括:编辑模块,设置为接收用户输入的原始字符;编码模块,设置为根据原始字符进行PDU编码;比较模块,设置为计算和比较不同方案预处理后的编码字节长度,最终确定最优编码方案。其中解码装置包括:显示模块,设置为输出界面得到的用户原始字符;解码模块,设置为根据原始字符进行PDU解码;判断模块,设置为判断第一次解码之后是否存在特殊字符而启动二次解码。The preferred embodiment of the present invention further provides an information encoding and decoding apparatus, wherein the encoding apparatus comprises: an editing module configured to receive original characters input by a user; an encoding module configured to perform PDU encoding according to original characters; a comparison module, setting In order to calculate and compare the length of the encoded bytes after preprocessing of different schemes, the optimal coding scheme is finally determined. The decoding device comprises: a display module, configured to output the user original character obtained by the interface; the decoding module is configured to perform PDU decoding according to the original character; and the determining module is configured to determine whether there is a special character after the first decoding and start secondary decoding. .
可选地,编辑模块是用户可见的,属于终端UI交互的一部分,将用户输入的字符传递给编码模块进行处理。Optionally, the editing module is visible to the user and belongs to a part of the terminal UI interaction, and the characters input by the user are passed to the encoding module for processing.
可选地,编码模块,采用四种编码方式来对发送的内容进行编码,它们是7-bit、8-bit、USC2编码和混合编码。Optionally, the encoding module uses four encoding methods to encode the transmitted content, which are 7-bit, 8-bit, USC2 encoding, and hybrid encoding.
ASCII是用来表示英文字符的一种编码规范,每个ASCII字符占用1个字节(8bits)。其中7-bit编码将8位ASCII编码(最高位为0)转换为7位编码,即每8个字符可以压缩成7个。将ASCII8位编码的Bit8去掉,依次将下7位编码的后几位逐次移到前面,形成新的8位编码。ASCII is a coding specification used to represent English characters. Each ASCII character occupies 1 byte (8 bits). The 7-bit encoding converts 8-bit ASCII encoding (the highest bit is 0) into 7-bit encoding, that is, every 8 characters can be compressed into seven. Bit8 of the ASCII 8-bit code is removed, and the next few bits of the next 7-bit code are sequentially moved to the front to form a new 8-bit code.
UCS2编码用于Unicode字符,用2个字节为字符编码。将unicode编码转为UCS2编码。首先我们知道UCS2编码是将单个字符转化为16位的宽字符,即由这个字符的unicode转化为十六进制,高二位补0,字符串的长度为2位的16进制数,PDU模式中字符串长度为原始消息的2倍。UCS2编码是将每个字符(1-2个字节)按照ISO/IEC10646的规定,转变为16位的Unicode 宽字符。可以简单地调用API函数或查表法实现编码和解码。UCS2 encoding is used for Unicode characters and is encoded with 2 bytes. Convert unicode encoding to UCS2 encoding. First of all, we know that UCS2 encoding converts a single character into a 16-bit wide character, that is, the unicode of this character is converted to hexadecimal, the upper two bits are complemented by 0, and the length of the string is 2-digit hexadecimal number, PDU mode. The length of the string is twice that of the original message. UCS2 encoding converts each character (1-2 bytes) into 16-bit Unicode according to ISO/IEC10646. Wide character. You can simply call the API function or look up the table to achieve encoding and decoding.
8-bit编码通常用于发送数据消息,用于发送和接收数据消息,如图片或铃声等,普通的短信不会用到。8-bit encoding is usually used to send data messages, used to send and receive data messages, such as pictures or ring tones, ordinary text messages will not be used.
混合编码,如果短信内容含有中文字符字则先进行预处理,即将内容中的汉字先转换为字符,将单个字符转化为16位的宽字符,即由这个字符的unicode转化为十六进制。并使用标志位和其他字符区别开,之后再将所有字符(含汉字转换的字符)按照ASCII编码后使用7-bit压缩编码发送。Hybrid coding, if the content of the message contains Chinese character words, the pre-processing is performed, that is, the Chinese characters in the content are first converted into characters, and the single characters are converted into 16-bit wide characters, that is, the unicode of the character is converted into hexadecimal. And use the flag bit to distinguish it from other characters, and then send all characters (characters with Chinese character conversion) according to ASCII encoding and then send them using 7-bit compression encoding.
可选地,比较模块设置为比较不同的编码方案最终的字节长度,如果全部为ASCII字符则采用默认的7-bit编码,计算得到7-bit编码的字节长度;对于短信中同时含有汉字和字符的短信进行预处理后分别进行UCS2编码和ASCII编码,最后再进行7-bit压缩编码,最后形成的编码字节数量和默认终端采用的UCS2编码字节数量进行比较,最终终端自动选择较优的编码方案。Optionally, the comparison module is configured to compare the final byte lengths of different coding schemes, and if all are ASCII characters, the default 7-bit encoding is used, and the 7-bit encoded byte length is calculated; for the short message, the Chinese characters are also included. After pre-processing with the character's short message, UCS2 encoding and ASCII encoding are performed separately, and finally 7-bit compression encoding is performed. The number of encoded bytes formed is compared with the number of UCS2 encoded bytes used by the default terminal, and the final terminal automatically selects Excellent coding scheme.
可选地,接收方终端解码装置和编码装置类似,接收终端根据接收短信的PDU字符串中设置用户信息编码方式(TP-DCS)进行解码,如果是UCS2解码则启动UCS2解码,如果是7Bit编码则启动7Bit解码,7Bit解码后需要判断为是否存在特殊字符而确定是否需要二次解码,如果需要二次解码就启动针对转换字符的UCS2解码。即再将汉字转换的字符按照UCS2解码。二次解码需要遍历整个字符串,遇见特殊符号则对后面的字符进行UCS2解码,每2个字节得到一个汉字,直到下一个特殊符号为止。Optionally, the receiving terminal decoding device is similar to the encoding device, and the receiving terminal performs decoding according to the setting of the user information encoding mode (TP-DCS) in the PDU string of the received short message, and if the UCS2 is decoded, the UCS2 decoding is started, if the 7Bit encoding is performed. Then, 7Bit decoding is started. After 7Bit decoding, it is necessary to determine whether there is a special character to determine whether secondary decoding is required, and if secondary decoding is required, UCS2 decoding for the converted character is started. That is, the characters converted by Chinese characters are decoded according to UCS2. Secondary decoding requires traversing the entire string. When a special symbol is encountered, UCS2 is decoded for the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol.
图6是根据本发明较佳实施例的移动终端信息编解码示意图,应用在短信场景中。如图6所示,A为主叫方手机,B为被叫方手机。FIG. 6 is a schematic diagram of encoding and decoding information of a mobile terminal according to a preferred embodiment of the present invention, which is applied in a short message scenario. As shown in FIG. 6, A is a calling party mobile phone, and B is a called party mobile phone.
用户编辑一条短消息,如果短信内容不含汉字,则不做预处理,对内容中的字符进行ASCII编码后使用7-bit压缩编码发送即可。如果短信内容含有汉字则先进行预处理,即将内容中的汉字先转换为字符,并使用标志位和其他字符区别开,之后再将所有字符(含汉字转换的字符)按照ASCII编码后使用7-bit压缩编码。最后形成的编码字节数量和默认终端采用的UCS2编码字节数量进行比较,最终终端自动选择最优编码方案,假设采用了混合编码方案。 The user edits a short message. If the content of the short message does not contain Chinese characters, no pre-processing is performed. The characters in the content are ASCII-encoded and then sent using 7-bit compression encoding. If the content of the short message contains Chinese characters, the pre-processing is performed first, that is, the Chinese characters in the content are first converted into characters, and the flag is distinguished from other characters, and then all characters (characters including Chinese characters converted) are used in accordance with ASCII encoding. Bit compression coding. The final number of encoded bytes is compared with the number of UCS2 encoded bytes used by the default terminal. The final terminal automatically selects the optimal coding scheme, assuming a hybrid coding scheme is employed.
接收方收到该数据包后按照发送端编码的逆过程进行处理。如果判断编码数据中包含特殊字符,则先进行第1次解码,即7-bit解码,得到16进制的ASCII字符,之后对16进制的ASCII字符进行第2次解码,分别使用UCS2解码得到汉字,使用ASCII对照表得到字符,即为发送方发送的原始短信。如果判断编码数据中未包含特殊字符,则按照默认解码方法处理。After receiving the data packet, the receiver processes according to the inverse process of the sender code. If it is judged that the encoded data contains special characters, the first decoding is performed first, that is, 7-bit decoding, and hexadecimal ASCII characters are obtained, and then the hexadecimal ASCII characters are decoded second, and respectively obtained by UCS2 decoding. Chinese characters, using the ASCII comparison table to get the characters, that is, the original text messages sent by the sender. If it is judged that the encoded data does not contain special characters, it is processed according to the default decoding method.
图7是根据本发明较佳实施例的移动终端信息编解码方法流程图,应用在短信场景中。FIG. 7 is a flowchart of a method for encoding and decoding information of a mobile terminal according to a preferred embodiment of the present invention, which is applied in a short message scenario.
该方法发明思想为:实施架构包括用户终端、通讯网络和短消息中心。其中用户终端包括固定电话、移动电话和其他可以实现网络交互的设备。通讯网络包括移动电话网、固定网、互联网等。用户终端系统为了区别原始字符和汉字转换字符而规定了一种特殊符号为#。如图7所示,该方法步骤包括:The inventive idea of the method is that the implementation architecture includes a user terminal, a communication network, and a short message center. The user terminals include fixed phones, mobile phones, and other devices that can implement network interaction. Communication networks include mobile telephone networks, fixed networks, and the Internet. The user terminal system specifies a special symbol as # in order to distinguish between the original character and the Chinese character conversion character. As shown in FIG. 7, the method steps include:
步骤S702:A新建短消息,输入短信内容,假设内容为:“短信test123”。Step S702: A new short message is input, and the short message content is input, and the content is assumed to be: “text message test123”.
步骤S704:系统判断该内容是否含有汉字,如果是,则执行步骤S706,如果不含汉字,则转步骤S708。Step S704: The system determines whether the content contains Chinese characters. If yes, step S706 is performed. If the Chinese characters are not included, then step S708 is performed.
步骤S706:先对短信内容中的汉字进行预处理,具体为遍历短信内容如果遇见汉字则进行UCS2编码,每1个汉字转换为2个字节的字符。在本例中将汉字“短”和“信”分别按照UCS2编码转换为“77ED”和“4FE1”,遍历结束后原先的短信内容“短信test123”就转换为字符串“4FE177EDtest123”。将特殊符号#加入转换字符的首尾,连续汉字只需添加一次。在本例中系统在“4FE177ED”字符串前后加上特殊字符“#”从而得到要发送的短信内容“#4FE177ED#test123”。Step S706: Pre-processing the Chinese characters in the short message content, specifically, traversing the short message content, if the Chinese character is encountered, the UCS2 encoding is performed, and each Chinese character is converted into a 2-byte character. In this example, the Chinese characters "short" and "letter" are converted into "77ED" and "4FE1" according to the UCS2 code, and the original short message content "text test123" is converted into the string "4FE177EDtest123" after the traversal. Add the special symbol # to the beginning and end of the conversion character, and the continuous Chinese character only needs to be added once. In this example, the system adds the special character "#" before and after the "4FE177ED" string to get the short message content "#4FE177ED#test123" to be sent.
步骤S708:对短消息内容进行7-bit编码,在本例中系统将“#4FE177ED#test123”字符串按照7-bit编码方式编码为“239AB118BBDD8AC411BD3CA7C76433”字符串,Step S708: Perform 7-bit encoding on the short message content. In this example, the system encodes the string of “#4FE177ED#test123” into a string of “239AB118BBDD8AC411BD3CA7C76433” according to the 7-bit encoding mode.
步骤S710:比较模块对混合编码方案形成的编码字节数量和默认采用UCS2编码的编码字节数量进行比较,终端自动选择字节数最少码方案的作为最优编码方案采用。Step S710: The comparison module compares the number of encoded bytes formed by the hybrid coding scheme with the number of encoded bytes that are UCS2 encoded by default, and the terminal automatically selects the minimum number of bytes scheme as the optimal coding scheme.
此实施例中,混合编码方案形成的编码字节数量为15个字节,默认采用 的UCS2编码字节数量为18个字节,最终终端自动选择混合编码最优编码方案,并设置短信PDU串用户信息编码方式(TP-DCS)为00即7Bit编码。In this embodiment, the number of encoded bytes formed by the hybrid coding scheme is 15 bytes, which is adopted by default. The number of UCS2 encoded bytes is 18 bytes, and the final terminal automatically selects the hybrid coding optimal coding scheme, and sets the short message PDU string user information coding mode (TP-DCS) to 00 or 7Bit code.
步骤S712:A将此字符串封装为短信数据包发送给B,B接收A发送的数据包。Step S712: A encapsulates the string into a short message data packet and sends it to B, and B receives the data packet sent by A.
步骤S714:B对“239AB118BBDD8AC411BD3CA7C76433”进行7-bit解码,得到解码后的字符串“#4FE177ED#test123”,判断含有特殊字符#后进行第2次解码,即遍历该字符串并和特殊符号#相比较,如果相同则停止遍历并执行步骤S716,如果不相同则直到遍历结束并转步骤S718。Step S714: B performs 7-bit decoding on "239AB118BBDD8AC411BD3CA7C76433" to obtain a decoded character string "#4FE177ED#test123", and judges that the special character # is included, and then performs the second decoding, that is, traversing the character string and the special symbol # For comparison, if the same, the traversal is stopped and step S716 is performed, if not the same until the traversal is finished and the process proceeds to step S718.
步骤S716:遍历整个字符串,遇见特殊符号#则对后面的字符进行UCS2解码,每2个字节得到一个汉字,直到下一个特殊符号为止。在本例中把特殊符号“#”之间的字符串“4FE177ED”进行UCS2解码为“短信”,其他字符保持不变。Step S716: traversing the entire character string, and encountering the special symbol #, UCS2 decoding is performed on the following characters, and a Chinese character is obtained every 2 bytes until the next special symbol. In this example, the character string "4FE177ED" between the special symbols "#" is decoded into UCS2 as "SMS", and the other characters remain unchanged.
步骤S718:最后得到的字符串即为A发送的短信内容。在本例中经过2次解码得到的字符串“短信test123”即为实际的短信内容。Step S718: The last obtained character string is the short message content sent by A. In this example, the character string "text test123" obtained after two decodings is the actual short message content.
通过本发明的较佳实施例的方案,对于含有中文字符的短信,可以显著减少发送短信的条数从而降低用户的通信费用,也减轻了服务提供商的负担,提高了用户体验。With the solution of the preferred embodiment of the present invention, for a short message containing Chinese characters, the number of sent short messages can be significantly reduced, thereby reducing the communication cost of the user, reducing the burden on the service provider, and improving the user experience.
显然,本领域的技术人员应该明白,上述的本发明的各模块或各步骤可以用通用的计算装置来实现,它们可以集中在单个的计算装置上,或者分布在多个计算装置所组成的网络上,可选地,它们可以用计算装置可执行的程序代码来实现,从而,可以将它们存储在存储装置中由计算装置来执行,或者将它们分别制作成各个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。It will be apparent to those skilled in the art that the various modules or steps of the present invention described above can be implemented by a general-purpose computing device that can be centralized on a single computing device or distributed across a network of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device, such that they may be stored in a storage device by a computing device, or they may be fabricated into individual integrated circuit modules, or Multiple modules or steps are made into a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software.
以上所述仅为本发明的优选实施例而已,并不用于限制本发明,对于本领域的技术人员来说,本发明可以有各种更改和变化。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。 The above description is only the preferred embodiment of the present invention, and is not intended to limit the present invention, and various modifications and changes can be made to the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and scope of the present invention are intended to be included within the scope of the present invention.
工业实用性Industrial applicability
本发明提供的终端信息处理方法及装置,先判断待处理信息的类型,根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述处理信息进行编码,处理编码后的所述待处理信息,解决了相关技术中比较单一的信息编码方式的问题。对于含有中文字符的短信,可以显著减少发送短信的条数从而降低用户的通信费用,改善用户体验。 The method and device for processing terminal information provided by the present invention first determines the type of information to be processed, and selects a single coding mode or a hybrid coding mode from a plurality of preset coding modes according to the type, and encodes and processes the processed information. The encoded information to be processed solves the problem of a relatively simple information encoding method in the related art. For text messages containing Chinese characters, the number of messages sent can be significantly reduced, thereby reducing the communication cost of the user and improving the user experience.

Claims (24)

  1. 一种终端信息的处理方法,包括:A method for processing terminal information includes:
    判断待处理信息的类型;Determining the type of information to be processed;
    根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述待处理信息进行编码;Selecting a single coding mode or a hybrid coding mode from a preset plurality of coding modes according to the type, and encoding the to-be-processed information;
    处理编码后的所述待处理信息。Processing the encoded information to be processed.
  2. 根据权利要求1所述的方法,其中,所述根据所述类型选择单一编码方式或混合编码方式,对所述处理信息进行编码包括:The method according to claim 1, wherein the encoding the processing information according to the type selecting a single encoding mode or a hybrid encoding mode comprises:
    在判定所述类型为多种内容类型组合时,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第二编码字节数量;When it is determined that the type is a combination of multiple content types, the to-be-processed information combined by the multiple content types is encoded by a hybrid coding manner to obtain a first number of encoded bytes; and a single coding mode is adopted. Encoding the to-be-processed information that is combined by the multiple content types to obtain a second number of encoded bytes;
    比较所述第一编码字节数量和所述第二编码字节数量,确定较少编码字节数量所对应的编码方式;Comparing the first number of encoded bytes and the number of the second encoded bytes to determine an encoding mode corresponding to a smaller number of encoded bytes;
    采用确定的编码方式对所述待处理信息进行编码。The to-be-processed information is encoded using a determined coding manner.
  3. 根据权利要求2所述的方法,其中,The method of claim 2, wherein
    所述单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式或USC2编码方式;The single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, or a USC2 coding mode;
    所述混合编码方式包括以下之一:所述USC2编码方式与所述7-bit编码方式组合而成的混合编码方式或、所述USC2编码方式与8-bit编码方式组合而成的混合编码方式。The hybrid coding mode includes one of the following: a hybrid coding mode in which the USC2 coding mode is combined with the 7-bit coding mode, or a hybrid coding mode in which the USC2 coding mode and the 8-bit coding mode are combined. .
  4. 根据权利要求3所述的方法,其中,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量包括:The method according to claim 3, wherein the to-be-processed information combined by the plurality of content types is encoded by using a hybrid coding manner, and the number of the first encoded bytes is obtained by:
    当所述待处理信息的类型为中文字符和ASCII字符组合时,采用所述混合编码方式中的所述USC2编码方式对所述待处理信息中的中文字符进行编码;采用所述混合编码方式中的所述7-bit或8-bit编码方式对所述ASCII 字符和编码之后的所述中文字符进行编码。When the type of the to-be-processed information is a combination of a Chinese character and an ASCII character, the Chinese character in the to-be-processed information is encoded by using the USC2 encoding mode in the hybrid coding mode; The 7-bit or 8-bit encoding method for the ASCII The character and the Chinese character after the encoding are encoded.
  5. 根据权利要求4所述的方法,其中,采用所述混合编码方式中的所述USC2编码方式对所述待处理信息中的中文字符进行编码包括:The method according to claim 4, wherein encoding the Chinese characters in the to-be-processed information by using the USC2 encoding manner in the hybrid encoding mode comprises:
    在对所述中文字符进行编码后的字符串首尾分别加入标识字符以区别于其它ASCII字符。The character string is encoded at the beginning and the end of the character string encoded by the Chinese character to distinguish it from other ASCII characters.
  6. 一种终端信息的处理方法,包括:A method for processing terminal information includes:
    判断待处理信息的类型;Determining the type of information to be processed;
    根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述待处理信息进行解码;Deselecting a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, and decoding the to-be-processed information;
    处理解码后的所述待处理信息。Processing the decoded information to be processed.
  7. 根据权利要求6所述的方法,其中,所述判断待处理信息的类型包括:The method of claim 6, wherein the determining the type of information to be processed comprises:
    识别待处理信息中是否包含标识字符,该标识字符用于表示所述待处理信息中包括中文字符,位于编码后中文字符的首尾。The identifier information is included in the to-be-processed information, and the identifier character is used to indicate that the to-be-processed information includes a Chinese character, and is located at the beginning and the end of the encoded Chinese character.
  8. 根据权利要求7所述的方法,其中,The method of claim 7 wherein
    所述单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式、USC2解码方式;The single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, and a USC2 decoding mode;
    所述混合解码方式包括以下之一:所述USC2解码方式与所述7-bit解码方式组合而成的混合解码方式、所述USC2解码方式与8-bit解码方式组合而成的混合解码方式。The hybrid decoding method includes one of the following: a hybrid decoding method in which the USC2 decoding method and the 7-bit decoding method are combined, and a hybrid decoding method in which the USC2 decoding method and the 8-bit decoding method are combined.
  9. 根据权利要求8所述的方法,其中,根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述待处理信息进行解码,包括:The method of claim 8, wherein the decoding of the information to be processed is performed by selecting a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes, including:
    在判定所述待处理信息中携带有所述标识字符时,选择所述混合解码方式对所述待处理信息进行解码。When it is determined that the to-be-processed information carries the identifier character, the hybrid decoding mode is selected to decode the to-be-processed information.
  10. 根据权利要求9所述的方法,其中,选择所述混合解码方式对所述待处理信息进行解码,包括:The method of claim 9, wherein the selecting the hybrid decoding mode to decode the to-be-processed information comprises:
    采用所述7-bit或8-bit解码方式对所述待处理信息进行解码,得到所 述待处理信息对应的ASCII字符;Decoding the to-be-processed information by using the 7-bit or 8-bit decoding manner to obtain a solution The ASCII characters corresponding to the processing information;
    对所述ASCII字符采用所述USC2解码方式得到所述ASCII字符中携带的中文字符,按照ASCII对照表得到所述ASCII字符携带的字符信息,其中,该字符信息与所述中文字符组成所述ASCII字符。Obtaining the Chinese character carried in the ASCII character by using the USC2 decoding mode, and obtaining the character information carried by the ASCII character according to the ASCII comparison table, wherein the character information and the Chinese character form the ASCII character character.
  11. 一种终端信息的处理装置,包括:A device for processing terminal information, comprising:
    第一判断模块,设置为判断待处理信息的类型;a first determining module, configured to determine a type of information to be processed;
    编码模块,设置为根据所述类型从预设的多种编码方式中选择单一编码方式或混合编码方式,对所述处理信息进行编码;The encoding module is configured to select a single encoding manner or a hybrid encoding manner from a preset plurality of encoding manners according to the type, and encode the processing information;
    处理模块,设置为处理编码后的所述待处理信息。And a processing module, configured to process the encoded information to be processed.
  12. 根据权利要求11所述的装置,其中,所述编码模块包括:The apparatus of claim 11 wherein said encoding module comprises:
    第一编码单元,设置为在判定所述类型为多种内容类型组合时,采用混合编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第一编码字节数量;以及采用单一编码方式对由所述多种内容类型组合而成的所述待处理信息进行编码,得到第二编码字节数量;a first coding unit, configured to: when determining that the type is a combination of multiple content types, encoding the to-be-processed information that is combined by the multiple content types by using a hybrid coding manner to obtain a first encoded byte a quantity; and encoding the to-be-processed information combined by the plurality of content types by using a single encoding manner to obtain a second number of encoded bytes;
    比较单元,设置为比较所述第一编码字节数量和所述第二编码字节数量,确定较少编码字节数量所对应的编码方式;a comparing unit, configured to compare the first number of encoded bytes and the second number of encoded bytes, and determine an encoding manner corresponding to a smaller number of encoded bytes;
    确定单元,设置为采用确定的所述编码方式对所述处理信息进行编码。A determining unit is configured to encode the processing information using the determined encoding manner.
  13. 根据权利要求12所述的装置,其中,The device according to claim 12, wherein
    所述单一编码方式包括以下之一:7-bit编码方式、8-bit编码方式或USC2编码方式;The single coding mode includes one of the following: a 7-bit coding mode, an 8-bit coding mode, or a USC2 coding mode;
    所述混合编码方式包括以下之一:所述USC2编码方式与所述7-bit编码方式组合而成的混合编码方式或所述USC2编码方式与8-bit编码方式组合而成的混合编码方式。The hybrid coding method includes one of the following: a hybrid coding method in which the USC2 coding method and the 7-bit coding method are combined, or a hybrid coding method in which the USC2 coding method and the 8-bit coding method are combined.
  14. 根据权利要求13所述的装置,其中,所述第一编码单元还设置为,The apparatus according to claim 13, wherein said first coding unit is further configured to
    当所述内容类型的组合方式为中文字符和ASCII字符组合时,采用所述混合编码方式中的所述USC2编码方式对所待处理信息中的中文字符进行编码;采用所述混合编码方式中的所述7-bit或8-bit编码方式对所述ASCII 字符和编码之后的所述中文字符进行编码。When the combination of the content type is a Chinese character and an ASCII character combination, the Chinese character in the information to be processed is encoded by using the USC2 encoding mode in the hybrid coding mode; The 7-bit or 8-bit encoding mode for the ASCII The character and the Chinese character after the encoding are encoded.
  15. 根据权利要求14所述的装置,其中,所述第一编码单元还设置为,The apparatus of claim 14, wherein the first coding unit is further configured to
    在采用所述混合编码方式中的所述USC2编码方式对所待处理信息中的中文字符进行编码后得到的字符串的首尾加入标识字符以区别于其它ASCII字符。The character string obtained by encoding the Chinese character in the information to be processed is added with the identification character to distinguish it from other ASCII characters by using the USC2 encoding mode in the hybrid encoding mode.
  16. 一种终端信息的处理装置,包括:A device for processing terminal information, comprising:
    第二判断模块,设置为判断待处理信息的类型;a second determining module, configured to determine a type of information to be processed;
    解码模块,设置为根据所述类型从预设的多种解码方式中选择单一解码方式或混合解码方式,对所述处理信息进行解码;a decoding module, configured to select a single decoding mode or a hybrid decoding mode from a preset plurality of decoding modes according to the type, and decode the processing information;
    处理模块,设置为处理解码后的所述待处理信息。And a processing module, configured to process the decoded information to be processed.
  17. 根据权利要求16所述的装置,其中,所述第二判断模块还设置为,The apparatus according to claim 16, wherein the second determining module is further configured to
    识别待处理信息中是否包含表示该信息中包括中文字符的标识字符。It is identified whether the information to be processed includes an identification character indicating that the Chinese character is included in the information.
  18. 根据权利要求17所述的装置,其中,The device according to claim 17, wherein
    所述单一解码方式包括以下之一:7-bit解码方式、8-bit解码方式或USC2解码方式;The single decoding mode includes one of the following: a 7-bit decoding mode, an 8-bit decoding mode, or a USC2 decoding mode;
    所述混合解码方式包括以下之一:所述USC2解码方式与所述7-bit解码方式组合而成的混合解码方式或所述USC2解码方式与8-bit解码方式组合而成的混合解码方式。The hybrid decoding method includes one of the following: a hybrid decoding method in which the USC2 decoding method is combined with the 7-bit decoding method, or a hybrid decoding method in which the USC2 decoding method and the 8-bit decoding method are combined.
  19. 根据权利要求18所述的装置,其中,所述解码模块还设置为,在判定所述待处理信息中携带有所述标识字符时,选择所述混合解码方式对所述待处理信息进行解码。The apparatus according to claim 18, wherein the decoding module is further configured to: when determining that the to-be-processed information carries the identification character, select the hybrid decoding mode to decode the to-be-processed information.
  20. 根据权利要求19所述的装置,其中,所述解码模块还设置为,The apparatus of claim 19, wherein the decoding module is further configured to
    在判定所述待处理信息中携带有所述标识字符时,采用混合解码方式对所述待处理信息进行解码包括:采用7-bit或8-bit解码方式对所述待处理信息进行解码,得到所述待处理信息对应的ASCII字符;Decoding the to-be-processed information by using a hybrid decoding manner, when decoding the information to be processed by using a mixed decoding manner, comprising: decoding the to-be-processed information by using a 7-bit or 8-bit decoding manner, The ASCII character corresponding to the to-be-processed information;
    对所述ASCII字符采用所述USC2解码方式得到所述ASCII字符中携带的中文字符,按照ASCII对照表得到所述ASCII字符携带的字符信息,其中, 该字符信息与所述中文字符组成所述ASCII字符。Obtaining, in the ASCII character, the Chinese character carried in the ASCII character by using the USC2 decoding mode, and obtaining the character information carried by the ASCII character according to an ASCII comparison table, where The character information and the Chinese character constitute the ASCII character.
  21. 一种计算机程序,包括程序指令,当该程序指令被发送端设备执行时,使得该发送端设备可实施权利要求1-5任一项的方法。A computer program comprising program instructions that, when executed by a source device, cause the source device to perform the method of any of claims 1-5.
  22. 一种载有权利要求21所述计算机程序的载体。A carrier carrying the computer program of claim 21.
  23. 一种计算机程序,包括程序指令,当该程序指令被接收端设备执行时,使得该接收端设备可实施权利要求5-10任一项的方法。A computer program comprising program instructions that, when executed by a receiving device, cause the receiving device to perform the method of any of claims 5-10.
  24. 一种载有权利要求23所述计算机程序的载体。 A carrier carrying the computer program of claim 23.
PCT/CN2014/089393 2014-08-26 2014-10-24 Processing method and device for terminal information WO2015117407A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410424547.4 2014-08-26
CN201410424547.4A CN105472107A (en) 2014-08-26 2014-08-26 Terminal information processing method and device

Publications (1)

Publication Number Publication Date
WO2015117407A1 true WO2015117407A1 (en) 2015-08-13

Family

ID=53777224

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/089393 WO2015117407A1 (en) 2014-08-26 2014-10-24 Processing method and device for terminal information

Country Status (2)

Country Link
CN (1) CN105472107A (en)
WO (1) WO2015117407A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109995373A (en) * 2018-01-03 2019-07-09 上海艾拉比智能科技有限公司 A kind of mixing packing compression method of integer array
CN117391070A (en) * 2023-12-08 2024-01-12 和元达信息科技有限公司 Method and system for adjusting random character

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111507068B (en) * 2016-10-27 2023-08-25 青岛海信移动通信技术有限公司 Input information processing method and device and mobile terminal
CN108108267B (en) * 2016-11-25 2021-06-22 北京国双科技有限公司 Data recovery method and device
CN108282256B (en) * 2017-01-06 2022-05-13 中兴通讯股份有限公司 Information processing method and terminal

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003007182A1 (en) * 2001-07-11 2003-01-23 Sendo International Limited Device for automatically extending text messages, and methods therefor
CN101047733A (en) * 2006-06-16 2007-10-03 华为技术有限公司 Short message processing method and device
CN101309483A (en) * 2008-05-29 2008-11-19 深圳华为通信技术有限公司 Short message encoding and decoding method and terminal
CN101621771A (en) * 2009-08-12 2010-01-06 中兴通讯股份有限公司 Method, device and system for processing short message encoding
CN101674552A (en) * 2009-09-25 2010-03-17 中兴通讯股份有限公司 Short message coding method and terminal
CN101938719A (en) * 2010-09-03 2011-01-05 中兴通讯股份有限公司 Method for coding and decoding short messages (SMS), device and terminal
CN102014352A (en) * 2010-08-19 2011-04-13 上海闻泰电子科技有限公司 Method for converting short message coded format

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003007182A1 (en) * 2001-07-11 2003-01-23 Sendo International Limited Device for automatically extending text messages, and methods therefor
CN101047733A (en) * 2006-06-16 2007-10-03 华为技术有限公司 Short message processing method and device
CN101309483A (en) * 2008-05-29 2008-11-19 深圳华为通信技术有限公司 Short message encoding and decoding method and terminal
CN101621771A (en) * 2009-08-12 2010-01-06 中兴通讯股份有限公司 Method, device and system for processing short message encoding
CN101674552A (en) * 2009-09-25 2010-03-17 中兴通讯股份有限公司 Short message coding method and terminal
CN102014352A (en) * 2010-08-19 2011-04-13 上海闻泰电子科技有限公司 Method for converting short message coded format
CN101938719A (en) * 2010-09-03 2011-01-05 中兴通讯股份有限公司 Method for coding and decoding short messages (SMS), device and terminal

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109995373A (en) * 2018-01-03 2019-07-09 上海艾拉比智能科技有限公司 A kind of mixing packing compression method of integer array
CN109995373B (en) * 2018-01-03 2023-08-15 上海艾拉比智能科技有限公司 Mixed packing compression method for integer arrays
CN117391070A (en) * 2023-12-08 2024-01-12 和元达信息科技有限公司 Method and system for adjusting random character
CN117391070B (en) * 2023-12-08 2024-03-22 和元达信息科技有限公司 Method and system for adjusting random character

Also Published As

Publication number Publication date
CN105472107A (en) 2016-04-06

Similar Documents

Publication Publication Date Title
WO2015117407A1 (en) Processing method and device for terminal information
US20120278433A1 (en) Method for transmitting and receiving multimedia information and terminal
KR20190066065A (en) Encoding and decoding methods and devices
JP2018513647A (en) Extended compression format for data compression
CN101621763B (en) Method and corresponding device for displaying sender Chinese name at mobile phone terminal
TWI734829B (en) Method for transmitting data, receiving equipment, and sending equipment
WO2012027932A1 (en) Method, equipment and terminal for encoding/decoding short message
TWI723232B (en) Method for processing data, terminal equipment, and network equipment
CN110719573B (en) Information transmission method and device, terminal equipment and storage medium
CN110149631B (en) Method and system suitable for cloud loudspeaker box connection establishment
WO2013182079A1 (en) Short message transcoding method and device
US10623140B2 (en) Method for processing signaling sub-segment, processing apparatus, access point, and station
WO2012155464A1 (en) A terminal for protecting short message, system and method thereof
US10736089B2 (en) Downlink information receiving method and sending method, user equipment, and network device
KR100956793B1 (en) Method and Server for Transforming Message Format for Interworking between Different Message Standards
CN107734345B (en) Picture datamation transmission method and system
US7149198B2 (en) System and method for voice processing and transporting in a protocol independent tandem free operation manner
CN113490165B (en) 4G module short message receiving and transmitting method for embedded system
WO2018103008A1 (en) Digital communication system and bit error rate calculation method
WO2011113247A1 (en) Method and terminal for initiating service
RU2696621C1 (en) Method of receiving and a method of sending information over a downlink, a user device and a network device
KR100710268B1 (en) A voice call transmitting and receiving method between two different kind of micro processors
KR101682828B1 (en) Message compression method and apparatus
KR100652550B1 (en) A method and device for user-to-user information transfer
US9065889B2 (en) Telephone relay apparatus, telephone relay method, and program

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14881438

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14881438

Country of ref document: EP

Kind code of ref document: A1