CN102799608A - Method for quickly acquiring data - Google Patents

Method for quickly acquiring data Download PDF

Info

Publication number
CN102799608A
CN102799608A CN2012101772700A CN201210177270A CN102799608A CN 102799608 A CN102799608 A CN 102799608A CN 2012101772700 A CN2012101772700 A CN 2012101772700A CN 201210177270 A CN201210177270 A CN 201210177270A CN 102799608 A CN102799608 A CN 102799608A
Authority
CN
China
Prior art keywords
trigger messages
data
data dictionary
dictionary table
triggering message
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
CN2012101772700A
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.)
China Digital Video Beijing Ltd
Original Assignee
China Digital Video Beijing 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 China Digital Video Beijing Ltd filed Critical China Digital Video Beijing Ltd
Priority to CN2012101772700A priority Critical patent/CN102799608A/en
Publication of CN102799608A publication Critical patent/CN102799608A/en
Pending legal-status Critical Current

Links

Landscapes

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

Abstract

The invention discloses a method for quickly acquiring data. The method comprises the following steps of: receiving a first triggering message sent by a control system through a terminal; judging whether a triggering message which is the same as the first triggering message exists or not in a data dictionary sheet, and if the triggering message which is the same as the first triggering message exists in the data dictionary sheet, deleting the first triggering message, otherwise, storing the first triggering message into the data dictionary sheet, and starting a clock for setting delay time t; in the delay time, receiving a second triggering message sent by the control system through the terminal; judging whether a triggering message which is the same as the second triggering message exists or not in the data dictionary sheet, if the triggering message which is the same as the second triggering message exists in the data dictionary sheet, deleting the second triggering message; and acquiring the latest data from the control system through the terminal according to the triggering message in the data dictionary sheet. By the method, the utilization rate of a memory is reduced, and the efficiency for processing the data is improved.

Description

