Method and system for recovering xml configuration files based on xpath
A technology for configuring files and recovery methods, applied in the direction of file system, file access structure, semi-structured data retrieval, etc., can solve the problems that the application program cannot support modifying the original default value, there is no solution, and no content recovery is provided.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0088] Please refer to figure 2 , the present embodiment provides an XPATH-based XML configuration file recovery method, realizes the application program that adopts the XML file to save the configuration, and can restore the content of the user configuration file stored on the storable medium to the same version when the system configuration is restarted. in the published run configuration file.
[0089] Here, for the convenience of description, the version XML configuration file released with the version of the application program is regarded as the first configuration file; the user XML configuration file stored on the storage medium is regarded as the second configuration file; the priority of the second configuration file The level is greater than the first configuration file, and the system runs the first configuration file after restoring the XML configuration, that is, the XML configuration saved on the storage medium.
[0090] Single instance and multiple instances ...
Embodiment 2
[0113] Please refer to image 3 , this embodiment is further extended on the basis of Embodiment 1. The similarities will not be repeated. The difference is that the recovery process for the single instance node enables it to be realized on the basis of synchronizing the modification of the configuration file by the user. The modification of the default value of the leaf node when the application is released.
[0114] The restoration process of a single-instance node that supports the above functions may specifically include the following steps:
[0115] S01: Before each recovery, back up a copy of the first configuration file released with the version as the baseline configuration file for the next recovery;
[0116] S02: Use the depth-first algorithm to recursively traverse all the leaf nodes in the first configuration file released with the version, and record the intermediate node information during the traversal process, so as to obtain the absolute paths of all leaf nod...
Embodiment 3
[0123] see Figure 5 to Figure 6 , on the basis of Embodiment 1 and Embodiment 2, this embodiment provides an XPATH-based XML configuration file recovery system,
[0124] see Figure 4 , the system includes:
[0125] The first traversal module 1 is used to traverse all the leaf nodes in the first configuration file released with the version, and obtain the absolute paths of all the leaf nodes;
[0126] The first query module 2 is configured to use XPATH to query whether there is a corresponding leaf node in a second configuration file according to the absolute path, and the second configuration file is a configuration file stored on a storable medium;
[0127] The first writing module 3 is used to write the value of the leaf node in the second configuration file into the corresponding leaf node in the first configuration file if the query result of the query module exists.
[0128] see Figure 6 , preferably, for multi-instance nodes, the system of this embodiment also inc...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More - R&D
- Intellectual Property
- Life Sciences
- Materials
- Tech Scout
- Unparalleled Data Quality
- Higher Quality Content
- 60% Fewer Hallucinations
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2025 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com



