CN100501743C - Processing method and apparatus for file configuration - Google Patents
Processing method and apparatus for file configuration Download PDFInfo
- Publication number
- CN100501743C CN100501743C CNB2007101124745A CN200710112474A CN100501743C CN 100501743 C CN100501743 C CN 100501743C CN B2007101124745 A CNB2007101124745 A CN B2007101124745A CN 200710112474 A CN200710112474 A CN 200710112474A CN 100501743 C CN100501743 C CN 100501743C
- Authority
- CN
- China
- Prior art keywords
- configuration file
- attribute
- relation
- attributes
- generation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Based on format of each configuration file (CF), the method determines attributes corresponding to CF, and relation between attributes. Carrying out simplifying process based on attribute relation of each CF, the method determines simple attribute relations. Based on attributes needed by CF and simple attribute relations, the method generates CF. comparing with current technique that multiple CFs needed to write respectively, the disclosed method needs to write one file only i.e. simple attribute relations. The invention does not concern each attribute relation in original CFs so as to reduce workload and working hours for CFs. Moreover, the said simple attribute relations are accomplished by device provided by this invention. Thus, the invention reduces working complexity and error rate, and raises success ratio for deploying system.
Description
Technical field
The present invention relates to computer application field, be meant a kind of disposal route and device of configuration file especially.
Background technology
For dirigibility and the extensibility that improves computer software, increasing computer software adopts the configuration file mode that the parameter and the data of all kinds, different purposes are configured, and the different distributions of these parameters and data based position and function is under different path and file.But, computer software heal huge or expandability good more, often just mean that the kind of configuration file and quantity are various more, the repeated labor that need pay is also just many more.Another problem is that the data between the configuration file are not isolated the existence usually, but exists confidential relation each other.
Though exist the computer software of complex configurations file powerful, but, deployment before computer software is used but becomes more and more difficult with test, difficulty derives from needs the configuration file of configuration too much, concern complexity between the configuration file, must carry out a large amount of repetitive operation in the layoutprocedure, the system testing after finishing for the deployment of computer software and deployment so all brings a lot of difficulties.System testing is meant the test that the correctness of special checking configuration file is carried out.For example, it is correct not representing the editor of configuration file after the configuration file editor finishes, this just need be deployed in configuration file earlier in the applied environment of computer software, moves computer software then and carries out system testing, if computer software goes wrong when operation.The editor that configuration file just is described is incorrect, will make amendment this moment to configuration file, redeploy then in the applied environment of computer software, proceed system testing, so repeatedly, until computer software operation success fully, showing just that configuration file is entirely true finishes, therefore, to a large amount of repetitive operation that configuration file carries out, make the system testing of carrying out for the correctness of checking configuration file become difficult unusually.
Summary of the invention
In view of this, technical matters to be solved by this invention is to provide a kind of disposal route and device of configuration file, makes the generation simple and fast of configuration file.
For achieving the above object, technical scheme of the present invention is achieved in that
A kind of disposal route of configuration file, this method comprises: determine attribute in the respective profiles according to the form of each configuration file, determine the relation between each attribute, relation on attributes according to each configuration file is simplified processing, determine the simple attributes relation, attribute and the simple attributes relation required according to configuration file generate configuration file.
Wherein, describedly simplify processing, comprising: the attribute that deletion repeats; Perhaps, the synthetic attribute of deletion; Perhaps, keep base attribute; Perhaps, combination arbitrarily more than.
Wherein, described simple attributes relation comprises between attribute implication, attribute codes and the attribute and concerning, described attribute and the simple attributes relation generation configuration file required according to configuration file comprise: according to the required attribute of configuration file, also directly according to described simple attributes relation generation configuration file.
Wherein, described simple attributes relation comprises between attribute codes and the attribute and concerning; Described attribute and the simple attributes relation generation configuration file required according to configuration file comprise: the attribute required according to configuration file, and according to the relation on attributes and the simple attributes relation generation configuration file of described configuration file.
Wherein, described generation configuration file comprises: generate synthetic attribute according to relation between required attribute of configuration file and attribute.
A kind for the treatment of apparatus of configuration file comprises: format analysis unit, relation on attributes determining unit, simplification processing unit and configuration file generation unit, and wherein, described format analysis unit is used for the form of configuration file is analyzed; Relation between the configuration file format analytic attribute that described relation on attributes determining unit is used for obtaining according to analysis generates the configuration file relation on attributes; Described simplification processing unit is used for simplifying processing according to the relation on attributes of each configuration file, generates the simple attributes relation; Described configuration file generation unit is used for generating configuration file according to configuration file required attribute and simple attributes relation.
Described configuration file generation unit by with the relation on attributes determining unit obtain the configuration file relation on attributes alternately.
Among the present invention, determine attribute in the respective profiles according to the form of each configuration file, determine the relation between each attribute, relation on attributes according to each configuration file is simplified processing, determine the simple attributes relation, attribute and the simple attributes relation required according to configuration file generate configuration file, need write the realization of a plurality of configuration files respectively compares with prior art, only need write a file among the present invention, it is the simple attributes relation, needn't go to be concerned about each relation on attributes of original configuration file again, very big like this reduction workload and the working time that configuration file is configured.In addition,, reduced work complexity and error rate, improved the success ratio of system deployment because the simple attributes relation is finished by device provided by the invention.
According to scheme provided by the invention, can shorten the time that editor disposes configuration file largely, reduce workload and work complexity, reduce error rate, improve the system deployment success ratio.
Description of drawings
Fig. 1 is configuration file processing flow chart among the present invention;
Fig. 2 is the configuration file format synoptic diagram;
Fig. 3 is a configuration file synoptic diagram in the specific embodiment of the invention;
Fig. 4 is configuration file treating apparatus structural representation among the present invention.
Embodiment
Among the present invention, determine attribute in the respective profiles according to the form of each configuration file, determine the relation between each attribute, simplify processing according to the relation on attributes of each configuration file, determine the simple attributes relation, attribute and the simple attributes relation required according to configuration file generate configuration file.
Fig. 1 is configuration file processing flow chart among the present invention, and as shown in Figure 1, the processing procedure of configuration file specifically may further comprise the steps:
Different configuration files has different forms, can analyze the attribute of this configuration file by the form of configuration file, by format specification the attribute of configuration file and putting in order of attribute, as certain configuration file format as shown in Figure 2, by the form of this configuration file, can obtain the following association attributes of this configuration file:
<attribute " tree-node " attribute " nodeid " attribute " describe " attribute " label-key " 〉
<attribute " operation " attribute " describe " attribute " label-key " 〉
……
</tree-node>
And then according to the attribute of the configuration file of determining, the relation between the analytic attribute.
Step 104: judging whether that all configuration files of choosing have all been analyzed finishes, and finishes if all analyzed, then continues execution in step 105; Otherwise, continue execution in step 108.Since may choose a plurality of configuration files simultaneously, therefore, by the complete analysis of this step to all configuration files of choosing.
After all configuration files of choosing are finished analysis, just determined relation between the corresponding attribute at each configuration file.
Step 107: when subsequent treatment need generate configuration file, attribute and the simple attributes relation required according to configuration file generated configuration file, finish current flow process.If simple attributes relation includes only between attribute codes and the attribute and concerns, when then generating configuration file, also need to generate respective profiles further combined with the relation on attributes of respective profiles according to the required attribute of configuration file and simple attributes relation.If the simple attributes relation not only comprises between attribute codes and the attribute concern, also comprise the attribute implication, then only need to get final product according to configuration file required attribute and simple attributes relation generation configuration file.Generating configuration file comprises according to relation between required attribute of configuration file and attribute and generates processes such as synthetic attribute.A configuration file can be only generated in this step, also a plurality of configuration files can be generated in the lump.
Step 108: select a configuration file of not analyzing, return execution in step 101 then.
Below by a concrete application example specific implementation of the present invention is described in more detail.
Fig. 3 is a configuration file synoptic diagram in the specific embodiment of the invention, and as shown in Figure 3, according to the form of configuration file A, the attribute that can obtain among the configuration file A is as follows:
<attribute 01 " nodeid " attribute 02 " describe " attribute 03 " codelist " 〉
<attribute 04 " operate " attribute 05 " describe " 〉
……
</>
……
}
To being described below of each attribute:
Attribute 01 nodeid node ID
Attribute 02 describe node is explained
The command code (using CSV between the command code) that attribute 03 codelist node comprises
Attribute 04 operate operation
Attribute 05 describe node is explained
After determining attribute that configuration file A comprises, determine the relation between each attribute: attribute 04 is attribute 01 and other attribute sums, i.e. attribute 04=attribute 01+XX; Attribute 05 is other attributes and attribute 02 sum, i.e. attribute 05=XX+ attribute 02, and wherein, XX is uncertain other attributes.
According to the form of configuration file B, the attribute that can obtain among the configuration file A is as follows:
{<attribute 11 " code " attribute 12 " describe " attribute 13 " version " attribute 14 " operation "
>
……
}
To being described below of each attribute:
Attribute 11 code command codes (digital form can not repeat)
Attribute 12 describe command codes are explained
Attribute 13 version version numbers (seldom changing)
Attribute 14 operation operation
After determining attribute that configuration file B comprises, determine do not have the relation of being mutually related between each attribute.
If current is chosen configuration file A and these two configuration files of B, after then having determined the relation on attributes among configuration file A and the B respectively, relation on attributes according to each configuration file is simplified processing, can determine that by analyzing attribute 04 is identical with attribute 14, therefore, but delete property 04 or attribute 14 are as delete property 14; Because attribute 04=attribute 01+XX, only keep the relation on attributes of simplifying most in the simple attributes relation, therefore, attribute 04 belongs to synthetic attribute, needs delete property 04, associative operation by that analogy, no longer too much describe, like this, only reserved property 01, attribute 02, attribute 11 and attribute 13 in the simple attributes relation that obtains at last, and, also comprise relation of synthetic attribute and other attributes or the like in this simple attributes relation.Can only comprise between attribute codes and the attribute in the simple attributes relation and concerning; Also can both comprise between attribute codes and the attribute concerning, also comprise the attribute implication.
When subsequent treatment need generate configuration file A, according to the required attribute of configuration file and simple attributes relation or according to the relation on attributes of the required attribute of configuration file, simple attributes relation and configuration file A, determine that configuration file A comprises attribute 01, attribute 02, attribute 03, attribute 04 and attribute 05 these 5 attributes, and attribute 04=attribute 01+XX, attribute 05=XX+ attribute 02 generate configuration file A according to these information of determining.
Fig. 4 is configuration file treating apparatus structural representation among the present invention, and as shown in Figure 4, this device comprises: format analysis unit, relation on attributes determining unit, simplification processing unit and configuration file generation unit.Wherein, the format analysis unit is used for the form of configuration file is analyzed, and provides configuration file format to the relation on attributes determining unit; Relation between the configuration file format analytic attribute that the relation on attributes determining unit is used for obtaining according to analysis generates the configuration file relation on attributes, and provides the configuration file relation on attributes to simplifying processing unit; Format analysis unit and relation on attributes determining unit are used for a plurality of configuration files of choosing are carried out associative operation; Simplify processing unit and be used for simplifying processing, generate the simple attributes relation, and provide the simple attributes relation to the configuration file generation unit according to the relation on attributes of each configuration file; The configuration file generation unit is used for generating configuration file according to configuration file required attribute and simple attributes relation.Only comprise when concerning between attribute codes and the attribute in the simple attributes relation, the configuration file generation unit by with the relation on attributes determining unit obtain the configuration file relation on attributes alternately.
The above is preferred embodiment of the present invention only, is not to be used to limit protection scope of the present invention.
Claims (7)
1, a kind of disposal route of configuration file, it is characterized in that, this method comprises: determine attribute in the respective profiles according to the form of each configuration file, determine the relation between each attribute, relation on attributes according to each configuration file is simplified processing, determine the simple attributes relation, attribute and the simple attributes relation required according to configuration file generate configuration file.
2, method according to claim 1 is characterized in that, describedly simplifies processing, comprising: the attribute that deletion repeats; Perhaps, the synthetic attribute of deletion; Perhaps, keep base attribute; Perhaps, combination arbitrarily more than.
3, method according to claim 1 is characterized in that,
Described simple attributes relation comprises between attribute implication, attribute codes and the attribute and concerning;
Described attribute and the simple attributes relation generation configuration file required according to configuration file comprise: according to the required attribute of configuration file, also directly according to described simple attributes relation generation configuration file.
4, method according to claim 1 is characterized in that,
Described simple attributes relation comprises between attribute codes and the attribute and concerning;
Described attribute and the simple attributes relation generation configuration file required according to configuration file comprise: the attribute required according to configuration file, and according to the relation on attributes and the simple attributes relation generation configuration file of described configuration file.
5, method according to claim 1 is characterized in that, described generation configuration file comprises: generate synthetic attribute according to relation between required attribute of configuration file and attribute.
6, a kind for the treatment of apparatus of configuration file is characterized in that, this device comprises: format analysis unit, relation on attributes determining unit, simplification processing unit and configuration file generation unit, wherein,
Described format analysis unit is used for the form of configuration file is analyzed;
Relation between the configuration file format analytic attribute that described relation on attributes determining unit is used for obtaining according to analysis generates the configuration file relation on attributes;
Described simplification processing unit is used for simplifying processing according to the relation on attributes of each configuration file, generates the simple attributes relation;
Described configuration file generation unit is used for generating configuration file according to configuration file required attribute and simple attributes relation.
7, device according to claim 6 is characterized in that, described configuration file generation unit by with the relation on attributes determining unit obtain the configuration file relation on attributes alternately.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNB2007101124745A CN100501743C (en) | 2007-06-28 | 2007-06-28 | Processing method and apparatus for file configuration |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNB2007101124745A CN100501743C (en) | 2007-06-28 | 2007-06-28 | Processing method and apparatus for file configuration |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101101598A CN101101598A (en) | 2008-01-09 |
CN100501743C true CN100501743C (en) | 2009-06-17 |
Family
ID=39035872
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNB2007101124745A Expired - Fee Related CN100501743C (en) | 2007-06-28 | 2007-06-28 | Processing method and apparatus for file configuration |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN100501743C (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102023871B (en) * | 2011-01-07 | 2014-02-12 | 中国农业银行股份有限公司 | Method and system for acquiring extensible markup language (XML) information |
CN109271216B (en) * | 2018-10-19 | 2022-07-26 | 北京北信源信息安全技术有限公司 | Configuration file management method and configuration file management device |
-
2007
- 2007-06-28 CN CNB2007101124745A patent/CN100501743C/en not_active Expired - Fee Related
Non-Patent Citations (2)
Title |
---|
Spring IDE 2.0 全新体验. 俞黎敏.程序员,第4期. 2007 |
Spring IDE 2.0 全新体验. 俞黎敏.程序员,第4期. 2007 * |
Also Published As
Publication number | Publication date |
---|---|
CN101101598A (en) | 2008-01-09 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Memon et al. | Regression testing of GUIs | |
US6622298B1 (en) | Method and apparatus for testing software having a user interface | |
CN108845940B (en) | Enterprise-level information system automatic function testing method and system | |
CN101866315B (en) | Test method and system of software development tool | |
JP2007515013A (en) | Software code migration and conversion equipment from any source platform to any target platform | |
CN107608873B (en) | Software testing method and system and testing platform | |
CN100501743C (en) | Processing method and apparatus for file configuration | |
US7624381B1 (en) | Portable detection of start and completion of object construction | |
CN104536880A (en) | GUI program testing case augmentation method based on symbolic execution | |
EP1710698A2 (en) | Generic software requirements analyser | |
US9396239B2 (en) | Compiling method, storage medium and compiling apparatus | |
US20030126506A1 (en) | Program testing system and method | |
Boucher et al. | Transforming workflow models into automated end-to-end acceptance test cases | |
CN112015633B (en) | Test excitation multi-platform multiplexing method, device, equipment and storage medium | |
CN113805861A (en) | Code generation method based on machine learning, code editing system and storage medium | |
CN111638905A (en) | Version number generation method and device, electronic equipment and readable storage medium | |
CN112836033A (en) | Business model management method, device, equipment and storage medium | |
CN111782641A (en) | Data error repairing method and system | |
CN110321130A (en) | The not reproducible compiling localization method of log is called based on system | |
Belkhouche et al. | Multiple views analysis of software designs | |
KR100791303B1 (en) | Apparatus and method for making component of build block | |
Lin et al. | Usage modeling through sequence enumeration for automated statistical testing of a GUI application | |
CN114356301A (en) | Method and system for automatically constructing programming task context based on Eclipse plug-in | |
CN117873571A (en) | Configuration method and device of continuous integrated pipeline | |
JP6576873B2 (en) | Job net verification apparatus and job net verification method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20090617 Termination date: 20170628 |
|
CF01 | Termination of patent right due to non-payment of annual fee |