CN101739466A - File managing method and file managing device - Google Patents

File managing method and file managing device Download PDF

Info

Publication number
CN101739466A
CN101739466A CN201010034262A CN201010034262A CN101739466A CN 101739466 A CN101739466 A CN 101739466A CN 201010034262 A CN201010034262 A CN 201010034262A CN 201010034262 A CN201010034262 A CN 201010034262A CN 101739466 A CN101739466 A CN 101739466A
Authority
CN
China
Prior art keywords
management information
file
change
content
file content
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.)
Pending
Application number
CN201010034262A
Other languages
Chinese (zh)
Inventor
程晶
张永智
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
BEIJING REDFLAG CH2000 SOFTWARE Co Ltd
Original Assignee
BEIJING REDFLAG CH2000 SOFTWARE Co Ltd
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 BEIJING REDFLAG CH2000 SOFTWARE Co Ltd filed Critical BEIJING REDFLAG CH2000 SOFTWARE Co Ltd
Priority to CN201010034262A priority Critical patent/CN101739466A/en
Publication of CN101739466A publication Critical patent/CN101739466A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Document Processing Apparatus (AREA)

Abstract

The invention discloses a file managing method. The method comprises the following steps of: judging that file content is modified; and generating management information indicating modification situation for the modified file content. The invention also discloses a file managing device, which comprises a content modification detection unit and a management information maintenance unit connected with each other, wherein the content modification detection unit is used for judging that the file content is modified and informing the management information maintenance unit; and the management information maintenance unit is used for generating the management information indicating the modification situation for the modified file content. Consequently, the method and the device can automatically add the management information for a modified file, which can effectively improve working efficiency and bring convenience to the management on the file.

Description

