CN106250107A - A kind of data statistical approach and system - Google Patents
A kind of data statistical approach and system Download PDFInfo
- Publication number
- CN106250107A CN106250107A CN201610564802.4A CN201610564802A CN106250107A CN 106250107 A CN106250107 A CN 106250107A CN 201610564802 A CN201610564802 A CN 201610564802A CN 106250107 A CN106250107 A CN 106250107A
- Authority
- CN
- China
- Prior art keywords
- click
- event
- click event
- module
- function
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/40—Transformation of program code
- G06F8/41—Compilation
- G06F8/43—Checking; Contextual analysis
- G06F8/433—Dependency analysis; Data or control flow analysis
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Telephonic Communication Services (AREA)
Abstract
The technical problem to be solved is: provide a kind of data statistical approach and system, it is achieved reusable, lower coupling, the data statistical approach of easy care.The present invention is used for identifying each click event and calling the function corresponding with click event by presetting the first click method, records described click event and is called;The system click method that will click on triggering replaces with the first click method;Described system clicks on method for calling the function corresponding with described click event.Achieve the general method of use to carry out burying an acquisition user data and data being added up, thus realize the data statistical approach of reusable and lower coupling, thus improve the maintainability of program code.
Description
Technical field
The present invention relates to Computer Applied Technology field, particularly relate to a kind of data statistical approach and system.
Background technology
Data can be added up, and then analyze the hobby of user by burying an acquisition user data, improve application.?
Ensureing that mobile terminal flow will not be by the premise of considerable influence, it is the widest more good that product managers always want to bury a coverage rate.Mesh
The way of front routine is to be packaged into tool-class by burying point code, as long as needing in engineering to bury point (as clicked on event, page jump)
Place be all inserted into burying point code.As, in order to add up the number of clicks of certain button control, at the execution code that this button is corresponding
Point code is buried in rear insertion, described in bury point code for adding up the number of clicks of this button control.But, once project is more and more multiple
Miscellaneous, bury code a little and be scattered in each corner of program, be unfavorable for safeguarding and multiplexing.
Summary of the invention
The technical problem to be solved is: provide a kind of data statistical approach and system, it is achieved reusable, low coupling
Close, the data statistical approach of easy care.
In order to solve above-mentioned technical problem, the technical solution used in the present invention is:
The present invention provides a kind of data statistical approach, including step:
The first click method of presetting is for identifying each click event and calling the function corresponding with click event, record
Described click event is called;
The system click method that will click on triggering replaces with the first click method;Described system click on method be used for calling with
The function that described click event is corresponding.
The present invention provides a kind of data statistics system, including:
Presetting module, is used for the first click method of presetting for identifying each click event and calling relative with click event
The function answered, records described click event and is called;
Replacement module, replaces with the first click method for will click on the system click method of triggering;Described system is clicked on
Method is for calling the function corresponding with described click event.
Above-mentioned data statistical approach and system, it has the beneficial effects that: replace with can know by system is clicked on method
Each click event other also calls the function corresponding with click event, records the invoked first click side of described click event
Method, it is achieved that general method can be used to carry out burying an acquisition user data and data being added up, thus realize reusable
And the data statistical approach of lower coupling, thus improve the maintainability of program code.
Accompanying drawing explanation
Fig. 1 is the FB(flow block) of a kind of data statistical approach of the present invention;
Fig. 2 is the structured flowchart of a kind of data statistics system of the present invention;
Label declaration:
1, presetting module;2, replacement module;
21, the first acquisition module;22, the second acquisition module;23, address Transpose module.
Detailed description of the invention
By describing the technology contents of the present invention in detail, being realized purpose and effect, below in conjunction with embodiment and coordinate attached
Figure is explained.
The design of most critical of the present invention is: replaces with each click event recognizable by system is clicked on method and adjusts
With the function corresponding with the event of click, record the invoked first click method of described click event, it is achieved that can use logical
Method carry out burying and obtain user data and data are added up.
Refer to Fig. 1 and Fig. 2:
As it is shown in figure 1, the present invention provides a kind of data statistical approach, including step:
The first click method of presetting is for identifying each click event and calling the function corresponding with click event, record
Described click event is called;
The system click method that will click on triggering replaces with the first click method;Described system click on method be used for calling with
The function that described click event is corresponding.
Further, described first click method includes:
Recognition methods, execution method and statistical method;
Described recognition methods is used for identifying click event;
Described execution method is for calling and performing the function corresponding with click event;
Described statistical method is for adding up each number of operations clicking on event.
Seen from the above description, described first click method can recognize that each click event and calls relative with click event
The function answered, records described click event and is called.
Further, will click on triggering system click on method replace with the first click method particularly as follows:
Obtain and click on the system click object that method is corresponding with system;
Obtain and click on the first click object that method is corresponding with first;
Exchange described system and click on object and the address of described first click object.
Seen from the above description, will click on the system of triggering to click on method and replace with the first click method user can be made to click on
The first click method is triggered during button control.
Further, described recognition methods particularly as follows:
Obtain the method name corresponding with button control;
According to described method name, obtain click event said module title;
Obtain the label corresponding with button control;
According to described module title and described label, obtain the function title that click event is corresponding.
Seen from the above description, may recognize that click event by above-mentioned recognition methods.
Further, described execution method particularly as follows:
Call the function corresponding with click event;
Perform described function.
Seen from the above description, the function corresponding with click event can be performed by above-mentioned execution method.
Further, described statistical method particularly as follows:
Upload the ID that click event is corresponding;
Add up the number of operations of click event corresponding for described ID.
The number of operations of click event corresponding for the described ID of above-mentioned statistics, has two kinds of implementations,
First implementation: obtain the ID that click event is corresponding;Sum corresponding for described ID is added 1.
Second implementation: obtain and store the ID that click event is corresponding;Add up number corresponding to described ID.
Seen from the above description, can the counting user clicking operation number of times to button control by above-mentioned statistical method.
As in figure 2 it is shown, the present invention provides a kind of data statistics system, including:
Presetting module 1, is used for the first click method of presetting for identifying each click event and calling and click on event phase
Corresponding function, records described click event and is called;
Replacement module 2, replaces with the first click method for will click on the system click method of triggering;Described system is clicked on
Method is for calling the function corresponding with described click event.
Further, described replacement module includes:
First acquisition module 21, clicks on, for obtaining, the system click object that method is corresponding with system;
Second acquisition module 22, clicks on, for obtaining, the first click object that method is corresponding with first;
Address Transpose module 23, clicks on object and the address of described first click object for exchanging described system.
Seen from the above description, click on the address of method by exchanging the first click method and system, user's point can be realized
Trigger, when hitting button control, the first click method of execution.
Embodiments of the invention one are:
The number of clicks method being used for adding up certain button control in prior art is: clicking trigger system clicks on method,
System clicks on method for calling the function corresponding with described click event;The function that event is corresponding is hit when performing fixed point
After, the clicking operation number of times of this button control is added up.The present invention is for adding up the number of clicks side of certain button control
Method is: the first click method of presetting, for identifying each click event and calling the function corresponding with click event, records institute
State click event to be called;The system click method that will click on triggering replaces with the first click method;When user clicks on button control
During part, triggering the first click method, the first click method identifies the click event that button control that user clicked on is corresponding, note
Recording the title of described click event and upload onto the server, the number of clicks of server statistics button control, first clicks on method
Call the function corresponding with described click event.
Embodiment based on iOS operating system is:
Rewrite the load method of button class, particularly as follows: click on function according to the button control of iOS operating system
SendAction:to:forEvent, clicks on function swiz_sendAction:to:forEvent, is used for identifying for self-defined one
Each click event also calls the function corresponding with click event, records described click event and is called, and the ginseng of this function
It is identical that number clicks on function with the button control of system;The function class_getInstanceMethod using iOS operating system obtains
Obtain the Method object of function sendAction:to:forEvent and function swiz_sendAction:to:forEvent
MethodSend, methodSwizSend;Use function class_replaceMethod or the function of iOS operating system
Method_exchangeImplementations carries out function exchange to methodSend and methodSwizSend.
When user clicks on certain button control, the load method of trigger button class, load method is by the button control of system
Part is clicked on function and is exchanged with self-defining click function.Therefore, perform after user clicks on certain button control is self-defining
Click on function, perform process particularly as follows: pass through the side of the function NSStringFromSelector acquisition action of iOS operating system
Religious name actionName, obtains click event said module, and e.g., the actionName of subject tool model is
SubjectClick, the actionName of calculator modules are calc;Obtain the tag word of the UIControl of iOS operating system
Section, obtains click event concrete function in described module, and e.g., the tag of the subfunction planting tool of subject instrument is 0214,
The tag touching ball function is 0220;After identifying click event, from code library, transfer corresponding function and perform;Will click on thing
The ID of part is uploaded to clicking operation statistical system by http agreement, wherein click on the ID of event be according to actionName and
Tag determines, is the value appointed with clicking operation statistical system;Clicking operation statistical system obtains the ID of click event, and
Sum corresponding for described ID is added 1, obtains the user operation number of times of this button control current.
In sum, the present invention provides a kind of data statistical approach and system, can by system clicks on method replaces with
Identify each click event and call the function corresponding with click event, recording described click event invoked first and click on
Method, it is achieved that general method can be used to carry out burying an acquisition user data and data being added up, thus realize answering
With and the data statistical approach of lower coupling, thus improve the maintainability of program code;Further, by obtaining button
Method name that control is corresponding and label, identify click event;Further, by obtaining and to add up click event corresponding
ID, obtains the number of operations of click event.
The foregoing is only embodiments of the invention, not thereby limit the scope of the claims of the present invention, every utilize this
The equivalents that bright description and accompanying drawing content are made, or directly or indirectly it is used in relevant technical field, the most in like manner include
In the scope of patent protection of the present invention.
Claims (10)
1. a data statistical approach, it is characterised in that including:
The first click method of presetting is for identifying each click event and calling the function corresponding with click event, and record is described
Click event is called;
The system click method that will click on triggering replaces with the first click method;Described system is clicked on method and is used for calling with described
The function that click event is corresponding.
A kind of data statistical approach the most according to claim 1, it is characterised in that described first click method includes:
Recognition methods, execution method and statistical method;
Described recognition methods is used for identifying click event;
Described execution method is for calling and performing the function corresponding with click event;
Described statistical method is for adding up each number of operations clicking on event.
A kind of data statistical approach the most according to claim 1, it is characterised in that the system that will click on triggering clicks on method
Replace with the first click method particularly as follows:
Obtain and click on the system click object that method is corresponding with system;
Obtain and click on the first click object that method is corresponding with first;
Exchange described system and click on object and the address of described first click object.
A kind of data statistical approach the most according to claim 2, it is characterised in that described recognition methods particularly as follows:
Obtain the method name corresponding with button control;
According to described method name, obtain click event said module title;
Obtain the label corresponding with button control;
According to described module title and described label, obtain the function title that click event is corresponding.
A kind of data statistical approach the most according to claim 2, it is characterised in that described execution method particularly as follows:
Call the function corresponding with click event;
Perform described function.
A kind of data statistical approach the most according to claim 2, it is characterised in that described statistical method particularly as follows:
Upload the ID that click event is corresponding;
Add up the number of operations of click event corresponding for described ID.
7. a data statistics system, it is characterised in that including:
Presetting module, for presetting the first click method for identifying each click event and calling corresponding with click event
Function, records described click event and is called;
Replacement module, replaces with the first click method for will click on the system click method of triggering;Described system clicks on method
For calling the function corresponding with described click event.
A kind of data statistics system the most according to claim 7, it is characterised in that including:
Identification module, is used for identifying click event;
Perform module, for calling and performing the function corresponding with click event;
Statistical module, for adding up each number of operations clicking on event.
A kind of data statistics system the most according to claim 7, it is characterised in that described replacement module includes:
First acquisition module, clicks on, for obtaining, the system click object that method is corresponding with system;
Second acquisition module, clicks on, for obtaining, the first click object that method is corresponding with first;
Address Transpose module, clicks on object and the address of described first click object for exchanging described system.
A kind of data statistics system the most according to claim 8, it is characterised in that described identification module includes:
3rd acquisition module, for obtaining the method name corresponding with button control;
4th acquisition module, for according to described method name, obtains click event said module title;
5th acquisition module, for obtaining the label corresponding with button control;
6th acquisition module, for according to described module title and described label, obtains the function title that click event is corresponding.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610564802.4A CN106250107A (en) | 2016-07-18 | 2016-07-18 | A kind of data statistical approach and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610564802.4A CN106250107A (en) | 2016-07-18 | 2016-07-18 | A kind of data statistical approach and system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106250107A true CN106250107A (en) | 2016-12-21 |
Family
ID=57613791
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610564802.4A Pending CN106250107A (en) | 2016-07-18 | 2016-07-18 | A kind of data statistical approach and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106250107A (en) |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106649120A (en) * | 2016-12-28 | 2017-05-10 | 中国银联股份有限公司 | Data acquisition method, and data analysis method and system |
CN106897202A (en) * | 2017-02-28 | 2017-06-27 | 百度在线网络技术(北京)有限公司 | For the method and apparatus of output data |
CN106933472A (en) * | 2017-05-20 | 2017-07-07 | 南京西桥科技有限公司 | A kind of user behavior data acquisition system and its control method based on mobile phone A PP |
CN108763016A (en) * | 2018-05-15 | 2018-11-06 | 广州市千钧网络科技有限公司 | A kind of method and device of acquisition user behavior data |
CN109522189A (en) * | 2017-09-19 | 2019-03-26 | 北京国双科技有限公司 | A kind of data monitoring method, apparatus and system |
CN109582526A (en) * | 2017-09-28 | 2019-04-05 | 北京国双科技有限公司 | A kind of data capture method and device |
CN111767107A (en) * | 2020-06-23 | 2020-10-13 | 杭州萤石软件有限公司 | Visual display method and system for information |
CN112181770A (en) * | 2020-09-28 | 2021-01-05 | 北京达佳互联信息技术有限公司 | Method, device and system for setting buried object |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101685451A (en) * | 2008-09-27 | 2010-03-31 | 国际商业机器公司 | Method for monitoring events in browser, event monitoring device and browser equipment |
US20110004602A1 (en) * | 2009-07-01 | 2011-01-06 | Huawei Technologies Co., Ltd. | Method for generating widget icon, apparatus for generating widget summary information file, and widget engine |
CN103365542A (en) * | 2013-07-01 | 2013-10-23 | 携程计算机技术(上海)有限公司 | User click behavior showing method and system |
CN104408204A (en) * | 2014-12-18 | 2015-03-11 | 北京国双科技有限公司 | Method and device for obtaining webpage page link address |
CN104980417A (en) * | 2014-08-06 | 2015-10-14 | 腾讯科技(深圳)有限公司 | UGC file distribution method and equipment |
-
2016
- 2016-07-18 CN CN201610564802.4A patent/CN106250107A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101685451A (en) * | 2008-09-27 | 2010-03-31 | 国际商业机器公司 | Method for monitoring events in browser, event monitoring device and browser equipment |
US20110004602A1 (en) * | 2009-07-01 | 2011-01-06 | Huawei Technologies Co., Ltd. | Method for generating widget icon, apparatus for generating widget summary information file, and widget engine |
CN103365542A (en) * | 2013-07-01 | 2013-10-23 | 携程计算机技术(上海)有限公司 | User click behavior showing method and system |
CN104980417A (en) * | 2014-08-06 | 2015-10-14 | 腾讯科技(深圳)有限公司 | UGC file distribution method and equipment |
CN104408204A (en) * | 2014-12-18 | 2015-03-11 | 北京国双科技有限公司 | Method and device for obtaining webpage page link address |
Non-Patent Citations (2)
Title |
---|
(美)扎德尔斯基: "《IOS应用安全攻防》", 30 June 2012, 东南大学出版社 * |
张洪明等: "《ASP与网页数据库设计项目开发与案例教程》", 30 September 2015, 科学技术出版社 * |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106649120A (en) * | 2016-12-28 | 2017-05-10 | 中国银联股份有限公司 | Data acquisition method, and data analysis method and system |
CN106897202A (en) * | 2017-02-28 | 2017-06-27 | 百度在线网络技术(北京)有限公司 | For the method and apparatus of output data |
CN106933472A (en) * | 2017-05-20 | 2017-07-07 | 南京西桥科技有限公司 | A kind of user behavior data acquisition system and its control method based on mobile phone A PP |
CN109522189A (en) * | 2017-09-19 | 2019-03-26 | 北京国双科技有限公司 | A kind of data monitoring method, apparatus and system |
CN109522189B (en) * | 2017-09-19 | 2022-06-21 | 北京国双科技有限公司 | Data monitoring method, device and system |
CN109582526A (en) * | 2017-09-28 | 2019-04-05 | 北京国双科技有限公司 | A kind of data capture method and device |
CN108763016A (en) * | 2018-05-15 | 2018-11-06 | 广州市千钧网络科技有限公司 | A kind of method and device of acquisition user behavior data |
CN111767107A (en) * | 2020-06-23 | 2020-10-13 | 杭州萤石软件有限公司 | Visual display method and system for information |
CN112181770A (en) * | 2020-09-28 | 2021-01-05 | 北京达佳互联信息技术有限公司 | Method, device and system for setting buried object |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106250107A (en) | A kind of data statistical approach and system | |
WO2020233015A1 (en) | Link tracking method and apparatus | |
CN107295050A (en) | Front end user behavioral statisticses method and device | |
CN103440092B (en) | A kind of processing method returning button, system and mobile terminal | |
CN104899016B (en) | Allocating stack Relation acquisition method and device | |
CN108459962A (en) | Code specification detection method, device, terminal device and storage medium | |
CN104765689B (en) | A kind of interface capability data supervise method and apparatus in real time | |
CN104572813B (en) | A kind of report generation method and device | |
CN106528372B (en) | Program operation monitoring system and method | |
CN104778121A (en) | Game program test method, device and system | |
WO2019085307A1 (en) | Data sampling method, terminal, and device, and computer readable storage medium | |
CN103631712B (en) | A kind of medelling software critical behavior tracking based on memory management | |
CN104298788A (en) | Paging querying method and system | |
CN105677311A (en) | Identification method and device for function call relationships | |
CN103176892A (en) | Page monitoring method and system | |
CN107729063A (en) | Call method, device and the terminal of SDK | |
CN108108248A (en) | A kind of CPU+GPU cluster management methods, device and equipment for realizing target detection | |
CN108491122A (en) | A kind of click event response method, computer readable storage medium and terminal device | |
CN109144834A (en) | Acquisition method and device, the Android system and terminal device of user behavior data | |
CN104219639A (en) | Method and device for displaying text message record | |
CN107678955A (en) | A kind of computational methods, device, equipment and the storage medium of functional interface time delay | |
CN105653133A (en) | Extension method and device of application programs | |
CN106469115A (en) | A kind of telecommunication network management automatic software test method and device | |
CN106201841A (en) | The statistical method of a kind of application program service data and device | |
WO2020073200A1 (en) | Program debugging method and system |
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 |
Application publication date: 20161221 |
|
RJ01 | Rejection of invention patent application after publication |