A kind of method of obtaining data fast
Technical field
The present invention relates to the data file process field, relate in particular to a kind of method of obtaining data fast.
Background technology
Files stored comprises program file and data file in the computing machine.Program file is system file just; Deposit the master file that relates to operating system in the system file; Generally in the installing operating system process, create automatically and associated documents are placed in the corresponding file folder, the file here directly influences the normal operation of system, and majority does not allow random change; And data file is used for the ephemeral data in the stored data base, can often change.During ephemeral data in the computer processing data file; What should handle is current data; Data after just changing, rather than historical data are so need the ephemeral data in system's ability real-time update data file; So that can in time empty the data in the data file after handling, in order to avoid the too much computer resource that takies.
In the prior art; Utilize the control of C++ coding when the data in the data file change; System can obtain file change information, but when obtaining file change information each all unavoidable trigger messages of obtaining twice identical file change continuously, computing machine receives twice trigger messages and will make a response to twice trigger messages; Handle accordingly; And twice processing procedure is identical, can cause the waste of computer resource like this, and the speed of computer processing data is reduced.So the prior art technical issues that need to address are how can the twice identical processing procedure of control end to trigger messages be reduced to once.
Summary of the invention
For addressing the above problem; The embodiment of the invention provides a kind of method of obtaining data fast; Compare the trigger messages of having stored in the trigger messages that receives and the data dictionary table through the terminal, the twice identical processing of control end to trigger messages is reduced to once, thus minimizing taking to computer resource; Improve data processing efficiency, improve real-time performance.
For achieving the above object, the embodiment of the invention discloses a kind of method of obtaining data fast, may further comprise the steps:
First trigger messages that the terminal receiving control system sends;
Whether said terminal judges has in the data dictionary table and the said first trigger messages identical triggering message, if delete said first trigger messages; If not, said first trigger messages is saved in the said data dictionary table, launches clock simultaneously, be used to set t time delay;
In said time delay t, second trigger messages that said terminal receiving control system sends;
Whether said terminal judges has in said data dictionary table and the said second trigger messages identical triggering message, if delete said second trigger messages; If not; Store said second trigger messages, wherein, no longer launch clock during said second trigger messages of said storage;
Said terminal obtains up-to-date data according to the trigger messages in the said data dictionary table to said control system.
Compared with prior art, the embodiment of the invention has the following advantages:
First trigger messages through the transmission of terminal receiving control system; Whether said terminal judges has in the data dictionary table and the said first trigger messages identical triggering message, if delete said first trigger messages; If not, said first trigger messages is saved in the said data dictionary table, launches clock simultaneously, be used to set t time delay; In said time delay t, second trigger messages that said terminal receiving control system sends; Whether said terminal judges has in said data dictionary table and the said second trigger messages identical triggering message, if delete said second trigger messages; Said terminal obtains up-to-date data according to the trigger messages in the said data dictionary table to said control system, thereby has reduced memory usage, has improved data processing efficiency.
Description of drawings
In order to be illustrated more clearly in the embodiment of the invention or technical scheme of the prior art; To do to introduce simply to the accompanying drawing of required use in embodiment or the description of the Prior Art below; Obviously, the accompanying drawing in describing below only is some embodiments of the present invention, for those of ordinary skills; Under the prerequisite of not paying creative work property, can also obtain other accompanying drawing according to these accompanying drawings.
Fig. 1 is the embodiment of the invention, a kind of process flow diagram that obtains the method for data fast.
Embodiment
To combine the accompanying drawing in the embodiment of the invention below, the technical scheme in the embodiment of the invention is carried out clear, intactly description, obviously, described embodiment is the present invention's part embodiment, rather than whole embodiment.Based on the embodiment among the present invention, those of ordinary skills are not making the every other embodiment that is obtained under the creative work prerequisite, all belong to the scope of the present invention's protection.
Embodiments of the invention provide a kind of method of obtaining data fast, and are as shown in Figure 1, specifically may further comprise the steps:
First trigger messages that step s101, terminal receiving control system send;
Wherein, said first trigger messages is meant when data file changes, the file change information that said control system is sent to said terminal.The function that control system utilizes Windows api function that Windows provides to concentrate is realized the monitoring to the data file, Windows api function collection be a cover each parts of being used for controlling Windows outward appearance and behavior one overlap predefined Windows function.The monitoring of using these functions that the data file is implemented; When data file such as is created, is modified, delete at the incident of operating; Function all can have corresponding reaction to incident; Produce file change information, and send to the terminal and the data file that changes is in time handled to remind the terminal.
Whether step s102, said terminal judges have in the data dictionary table and the said first trigger messages identical triggering message, if get into step s103; If not, get into step s104.
Step s103 deletes said first trigger messages;
Step s104 is saved in said first trigger messages in the said data dictionary table, launches clock simultaneously, is used to set t time delay;
Wherein, data dictionary is meant that data item to data, data structure, data stream, data storage, processing logic, external entity etc. define and describe, and its objective is each element in the data process flow diagram is made detailed explanation.Data dictionary is that a kind of user can the accessed record database and the catalogue of application program source data.The active data dictionary is meant that its content can be by the automatic data updated dictionary of DBMS when database or application structure are made amendment.Passive data dictionary is meant must the manual data dictionary that upgrades its content when revising.Data dictionary is the tables of data that one group of data is made explanations, and the data dictionary table is the tables of data that the data in the tables of data are made explanations.The trigger messages that file change of storage produces in the data dictionary, the trigger messages that the data of storing a plurality of files in the data dictionary table produce when changing.Concrete application is above-mentioned active data dictionary in the embodiment of the invention, just when data file changes, can trigger messages be saved in the data dictionary table automatically.
Said terminal receives first trigger messages that produces when data file changes; Trigger messages in itself and the data dictionary table is compared; If said first trigger messages is identical with trigger messages in the data dictionary table; The trigger messages that has just had this data file in the data dictionary table, rigidly connecting said first trigger messages of receiving so is useless to deal with data, directly with its deletion; If the trigger messages in said first trigger messages and the data dictionary table is inequality; The trigger messages of this data file not in the data dictionary table just; Rigidly connecting said first trigger messages of receiving so is useful to deal with data, and it is saved in the data dictionary table.
Because in the prior art; Utilize the C++ coding when obtaining file change information, all to obtain the trigger messages of twice identical file change continuously at every turn; If, in the time delay of a setting, also can receive once same trigger messages so received first trigger messages, so after will first trigger messages being saved to the data dictionary table; Set t time delay, wait for that same next time trigger messages arrives.
Step s105, in said time delay t, second trigger messages that said terminal receiving control system sends;
Received first trigger messages; And it is saved in the data dictionary table; In time delay t, just also can receive said second trigger messages, and said second trigger messages is the data file identical with first trigger messages trigger messages that control system is sent when changing.
Whether step s106, said terminal judges have in said data dictionary table and the said second trigger messages identical triggering message, if get into step s107; If not, get into step s108.
Step s107 deletes said second trigger messages;
Step s108 stores said second trigger messages, wherein, no longer launches clock during said second trigger messages of said storage;
Second trigger messages breath that said terminal will be received compares with the trigger messages in the data dictionary table; Because existing and its identical triggering message in the data dictionary table; Just said first trigger messages; So second trigger messages that receive at said terminal is useless to deal with data, directly its deletion is got final product.
Step s109, said terminal obtain up-to-date data according to the trigger messages in the said data dictionary table to said control system;
Wherein, the trigger messages in the said data dictionary table has uniqueness, possibly be one of following two kinds of situation only:
When said first trigger messages was identical with trigger messages in the said data dictionary table, the trigger messages in the former data dictionary table was the trigger messages in the said data dictionary table;
When the trigger messages in said first trigger messages and the said data dictionary table was inequality, first trigger messages was the trigger messages in the said data dictionary table.
Said terminal obtains the latest data in the file according to the file change information of the record of the trigger messages in the said data dictionary table.
The present invention has realized following beneficial effect: through first trigger messages of terminal receiving control system transmission; Whether said terminal judges has in the data dictionary table and the said first trigger messages identical triggering message, if delete said first trigger messages; If not, said first trigger messages is saved in the said data dictionary table, launches clock simultaneously, be used to set t time delay; In said time delay t, second trigger messages that said terminal receiving control system sends; Whether said terminal judges has in said data dictionary table and the said second trigger messages identical triggering message, if delete said second trigger messages; Said terminal obtains up-to-date data according to the trigger messages in the said data dictionary table to said control system, thereby has reduced memory usage, has improved data processing efficiency.
Through the description of above embodiment, those skilled in the art can be well understood to the present invention and can realize by the mode that software adds essential general hardware platform.Based on such understanding; The part that technical scheme of the present invention contributes to prior art in essence in other words can be come out with the embodied of software product; This computer software product is stored in the storage medium, comprises that some instructions are with so that a computer equipment (can be personal computer, server or the network equipment etc.) is carried out the described method of each embodiment of the present invention.
The above only is a preferred implementation of the present invention; Should be pointed out that for those skilled in the art, under the prerequisite that does not break away from the principle of the invention; Can also make some improvement and retouching, these improvement and retouching also should be regarded as protection scope of the present invention.