File management method and device
Technical field
The present invention relates to the file processing field, be specifically related to file management method and device.
Background technology
Along with computer technology and fast development of information technology, computing machine has become people's daily life, office and study necessary tool, and more and more data information is preserved on computers by the form of electronic document.When this form offered convenience to people, problem difficult in maintenance had also appearred.A lot of electronic document contents need constantly to revise, safeguard, especially code information is being safeguarded a large amount of e-file information jointly by some team under a lot of situations, during can constantly change file, comprise increase, deleted file or file content.At this moment how to manage better, safeguard that these e-files have become the problem that can't neglect.
In present code administration field, it no matter is the merge function of present diff/patch instrument or svn instrument, all, say nothing of the function that when inserting management information, derives statistic record not to changing the function that file inserts the management information of different-format in batches.
In the developing instrument field, some software such as Eclipse have the insertion annotation function, but can only insert the note of set form, immobilized substance, and can't finish automatic selection form, in batches add the function of management information, also can't finish the function that derives statistic record.
In fact, can only add management information at the file that change takes place with manual type usually at present, work efficiency is low, and the error rate height is unfavorable for efficient, management automatically to file.
Summary of the invention
In view of this, fundamental purpose of the present invention is to provide a kind of file management method and device, adds management information at the file that change takes place automatically, to increase work efficiency convenient management to file.
For achieving the above object, technical scheme of the present invention is achieved in that
File management method, this method comprises:
Judge that change has taken place file content, generate the management information that is used to show the change situation at the file content that change takes place.
Described change is the deletion of file content, and the process that generates described management information comprises:
Obtain the form and the current system time of management information, statement, current system time and the descriptive information of deleting content is inserted in the file with obtained management information format unification.
Described change is the increase of file content, and the process that generates described management information comprises:
Obtain the form and the current system time of management information; Write and show that changing content begins the management information of part, and after adding end of message (EOM), write the management information that shows the changing content latter end.
The line number of change takes place in total line number that change takes place in the current All Files of record of further adding up and the current file; The position that described change takes place is the position of inserting described management information.
Further comprise:
With the variate-value of the change line number of file content, and the path of the file of current variation and title write as a result in the statistics file.
Change has taken place in described judgement file content, realizes by differential technique.
Further comprise:
Confirming that all file contents that need change have changed finishes, and final statistical information is write statistics file as a result.
Document management apparatus, this device comprise continuous content alteration detecting unit, management information maintenance unit; Wherein,
Described content alteration detecting unit is used to judge that change has taken place file content, and notifies described management information maintenance unit;
Described management information maintenance unit is used for generating the management information that is used to show the change situation at the file content that change takes place.
Further comprise statistic unit;
Described management information maintenance unit is further used for will be referred to management information and adds the operating result of operation and send to described statistic unit;
Described statistic unit is used for adding operating result according to the management information of receiving and carries out statistical operation at file content change situation.
Described management information maintenance unit comprises continuous management information interpolation decision-making module, management information format control module, management information interpolation execution module; Wherein,
Described management information is added decision-making module, is used to determine whether to add management information, and notifies described management information format control module when determining to add management information;
Described management information format control module is used for the definite management information format that will add, and is notified to described management information interpolation execution module;
Described management information is added execution module, is used to carry out comprise that the management information that obtains current system time adds operation.
As seen, the inventive method and device can add management information at the file that change takes place automatically, therefore can effectively increase work efficiency, and have made things convenient for the management to file.
Description of drawings
Fig. 1 is the file management process flow diagram of one embodiment of the invention;
Fig. 2 is the file management process flow diagram of another embodiment of the present invention;
Fig. 3 is the file management process flow diagram of further embodiment of this invention;
Fig. 4 is a file management general flow chart of the present invention;
Fig. 5 is the document management apparatus figure of the embodiment of the invention.
Embodiment
On the invention thinking, file management method provided by the present invention comprises: judge that change has taken place file content, generate the management information that is used to show the change situation at the file content that change takes place.
Document management apparatus provided by the present invention comprises continuous content alteration detecting unit, management information maintenance unit; Wherein, described content alteration detecting unit is used to judge that change has taken place file content, and notifies described management information maintenance unit; Described management information maintenance unit is used for generating the management information that is used to show the change situation at the file content that change takes place.
Referring to Fig. 1, Fig. 1 is the file management process flow diagram of one embodiment of the invention, and this flow process may further comprise the steps:
Step 101: read in the descriptive information of user's input and correlated variables is carried out initialization process.
Step 102: document change content detection.
Particularly, can use the mode that is called as differential technique at present among the present invention file is detected, described differential technique can content-based contrast be found the difference of two cover file sets, and according to the old file set of difference update of two cover file sets.Therefore, can use differential technique same file is compared constantly in difference, to determine to take place in the file content of change.
Step 103: judge whether needs deletion information according to document change content detection result,, enter step 104 as needs; Otherwise, directly enter step 110.
Step 104: statistical information is handled.
Concrete statistical information processing procedure will be described at Fig. 2 in subsequent content.
Step 105: the line number of deleting in total line number of deleting in the current All Files of record that adds up and the current file.
Step 106: judge whether current location can insert management information, if can, enter step 107; Otherwise, return step 102.
Particularly, generally speaking,, then need to insert management information if change has taken place file content; But, when current file is the first trip of * .xml, do not insert management information usually, when the lastrow end of line character of changing content is “ " time do not insert management information usually yet.
Step 107: the form of obtaining management information according to file extension.
Step 108: obtain current system time.
Step 109: write the management information of corresponding format, return step 102.
Particularly, the descriptive information that statement, time (being current system time) and the user of deletion content can be set is inserted in the file with obtained management information format unification.
Step 110: need to judge whether increase information, if desired, carry out step 111; Otherwise, directly enter step 120.
Step 111: statistical information is handled.
Concrete statistical information processing procedure will be described at Fig. 2 in subsequent content.
Step 112: the line number that increases in total line number that increases in the current All Files of record that adds up and the current file.
Step 113: judge whether current location can insert management information, if can, enter step 114; Otherwise, return step 102.
Particularly, generally speaking,, then need to insert management information if change has taken place file content; But, when current file is the first trip of * .xml, do not insert management information usually, when the lastrow end of line character of changing content is “ " time do not insert management information usually yet.
Step 114: add management information and handle, return step 102.
Concrete interpolation management information is handled process and will be described at Fig. 3 in subsequent content.
Step 120: judge whether the updating file collection finishes,, enter step 121 if finish; Otherwise, return step 102.
Step 121: judge whether the deletion of file and the variate-value of increase line number are 0, if, process ends; Otherwise, enter step 122.
Step 122: the deletion of file and the variate-value that increases line number are write as a result in the statistics file, and with this variate-value zero clearing.
Particularly, can confirm when carrying out step 122 that all file contents that need change have changed to finish, therefore final statistical information can have been write statistics file as a result.
Referring to Fig. 2, Fig. 2 is the file management process flow diagram of another embodiment of the present invention, and the specifically described statistical information processing procedure of this flow process may further comprise the steps:
Step 201: judge that whether current file path and title have write as a result in the statistics file, if write, finish the statistical information processing procedure; Otherwise, enter step 202.
Step 202: judge whether the deletion of file and the variate-value of increase line number are 0, if directly enter step 204; Otherwise, enter step 203.
Step 203: the deletion of file and the variate-value that increases line number are write as a result in the statistics file, and with this variate-value zero clearing.
Step 204: the path of the file of current variation and title are write as a result in the statistics file.
Referring to Fig. 3, Fig. 3 is the file management process flow diagram of further embodiment of this invention, and this flow process specifically described interpolation management information processing process may further comprise the steps:
Step 301: the form of obtaining management information according to file extension.
Step 302: obtain current system time.
Step 303: write show changing content begin the part management information.
Particularly, the descriptive information that statement, time (being current system time) and the user who increases the operation beginning can be set is inserted in the file with obtained management information format unification.
Step 304: document change content detection.
Step 305: judge according to document change content detection result whether interpolation information finishes,, enter step 306 if finish; Otherwise, return step 304.
Step 306: write the management information that shows the changing content latter end.
Particularly, the descriptive information that statement, time (being current system time) and the user who increases EO can be set is inserted in the file with obtained management information format unification.
In actual applications, the management information of insertion can select suitable form to show according to file extension, and reaching does not influence the effect that code file realizes function.And the management information format of insertion may be varied, and wherein a kind of form is as shown in table 1:
Figure G2010100342621D00061
Figure G2010100342621D00071
Table 1
By the above as seen, the present invention can count modification information for the user when carrying out file management, comprising: add line number; The deletion line number; Total line number that changes; The path and the filename that change.Automatically the position of locating and displaying management information, and all variation pieces begin to locate to show the time that adds management information, and deleting the position display management information of content, comprising: partial content has been deleted in statement herein; The recorded information that the explicit user unification provides is as function of this modification etc.
Have, can comprise in beginning that has increased the content change piece and latter end display management information: statement has increased partial content herein; The recorded information that the explicit user unification provides is as function of this modification etc.And, can select suitable form to show according to file extension in insertion management information, reaching does not influence the effect that code file realizes function.
Particularly, can count the modification information of file content, as: read in differential file information at the application differential technique, in the process of detection and updating file, according to the difference processing process record, the add up line number of deletion/interpolations of each file of record, the file path and the title of record variation simultaneously; When this document processing is finished, relevant information is appended to the end of file of specific log file.
Can locate the position of adding management information automatically, the up-to-date position is exactly the position of display management information usually, as: determine the information that current line need be deleted or needs add by differential technique, use the present invention afterwards and add the management information processing at this place, the follow-up position that can also continue to seek next place's interpolation management information by differential technique.
Can all variation pieces begin to locate to show the time that adds management information, as: after having located the position of inserting management information, obtain and insert current system time.
Can add management information in the position of having deleted content, as: confirm that in conjunction with differential technique the current operation that will carry out is the deletion content, then at first in this recorded information of inserting the statement and the initial appointment of user of deletion content (as the function of this modification etc., the user only need import a recorded information and get final product), use differential technique deletion corresponding content afterwards again.Also have the operation of increasing if confirm current location, can also comprise in beginning that has increased the content change piece and latter end display management information: statement has increased partial content herein; Show the unified recorded information that provides, as the function of this modification etc.
Particularly, if confirm that in conjunction with differential technique the current operation that will carry out is to increase partial content, then at first in this recorded information that insert to change statement and the initial appointment of user (as the function of this modification etc., the user only need import a recorded information and get final product), point out it is the beginning part of changing content simultaneously here.Use differential technique updating file information afterwards again.After upgrading end, insert the management information of changing content explanation and user's appointment once more, illustrate it is the position that change information finishes here.If confirm the existing deletion action of current location the operation of increasing is arranged again, so also can only insert the change management recording of information.
The operation thinking of Fig. 1 to Fig. 3 can be simplified as shown in Figure 4.Referring to Fig. 4, Fig. 4 is a file management general flow chart of the present invention, and this flow process may further comprise the steps:
Step 410: judge that change has taken place file content.
Step 420: generate the management information that is used to show the change situation at the file content that change takes place.
Described change may be to add and/or deletion, and can further carry out statistical operation at the change of file content.
By above flow process as seen, the inventive method can be added management information at the file that change takes place automatically; Can effectively increase work efficiency like this, make things convenient for management file.
In order to realize the above flow process, can enter setting as shown in Figure 5.Referring to Fig. 5, Fig. 5 is the document management apparatus figure of the embodiment of the invention, and this device comprises content alteration detecting unit, management information maintenance unit, the statistic unit that can link to each other in twos; Wherein, the management information maintenance unit comprises continuous management information interpolation decision-making module, management information format control module, management information interpolation execution module.
During concrete the application, the content alteration detecting unit can be used judgement file contents such as differential technique change has taken place, and give management information maintenance unit and statistic unit with this advisory, carry out by the management information maintenance unit and comprise that the management information that obtains management information format and obtain current system time adds operation; And the operating result that the management information maintenance unit can also further will be referred to above-mentioned management information interpolation operation sends to statistic unit, carries out statistical operation by statistic unit according to management information interpolation operating result and the file content change situation received.
In management information maintenance unit inside, management information is added decision-making module and is used to determine whether to add management information, and when determining to add management information notice management information format control module, by the definite management information format that will add of management information format control module, and this advisory added execution module to management information, add final execution of execution module by management information and comprise that the management information that obtains current system time adds operation.
The concrete operations that each functional entity can be realized among Fig. 5 are described in detail in Fig. 1 to 4, do not repeat them here.
Adding the involved file of management information, can be single file, also can be the file set that comprises a plurality of files.
In sum as seen, no matter be method or device, change has taken place in the equal decidable file content of the technology of the present invention, and generates the management information that is used to show the change situation at the file content that change takes place.Can effectively increase work efficiency like this, make things convenient for management file.
The above is preferred embodiment of the present invention only, is not to be used to limit protection scope of the present invention, all any modifications of being done within the spirit and principles in the present invention, is equal to and replaces and improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. file management method is characterized in that, this method comprises:
Judge that change has taken place file content, generate the management information that is used to show the change situation at the file content that change takes place.
2. method according to claim 1 is characterized in that described change is the deletion of file content, and the process that generates described management information comprises:
Obtain the form and the current system time of management information, statement, current system time and the descriptive information of deleting content is inserted in the file with obtained management information format unification.
3. method according to claim 1 is characterized in that described change is the increase of file content, and the process that generates described management information comprises:
Obtain the form and the current system time of management information; Write and show that changing content begins the management information of part, and after adding end of message (EOM), write the management information that shows the changing content latter end.
4. according to each described method of claim 1 to 3, it is characterized in that, the line number of change takes place in total line number of generation change and the current file in the current All Files of record that further adds up; The position that described change takes place is the position of inserting described management information.
5. according to each described method of claim 1 to 3, it is characterized in that, further comprise:
With the variate-value of the change line number of file content, and the path of the file of current variation and title write as a result in the statistics file.
6. according to each described method of claim 1 to 3, it is characterized in that change has taken place described judgement file content, realizes by differential technique.
7. method according to claim 1 is characterized in that, further comprises:
Confirming that all file contents that need change have changed finishes, and final statistical information is write statistics file as a result.
8. document management apparatus is characterized in that, this device comprises continuous content alteration detecting unit, management information maintenance unit; Wherein,
Described content alteration detecting unit is used to judge that change has taken place file content, and notifies described management information maintenance unit;
Described management information maintenance unit is used for generating the management information that is used to show the change situation at the file content that change takes place.
9. device according to claim 8 is characterized in that, further comprises statistic unit;
Described management information maintenance unit is further used for will be referred to management information and adds the operating result of operation and send to described statistic unit;
Described statistic unit is used for adding operating result according to the management information of receiving and carries out statistical operation at file content change situation.
10. according to Claim 8 or 9 described devices, it is characterized in that described management information maintenance unit comprises that continuous management information adds decision-making module, management information format control module, management information and add execution module; Wherein,
Described management information is added decision-making module, is used to determine whether to add management information, and notifies described management information format control module when determining to add management information;
Described management information format control module is used for the definite management information format that will add, and is notified to described management information interpolation execution module;
Described management information is added execution module, is used to carry out comprise that the management information that obtains current system time adds operation.
CN201010034262A 2010-01-18 2010-01-18 File managing method and file managing device Pending CN101739466A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201010034262A CN101739466A (en) 2010-01-18 2010-01-18 File managing method and file managing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201010034262A CN101739466A (en) 2010-01-18 2010-01-18 File managing method and file managing device

