Method and device for compressing, decompressing and querying documents
A compression method and document technology, applied in file systems, instruments, computing, etc., can solve problems such as inability to compress XML documents
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0076] Embodiment 1 provides a method for compressing an XML document with a corresponding Schema. The method first separates the structural content and data content of the XML document; secondly, respectively determines the path code of the node and the path code of the data content; finally, the The path encoding of the node, the path encoding of the data content, and the data content are respectively compressed; the specific steps are as follows:
[0077] Step A, separate the structural content and data content of the XML document according to a preset separation method; the structural content is other content in the tags in the XML document except attribute values and the content between tags; the data content Including the attribute values in the tags in the XML document and the content between the tags;
[0078] Step B, assign preset node numbers to the site, regions, namedrica, item, id, location, categories, and category nodes in the Schema node; the node numbers c...
Embodiment 2
[0100] Embodiment 2 of the present invention provides a method for decompressing an XML document compressed using the above compression method. After obtaining and decompressing the path code of the compressed node, the compressed data content and the compressed document structure information, Output the node corresponding to the decompressed path code; determine the compressed data content corresponding to the decompressed node according to the decompressed document structure information, and the method of decompressing and outputting the determined data content specifically includes the following process:
[0101] Step one, judge whether described XML document has binary Schema graph (Binaryschemagraph, bsg) file, when confirming, turn to step two; In the described bsg file, include the node name of Schema node, the child node number of this node, the The type of node, the type includes data content type and node type; the type of the indicator of the node, the number of occu...
Embodiment 3
[0107] The third embodiment provides a method for querying the compressed XML document using the above-mentioned compression method, because the node and / or storage path of the data content in the XML document corresponding to the Schema after compression according to the above-mentioned method is a path code; Therefore, after the query path is converted into a path code, the nodes and / or data content can be searched, and the found nodes and / or data content can be output as the query result; in this step, the XML document comes with a bsg file, The bsg file includes the node name of the Schema node, the number of child nodes of the Schema node, the type of the Schema node, and the type includes a data content type and a node type; the type of the indicator of the Schema node, the indicator The number of occurrences, structure content and data content; the type of the indicator includes all indicator, choice indicator and sequence indicator; the bsg file also includes a start ...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com