Claims (4)

1. a method of obtaining data fast is characterized in that, may further comprise the steps:
First trigger messages that the terminal receiving control system sends;
Whether said terminal judges has in the data dictionary table and the said first trigger messages identical triggering message, if delete said first trigger messages; If not, said first trigger messages is saved in the said data dictionary table, launches clock simultaneously, be used to set t time delay;
In said time delay t, second trigger messages that said terminal receiving control system sends;
Whether said terminal judges has in said data dictionary table and the said second trigger messages identical triggering message, if delete said second trigger messages; If not; Store said second trigger messages, wherein, no longer launch clock during said second trigger messages of said storage;
Said terminal obtains up-to-date data according to the trigger messages in the said data dictionary table to said control system.
2. method according to claim 1 is characterized in that, said first trigger messages and said second trigger messages are meant when data file changes, the file change information that said control system is sent to said terminal.
3. method according to claim 1 is characterized in that the trigger messages in the said data dictionary table has uniqueness and comprises:
When said first trigger messages was identical with trigger messages in the said data dictionary table, the trigger messages in the said data dictionary table was the trigger messages in the said data dictionary table;
When the trigger messages in said first trigger messages and the said data dictionary table was inequality, said first trigger messages was the trigger messages in the said data dictionary table.
4. method according to claim 1 is characterized in that said terminal obtains up-to-date data according to the trigger messages in the said data dictionary table to said control system and specifically comprises:
Said terminal obtains the latest data in the file according to the file change information of the record of the trigger messages in the said data dictionary table.
CN2012101772700A 2012-05-31 2012-05-31 Method for quickly acquiring data Pending CN102799608A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2012101772700A CN102799608A (en) 2012-05-31 2012-05-31 Method for quickly acquiring data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2012101772700A CN102799608A (en) 2012-05-31 2012-05-31 Method for quickly acquiring data