Publications (1)

Publication Number Publication Date
CN101739466A true CN101739466A (en) 2010-06-16

Family

ID=42462949

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201010034262A Pending CN101739466A (en) 2010-01-18 2010-01-18 File managing method and file managing device

Country Status (1)

Country Link
CN (1) CN101739466A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104933101A (en) * 2015-05-29 2015-09-23 南车株洲电力机车研究所有限公司 SVN-based method for automatic statistics of configuration audit information
CN106155750A (en) * 2016-07-29 2016-11-23 腾讯科技(深圳)有限公司 The loading method of a kind of resource file and device

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7418656B1 (en) * 2003-10-03 2008-08-26 Adobe Systems Incorporated Dynamic annotations for electronics documents

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7418656B1 (en) * 2003-10-03 2008-08-26 Adobe Systems Incorporated Dynamic annotations for electronics documents

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104933101A (en) * 2015-05-29 2015-09-23 南车株洲电力机车研究所有限公司 SVN-based method for automatic statistics of configuration audit information
CN104933101B (en) * 2015-05-29 2018-05-29 南车株洲电力机车研究所有限公司 A kind of configuration audit information method for automatically counting based on SVN
CN106155750A (en) * 2016-07-29 2016-11-23 腾讯科技(深圳)有限公司 The loading method of a kind of resource file and device
CN106155750B (en) * 2016-07-29 2018-09-07 腾讯科技(深圳)有限公司 A kind of loading method and device of resource file

