Unlock instant, AI-driven research and patent intelligence for your innovation.
Text data storage method and device
What is Al technical title?
Al technical title is built by PatSnap Al team. It summarizes the technical point description of the patent document.
A text data and data structure technology, applied in the field of text processing, can solve the problem of low efficiency of target characters
Active Publication Date: 2020-06-30
HANGZHOU ANHENG INFORMATION TECH CO LTD
View PDF3 Cites 0 Cited by
Summary
Abstract
Description
Claims
Application Information
AI Technical Summary
This helps you quickly interpret patents by identifying the three key elements:
Problems solved by technology
Method used
Benefits of technology
Problems solved by technology
[0004] In view of this, the purpose of the present invention is to provide a text data storage method and device to alleviate the technical problem of low efficiency in the prior art when locating target characters in text
Method used
the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more
Image
Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
Click on the blue label to locate the original text in one second.
Reading with bidirectional positioning of images and text.
Smart Image
Examples
Experimental program
Comparison scheme
Effect test
Embodiment 1
[0110] The embodiment of the present invention provides a storage method for the number of text characters, such as figure 2 shown, including:
[0111] Step S12, acquiring the text data and the data to be stored in the text data at the current moment.
[0112] Step S14, read the number of characters of the data to be stored, and read the position of the data to be stored in the text data, the position includes: the number of rows or the number of columns.
[0113] Specifically, in the case of text data sorted by row, the position includes row; and in the case of text data sorted by column, the position includes column.
[0114] Step S16, search for the node corresponding to the position in the pre-built binary tree data structure, and determine the number of characters as the node value of the corresponding node to store the number of characters, wherein the binary tree data structure is pre-ordered according to the middle order of the binary tree The traversal order specif...
Embodiment 2
[0169] The embodiment of the present invention also provides a storage device for text data, such as Figure 9 shown, including:
[0170] Acquisition module 100, for obtaining the data to be stored in the text data and the text data at the current moment;
[0171] The reading module 200 is used to read the number of characters of the data to be stored, and read the position of the data to be stored in the text data, the position includes: the number of rows or the number of columns;
[0172] The determination module 300 is used to search for the node corresponding to the position in the pre-built binary tree data structure, and determine the number of characters as the node value of the corresponding node, so as to store the number of characters, wherein the binary tree data structure is in advance according to the binary tree The inorder traversal order of specifies the storage order of the nodes.
[0173] In the embodiment of the present invention, the acquisition module 1...
the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More
PUM
Login to View More
Abstract
The invention provides a text data storage method and apparatus, and relates to the technical field of text processing. The method comprises the steps of obtaining text data and to-be-stored data in the text data at a current moment; reading a character number of the to-be-stored data, and reading the position of the to-be-stored data in the text data, wherein the position comprises a row number or a column number; and searching for a node corresponding to the position in a pre-built binary treedata structure, and determining the character number as a node value of the corresponding node, thereby storing the character number, wherein the binary treedata structure defines a storage sequence of nodes previously according to an inorder traversal sequence of a binary tree. The character number of each row or each column in the text data is stored by utilizing the binary tree data structure, so that the technical problem of relatively low efficiency of locating target characters in a text in the prior art is relieved.
Description
technical field [0001] The present invention relates to the technical field of text processing, in particular to a text data storage method and device. Background technique [0002] The storage of text characters is essentially the storage of continuous character sequences. The traditional continuous character sequence storage methods include arrays and linked lists. In these two storage methods, after characters are inserted or deleted in the text, the text after the modified position needs to be shifted, so that the characters and characters in the text The correspondence between the number of rows at has changed. [0003] However, for modern text editors, the continuous maintenance of the corresponding relationship between text characters and their line numbers is conducive to quickly locating the target characters when the text is read and edited, and has high practicality in scenarios such as code editing. the value of. The positioning method in the prior art is to s...
Claims
the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More
Application Information
Patent Timeline
Application Date:The date an application was filed.
Publication Date:The date a patent or application was officially published.
First Publication Date:The earliest publication date of a patent with the same application number.
Issue Date:Publication date of the patent grant document.
PCT Entry Date:The Entry date of PCT National Phase.
Estimated Expiry Date:The statutory expiry date of a patent right according to the Patent Law, and it is the longest term of protection that the patent right can achieve without the termination of the patent right due to other reasons(Term extension factor has been taken into account ).
Invalid Date:Actual expiry date is based on effective date or publication date of legal transaction data of invalid patent.