Publications (1)

Publication Number Publication Date
CN102799608A true CN102799608A (en) 2012-11-28

Family

ID=47198718

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2012101772700A Pending CN102799608A (en) 2012-05-31 2012-05-31 Method for quickly acquiring data

Country Status (1)

Country Link
CN (1) CN102799608A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1996854A (en) * 2006-12-22 2007-07-11 中国建设银行股份有限公司 Integrated processing system and method for the data exchange between different application systems
CN101504670A (en) * 2009-03-04 2009-08-12 成都市华为赛门铁克科技有限公司 Data operation method, system, client terminal and data server
US7885947B2 (en) * 2006-05-31 2011-02-08 International Business Machines Corporation Method, system and computer program for discovering inventory information with dynamic selection of available providers
CN101998682A (en) * 2009-08-27 2011-03-30 中兴通讯股份有限公司 Device and method for acquiring service content by personal network equipment and related device thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7885947B2 (en) * 2006-05-31 2011-02-08 International Business Machines Corporation Method, system and computer program for discovering inventory information with dynamic selection of available providers
CN1996854A (en) * 2006-12-22 2007-07-11 中国建设银行股份有限公司 Integrated processing system and method for the data exchange between different application systems
CN101504670A (en) * 2009-03-04 2009-08-12 成都市华为赛门铁克科技有限公司 Data operation method, system, client terminal and data server
CN101998682A (en) * 2009-08-27 2011-03-30 中兴通讯股份有限公司 Device and method for acquiring service content by personal network equipment and related device thereof

Similar Documents

Publication Publication Date Title
CN107332876B (en) Method and device for synchronizing block chain state
CN102917020B (en) A kind of method of mobile terminal based on packet and operation system data syn-chronization
US7606808B2 (en) Maintaining and establishing subscriptions with load-balanced servers
WO2016206600A1 (en) Information flow data processing method and device
US20160330208A1 (en) Method and apparatus for implementing document sharing between user groups
CN104219316A (en) Method and device for processing call request in distributed system
CN104834558A (en) Method and system for processing data
CN105589658B (en) Resource processing method, system and server, and warehouse management method and device
CN102769640A (en) Method, server and system for user information updating
CN103684808A (en) Method for sending broadcast messages and server
US20210029198A1 (en) Data synchronization method and synchronization service device
CN102799609A (en) Data acquisition method based on data monitoring
CN104219639A (en) Method and device for displaying text message record
US20120005280A1 (en) Message thread management using dynamic pointers
CN109543088A (en) User comment processing method, device, equipment and storage medium
CN105718569A (en) Method, device and system for uploading compound document
CN103037000A (en) Publish-subscribe system and notification message processing method thereof
EP2224381A1 (en) Method and apparatus for case-based service composition
US20120102168A1 (en) Communication And Coordination Between Web Services In A Cloud-Based Computing Environment
US7437733B2 (en) System and method for using a mobile agent object to collect data
CN112969198A (en) Data transmission method, terminal and storage medium
CN102456005A (en) High-data-volume file processing method and system
CN102378123A (en) Processing method of temporary group and group system
CN104283763A (en) Service system for transmitting electronic mail with large-information-amount attachment and method for sending and receiving electronic mail
CN107786661B (en) Information synchronization 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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20121128