Similar Documents

Publication Publication Date Title
CN108255925B (en) Method and terminal for displaying data table structure change condition
US9348581B2 (en) Systems, method and computer program products for tracking and viewing changes to information stored in a data structure
CN105144080B (en) System for metadata management
US9384177B2 (en) File history recording system, file history management system and file history recording method
US9922383B2 (en) Patent claims analysis system and method
CN109074383B (en) Document search with visualization within the context of a document
US20060106746A1 (en) Tracking usage of data elements in electronic business communications
CN108762743B (en) Data table operation code generation method and device
CN106201861A (en) The detection method of a kind of code quality and device
JP2005508552A (en) Memory system for data objects
CN104252452A (en) Data management method and device
CN101171571A (en) Apparatus for analysing and organizing artifacts in a software application
US20210326310A1 (en) System for tracking and displaying changes in a set of related electronic documents
AU2009238294A1 (en) Data transformation based on a technical design document
JP6090850B2 (en) Source program analysis system, source program analysis method and program
CN103329130A (en) Managing changes to collections of data
CN111367976A (en) Method and device for exporting EXCEL file data based on JAVA reflection mechanism
US20220075800A1 (en) System and method for computing and managing datasets using hierarchical analytics
CN114201615B (en) Scientific research data change review method and server based on data snapshot
US20120310893A1 (en) Systems and methods for manipulating and archiving web content
CN102866985B (en) For data formatter and the method for on-line analysing processing system
CN101739466A (en) File managing method and file managing device
US9384285B1 (en) Methods for identifying related documents
CN102171696B (en) The generation method and apparatus of customization data
JP5845961B2 (en) Information processing apparatus and information processing program

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C12 Rejection of a patent application after its publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20100616