Movatterモバイル変換


[0]ホーム

URL:


CN110908880A - Embedded point code injection method, event reporting method and related equipment thereof - Google Patents

Embedded point code injection method, event reporting method and related equipment thereof
Download PDF

Info

Publication number
CN110908880A
CN110908880ACN201911060651.9ACN201911060651ACN110908880ACN 110908880 ACN110908880 ACN 110908880ACN 201911060651 ACN201911060651 ACN 201911060651ACN 110908880 ACN110908880 ACN 110908880A
Authority
CN
China
Prior art keywords
buried point
event
class
point
buried
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.)
Granted
Application number
CN201911060651.9A
Other languages
Chinese (zh)
Other versions
CN110908880B (en
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 Kingsoft Internet Security Software Co Ltd
Original Assignee
Beijing Kingsoft Internet Security 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 Kingsoft Internet Security Software Co LtdfiledCriticalBeijing Kingsoft Internet Security Software Co Ltd
Priority to CN201911060651.9ApriorityCriticalpatent/CN110908880B/en
Publication of CN110908880ApublicationCriticalpatent/CN110908880A/en
Application grantedgrantedCritical
Publication of CN110908880BpublicationCriticalpatent/CN110908880B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Classifications

Landscapes

Abstract

The application discloses a buried point code injection method, an event reporting method and related equipment thereof, wherein the buried point code injection method comprises the steps of acquiring buried point codes corresponding to buried points according to buried point requirements; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project. The method is characterized in that the embedded point requirements are analyzed, the implementation structure is redesigned, so that an independent functional module is formed, each embedded point is defined into a class in advance, the embedded point classes are uniformly defined into a proxy class, and the embedded point classes are called in the proxy class, so that the uniformity of interfaces is maintained, and the efficiency of adding, modifying and understanding the embedded points is improved.

Description

Embedded point code injection method, event reporting method and related equipment thereof
Technical Field
The present application relates to the field of computer application technologies, and in particular, to a buried point code injection method, an event reporting method, and related devices.
Background
With the rapid development of internet technology, various internet-based Application programs (apps) are produced, and in order to verify whether the business logic of the Application program is smooth and the use condition of the function as a whole, it is necessary to obtain the data index of the Application program by adding a buried point in the Application program for verification. For example, when a game program is developed, a buried point needs to be added at a stage before the game program is online, so as to count the behavior of a user, for example, 10 commodities exist in a page of a game store, the purchased quantity of the 10 commodities is counted by adding the buried point, which commodity is sold better can be known through data counted by the buried point, and optimization adjustment is made on the game program. Therefore, through the buried point, the use condition of the current application program function by the user can be known, and the application program can be better optimized and improved.
However, since there are a lot of points buried in the actual development process, which is several tens to hundreds, and the points buried are more complicated and detailed, such as lottery statistics, not only the number of lotteries is counted, but also it may be necessary to count the page clicked by the user before the lottery is clicked, the total amount of money spent in the lottery, and the reason for failure if the lottery fails, etc. Therefore, in the related art, different embedded points are defined in each function module of the application program to perform statistics of various types of data, but defining the embedded points in different modules causes inconvenience in finding embedded point codes, increases time for reading the codes, and particularly when a requirement is changed, causes a current embedded point to be unsuitable to be defined in a current module, and redefines the embedded point position, thereby reducing development efficiency.
Disclosure of Invention
The object of the present application is to solve at least to some extent one of the above mentioned technical problems.
Therefore, a first objective of the present application is to provide a method for injecting embedded point codes, which analyzes embedded point requirements, redesigns an implementation structure of the embedded point requirements to form independent functional modules, defines each embedded point into a class in advance, uniformly defines the embedded point classes into a proxy class, and calls the embedded point classes in the proxy class, so as to maintain the uniformity of interfaces and improve the efficiency of adding, modifying and understanding the embedded points.
A second objective of the present application is to provide an event reporting method.
A third object of the present application is to provide a buried point code injection device.
A fourth objective of the present application is to provide an event reporting apparatus.
A fifth object of the present application is to provide an electronic device.
A sixth object of the present application is to propose a computer-readable storage medium.
A seventh object of the present application is to propose another electronic device.
An eighth object of the present application is to propose another computer-readable storage medium.
In order to achieve the above object, a first embodiment of the present application provides a method for embedded point code injection, including: acquiring a buried point code corresponding to a buried point according to the buried point requirement; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project.
According to the embedded point code injection method, embedded point codes corresponding to embedded points are obtained according to embedded point requirements; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project. According to the method, embedded point requirements are analyzed, corresponding embedded point codes are generated through a predefined proxy class and a predefined embedded point class, and then the embedded point codes are injected to corresponding positions.
According to an embodiment of the present application, acquiring a buried point code corresponding to a buried point according to a buried point requirement includes:
acquiring a corresponding target buried point class from a predefined proxy class according to the buried point requirement; acquiring corresponding target parameters from corresponding target buried point classes according to the buried point requirements; and generating a buried point code corresponding to the buried point according to the proxy class, the corresponding target buried point class and the corresponding target parameter.
According to an embodiment of the present application, the buried point code injection method further includes: predefining an agent class; defining all corresponding embedded point classes in the proxy class in advance according to the service requirements of the target project; and defining all parameters of each buried point class in all the buried point classes.
To achieve the above object, a second aspect of the present application provides an event reporting method, including: when an event with a preset buried point is triggered, acquiring the event; extracting total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; determining target parameters to be uploaded under the buried point according to the scene injected by the buried point; generating corresponding event statistical information to be reported according to the target parameters to be uploaded under the buried point and the total statistical information of the event; and reporting the event and the statistical information of the event to be reported.
The event reporting method of the embodiment of the application acquires an event with a preset embedded point when the event is triggered; extracting total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; determining target parameters to be uploaded under the buried point according to the scene injected by the buried point; generating corresponding event statistical information to be reported according to the target parameters to be uploaded under the buried point and the total statistical information of the event; and reporting the event and the statistical information of the event to be reported. The method can improve the efficiency of adding, modifying and understanding the embedded point codes by respectively defining each embedded point into a class in advance, uniformly defining the embedded point classes into an agent class and further generating the corresponding embedded point codes by the predefined agent class and the predefined embedded point class, and can maintain the uniformity of interfaces by calling the embedded point classes in the agent class, so that if a certain embedded point class is required to be found, the agent class can be directly found. In addition, different parameter values are initialized according to the scene injected by the buried point, the target parameter to be uploaded under the buried point is determined, and the corresponding statistical information of the event to be reported is generated according to the target parameter to be uploaded under the buried point and the total statistical information of the event. Therefore, reporting of other parameters irrelevant to behaviors is avoided, and accuracy of event reporting is improved.
According to an embodiment of the present application, the event reporting method further includes: determining event reporting time according to the type of the embedded point; and when the current state meets the event reporting opportunity, executing the step of extracting the total statistical information of the event.
According to an embodiment of the present application, generating corresponding event statistical information to be reported according to the target parameter to be uploaded under the embedded point and the total statistical information of the event includes: acquiring statistical information corresponding to the target parameter from the total statistical information of the event; setting statistical information corresponding to other parameters except the target parameter under the buried point as a target threshold; and generating corresponding event statistical information to be reported according to the statistical information corresponding to the target parameter and the statistical information corresponding to the other parameters.
According to one embodiment of the present application, the target threshold is thenumber 0 or the character "null".
In order to achieve the above object, a third embodiment of the present application provides a buried point code injection apparatus, including: the embedded point code acquisition module is used for acquiring embedded point codes corresponding to embedded points according to embedded point requirements; the buried point code is generated through a predefined proxy class and a predefined buried point class, wherein the buried point class is defined in the proxy class; the buried point injection position determining module is used for determining a target position capable of acquiring the buried point requirement in a target project according to the buried point requirement; and the buried point injection module is used for injecting the buried point codes of the corresponding buried points into the target position of the target project.
According to the embedded point code injection device, embedded point codes corresponding to embedded points are obtained according to embedded point requirements; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project. The device can realize that a corresponding embedded point code is generated by a predefined agent class and a predefined embedded point class through analyzing the embedded point requirement, and then the embedded point code is injected to a corresponding position.
According to an embodiment of the present application, the buried point code obtaining module is specifically configured to: acquiring a corresponding target embedded point class from the predefined proxy class according to the embedded point requirement; acquiring corresponding target parameters from the corresponding target buried point classes according to the buried point requirements; and generating a buried point code corresponding to the buried point according to the proxy class, the corresponding target buried point class and the corresponding target parameter.
According to an embodiment of the present application, the buried point code injection apparatus further includes: and the pre-defining module is used for pre-defining an agent class, pre-defining all corresponding embedded point classes in the agent class according to the service requirement of the target project, and defining all parameters of all embedded point classes in all the embedded point classes.
To achieve the above object, a fourth aspect of the present application provides an event reporting apparatus, including: the event acquisition module is used for acquiring an event with a preset buried point when the event is triggered; the extraction module is used for extracting the total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; the to-be-uploaded parameter determination module is used for determining target parameters to be uploaded under the buried point according to the scene injected by the buried point; a to-be-reported event statistical information generation module, configured to generate corresponding to-be-reported event statistical information according to the target parameter to be uploaded under the buried point and the total statistical information of the event; and the reporting module is used for reporting the event and the statistical information of the event to be reported.
The event reporting device of the embodiment of the application acquires an event when the event with a preset embedded point is triggered; extracting total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; determining target parameters to be uploaded under the buried point according to the scene injected by the buried point; generating corresponding event statistical information to be reported according to the target parameters to be uploaded under the buried point and the total statistical information of the event; and reporting the event and the statistical information of the event to be reported. The device defines each embedded point into a class in advance, defines the embedded point classes into a proxy class in a unified way, and generates corresponding embedded point codes through the predefined proxy class and the predefined embedded point class, so that the efficiency of adding, modifying and understanding the embedded point codes can be improved, and the embedded point classes are called in the proxy class, so that the uniformity of interfaces is kept, and if a certain embedded point class is required to be found, the proxy class can be directly found. In addition, different parameter values are initialized according to the scene injected by the buried point, the target parameter to be uploaded under the buried point is determined, and the corresponding statistical information of the event to be reported is generated according to the target parameter to be uploaded under the buried point and the total statistical information of the event. Therefore, other parameters irrelevant to the reporting behavior are prevented from being reported, and the accuracy of reporting the event is improved.
According to an embodiment of the present application, the event reporting apparatus further includes: an event reporting time determining module, configured to determine an event reporting time according to the type of the embedded point; wherein the extraction module is specifically configured to: and when the current state meets the event reporting opportunity, extracting the total statistical information of the event.
According to an embodiment of the present application, the to-be-reported event statistic information generating module is specifically configured to: acquiring statistical information corresponding to the target parameter from the total statistical information of the event; setting statistical information corresponding to other parameters except the target parameter under the buried point as a target threshold; and generating corresponding event statistical information to be reported according to the statistical information corresponding to the target parameter and the statistical information corresponding to the other parameters.
According to one embodiment of the present application, the target threshold is thenumber 0 or the character "null".
To achieve the above object, an embodiment of a fifth aspect of the present application provides an electronic device, including: the embedded point code injection method comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein when the processor executes the computer program, the embedded point code injection method is realized.
To achieve the above object, a sixth aspect of the present application provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method for embedded code injection according to the first aspect of the present application.
To achieve the above object, a seventh embodiment of the present application provides an electronic device, including: the event reporting method includes that the event reporting method is implemented when the processor executes the computer program.
To achieve the above object, an eighth aspect of the present application provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the event reporting method according to the second aspect of the present application.
Additional aspects and advantages of the present application will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the present application.
Drawings
The above and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
fig. 1 is a flow chart illustrating a buried point code injection method according to an embodiment of the present application.
FIG. 2 is a diagram of a buried point class code according to one embodiment of the present application.
FIG. 3 is a schematic diagram of a proxy class and a buried point class structure according to one embodiment of the present application.
Fig. 4 is a flow chart illustrating a buried point code injection method according to another embodiment of the present application.
FIG. 5 is a diagram of different scene location codes according to one embodiment of the present application.
Fig. 6 is a flowchart illustrating an event reporting method according to an embodiment of the present application.
Fig. 7 is a schematic diagram of a buried point to-be-uploaded parameter code according to an embodiment of the present application.
Fig. 8 is a schematic diagram of the structure of the agent class and the buried point class according to another embodiment of the present application.
FIG. 9 is a schematic diagram of a buried point code injection apparatus according to one embodiment of the present application.
Fig. 10 is a schematic structural diagram of a buried point code injection device according to another embodiment of the present application.
Fig. 11 is a schematic structural diagram of an event reporting apparatus according to an embodiment of the present application.
Fig. 12 is a schematic structural diagram of an event reporting apparatus according to another embodiment of the present application.
FIG. 13 illustrates a block diagram of an exemplary electronic device suitable for use in implementing embodiments of the present application.
Detailed Description
Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are exemplary and intended to be used for explaining the present application and should not be construed as limiting the present application.
A buried point code injection method, an event reporting apparatus, an electronic device, and a computer-readable storage medium according to embodiments of the present application are described below with reference to the drawings.
FIG. 1 is a flow chart of a buried point code injection method according to one embodiment of the present application.
As shown in fig. 1, the method for injecting the buried point code includes the following steps:
step 101, acquiring a buried point code corresponding to a buried point according to a buried point requirement; the buried point code is generated by a predefined proxy class and a predefined buried point class, wherein the buried point class is defined in the proxy class.
In the embodiment of the present application, the buried point requirement may be understood as a function of the statistics of the specific data indexes implemented by the buried point in the application program, such as the statistics of diamond consumption, the statistics of gold coin consumption, the statistics of lottery drawing situations, the statistics of video advertisement watching situations, and the like.
Where each buried point may have a unique identifier, often referred to as an "event," the name of which is often associated with the buried point requirements. Each event may contain one or more parameters, each representing a different meaning for statistically different data. In the embodiment of the present application, each of the buried points may be defined as a class, and as the buried point class, the name of the class may be the name of the event, and the members in the class may be parameters in the event. As an example, all the corresponding embedded point classes may be defined according to the business requirements of the target project; in all the buried point classes, all the parameters of each buried point class are defined. For example, a prop purchase in a game-type application, which may include a prop purchase of skin, checkpoint, weapon, etc., may define the pit class and all parameters of the pit class based on the above purchased prop type and data. Therefore, the embedded point can be found by searching the embedded point class, and the calling and setting of parameters in the embedded point class are more convenient, the structure is clearer and more reasonable and is easy to understand.
For example, as shown in fig. 2, iosdiamond direct is an event name of a buried point class, which is known by the event name and is used for counting diamond consumption, wherein a parameter Scene represents consumed scenes, a parameter Clothid represents clothing ID, a parameter Furid represents furniture ID, a parameter Chatwith represents who chats, and a parameter Topicid represents chatting topic ID.
In addition, in the embodiment of the application, because the number of the embedded point classes is large, the embedded point classes are placed in different classes to be called and are inconvenient to search, in order to provide a uniform access interface, an agent class can be defined in advance, and the embedded point classes are uniformly defined in the agent class, so that the required embedded point classes can be searched or called by accessing the uniform agent interface, the consistency of the interface is ensured, and the efficiency of adding, modifying and understanding the embedded points can be improved. For example, calling an iosdiamond flush event does not call the flush event directly, but instead calls the flush event in a proxy class by accessing the proxy class. It should be noted that each application program has only one proxy class, the proxy class includes a plurality of embedded point classes, and each embedded point class may include one or more parameters.
For example, as shown in fig. 3, a pre-designed buried point implementation structure is provided, in which a unified proxy class is defined, and the proxy class defines: diamond consumption, gold coin consumption, flow statistics, and the like, each of which comprises a plurality of parameters. For example, if the data of diamond consumption needs to be counted, the buried point class of the corresponding diamond consumption class can be called from the agent class, and the parameters include: the amount consumed, the type of specific prop consumed, the scenario of consumption (i.e., from which page to go to the current page), the ID of the type consumed, the current time consumed, the network status, etc.
It can be understood that the embedded point codes corresponding to different embedded point requirements are different, and alternatively, as shown in fig. 4, a corresponding target embedded point class may be obtained from a predefined proxy class according to the embedded point requirements, and a corresponding target parameter may be obtained from the target embedded point class, and then, the embedded point code corresponding to the embedded point may be generated according to the proxy class, the corresponding target embedded point class, and the corresponding target parameter. The method comprises the following specific steps:
step 401, according to the buried point requirement, obtaining a corresponding target buried point class from a predefined proxy class.
It will be appreciated that each of the burial points has a unique identifier, which is an event, the name of which is typically associated with the burial point requirements. For example, the event name is consistent with the buried point requirement. Therefore, in the embodiment of the present application, the buried point requirement corresponding to each buried point class in the proxy class can be obtained by looking up the event name of the buried point class, and when the buried point requirement is consistent with the buried point requirement, the corresponding buried point class is used as the target buried point class. For example, the diamond consumption buried point demand in the statistical game is consistent with the demand of the diamond consumption buried point class in the agent class, and the diamond consumption buried point class in the agent class is the target buried point class.
And 402, acquiring corresponding target parameters from corresponding target buried point classes according to the buried point requirements.
In the embodiment of the application, each buried point class may include one or more parameters, each parameter represents a different meaning, and a parameter corresponding to the buried point requirement is obtained from one or more parameters in the corresponding target buried point class as a target parameter. For example, for counting the amount of diamond consumed, a parameter for counting the amount of diamond consumed may be used as a target parameter from among a plurality of parameters in the diamond consumption cloud.
And 403, generating a buried point code corresponding to the buried point according to the proxy class, the corresponding target buried point class and the corresponding target parameter.
Further, according to the buried point requirement, a corresponding target buried point class is obtained in a predefined proxy, and then target parameters corresponding to the buried point requirement are configured in the target buried point class to generate a buried point code corresponding to the buried point.
And step 102, determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement.
And 103, injecting the embedded point codes corresponding to the embedded points into the target position of the target project.
It is understood that the embedded point requirements corresponding to different embedded point classes are different, and as an example, the embedded point requirements corresponding to the embedded point class in the target item are obtained, and when the embedded point requirements corresponding to the embedded point class in the target item are consistent with the embedded point requirements corresponding to the embedded point code, the position of the embedded point class in the target item is used as a target position, and the embedded point code is injected into the target position of the target item.
For example, as shown in fig. 5, for a scene with statistical diamond consumption (diamond post), including four scenes of ABCD, different bur codes are added at different scene positions according to bur requirements to perform statistics of related data.
According to the embedded point code injection method, embedded point codes corresponding to embedded points are obtained according to embedded point requirements; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project. According to the method, embedded point requirements are analyzed, corresponding embedded point codes are generated through a predefined proxy class and a predefined embedded point class, and then the embedded point codes are injected to corresponding positions.
In the embodiment of the application, a buried point is set in the application program for data statistics, and further, the statistical data is reported so as to analyze the statistical data and make optimization adjustment on the application program. As shown in fig. 6, the specific steps are as follows:
step 601, when an event with a preset embedded point is triggered, acquiring the event.
In the embodiment of the application, when an event with a preset buried point is triggered, the event can be acquired through a preset function. For example, in an event that a diamond consumption buried point is preset, when the diamond is spent to buy a prop, the event is triggered, the event can be monitored, and the event can be obtained through a monitoring function. The preset function may be, but is not limited to, a listening function.
Step 602, extracting total statistical information of events; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class.
Further, after an event with a preset buried point is acquired, different parameters in a buried point code corresponding to the event correspond to different statistical data information, and statistical information corresponding to the parameters in the buried point code in the event can be extracted to acquire total statistical information of the event. It is understood that the buried point code is generated by a predefined proxy class and a predefined buried point class, wherein the buried point class is defined in the proxy class.
For example, after the user spends money to purchase the prop, a preset diamond consumption buried point event is triggered, statistical information in a buried point code corresponding to the event is extracted, and total statistical information of diamond consumption is obtained. Such as the amount consumed, the type of specific prop consumed, the scenario of consumption (i.e. from which page to go to the current page), the ID of the type consumed, the current time consumed, the network status, etc.
Step 603, determining target parameters to be uploaded under the buried point according to the scene injected by the buried point.
In the embodiment of the application, data reported by an event is confused because the reporting of the event does not need to report all statistical information of the event every time, for example, the ID of furniture is reported while clothes are purchased, or the reporting fails when the clothes are purchased successfully. Therefore, in order to improve the accuracy of event reporting, according to the scene injected by the buried point, the reported event statistical information is distinguished, and the target parameters to be uploaded under the buried point are determined. For example, in a diamond consumption event, when scene is a, only the ID of the clothing is reported, and when scene is B, only the ID of the furniture is reported.
And step 604, generating corresponding event statistical information to be reported according to the target parameters to be uploaded under the buried point and the total statistical information of the events.
Optionally, statistical information corresponding to the target parameter is obtained from the total statistical information of the event in order to avoid reporting other parameters irrelevant to the reporting behavior; setting statistical information corresponding to other parameters except the target parameter under the buried point as a target threshold; and generating corresponding event statistical information to be reported according to the statistical information corresponding to the target parameters and the statistical information corresponding to other parameters.
That is, according to the target parameter, the statistical information corresponding to the target parameter is obtained from the total statistical information, a target threshold is set for the statistical information corresponding to other parameters except the target parameter, for example, the target threshold is set to 0 or the character is "null", and then, according to the statistical information corresponding to the target parameter and the statistical information with the target threshold set, the corresponding statistical information of the event to be reported is generated.
For example, as shown in fig. 7, except for scene (a parameter that must be reported), other parameters are set to 0 by default, and different values are initialized according to scene through the switch judgment. Therefore, other parameters which are irrelevant to the reporting behavior are avoided being reported.
Step 605, reporting the event and the statistical information of the event to be reported.
Further, the event and the statistical information of the event to be reported are reported, for example, the statistical information of the diamond consumption event and the diamond event is reported to the server through a ReportData (iosdiamond direct, params) function.
In order to improve the usability and feasibility of the present application, optionally, in an embodiment of the present application, an event reporting time may be determined according to a type of a buried point, and the step of extracting total statistical information of an event is performed when a current state meets the event reporting time; or, when the current state meets the event reporting time, the reporting event and the statistical information of the event to be reported are directly executed. That is to say, the event reporting time can be determined according to the type of the buried point, when the current state meets the event reporting time, the total statistical information of the event can be extracted, the statistical information of the event to be reported is screened out from the total statistical information of the event, and the event and the statistical information of the event to be reported are reported; or, the event statistical information to be reported is obtained in advance, so that when the current state is monitored to meet the event reporting time, the event statistical information to be reported and the event which are obtained in advance can be directly reported.
It can be understood that, depending on the type of the embedded point, the reporting time of the event corresponding to the embedded point may also be different. For example, for a point-buried event that statistics shows that a prop is successfully purchased, the timer is set when the prop is successfully purchased; for the embedded point event of the failure reason of the statistical purchase of the props, the timer is set when the purchase of the props fails.
The event reporting method of the embodiment of the application acquires an event when the event with a preset embedded point is triggered; extracting total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; determining target parameters to be uploaded under the buried point according to the scene of the buried point injection; generating corresponding event statistical information to be reported according to target parameters to be uploaded under the buried point and the total statistical information of the events; reporting the event and the statistical information of the event to be reported. The method can improve the efficiency of adding, modifying and understanding the embedded point codes by respectively defining each embedded point into a class in advance, uniformly defining the embedded point classes into an agent class and further generating the corresponding embedded point codes by the predefined agent class and the predefined embedded point class, and can maintain the uniformity of interfaces by calling the embedded point classes in the agent class, so that if a certain embedded point class is required to be found, the agent class can be directly found. In addition, different parameter values are initialized according to the scene injected by the buried point, the target parameter to be uploaded under the buried point is determined, and the corresponding statistical information of the event to be reported is generated according to the target parameter to be uploaded under the buried point and the total statistical information of the event. Therefore, reporting of other parameters irrelevant to behaviors is avoided, and accuracy of event reporting is improved.
To better illustrate the above embodiments, an example is described, as shown in fig. 8, a buried point class diamondpost is defined in advance in a predefined proxy class ReportProxy, and parameters such as scene, clothid, furid, and num are defined in the buried point class diamondpost. The scene sets 8 scenes (the 8 scenes can enter a specific purchased interface), and the embedded point codes are added to corresponding scene positions according to embedded point requirements. For example, when purchasing clothing and furniture, clothid and furid point codes can be added at corresponding positions to record the ID and price of the clothing and furniture. As an example, before purchasing the clothes, a pop-up window is provided, in which information such as specific price and name of the clothes is displayed, and a buried point may be added to the position of the pop-up window to obtain the ID and price of the clothes. And then, when the purchase is successful, calling a report data reporting function to report the data to the server, wherein in the reporting function, the judgment can be carried out according to the scene, when the scene is 3, 5 and 6, only the clothes ID (clothid) is reported, other parameters are set to be 0, when the scene is 4 and 7, only the furniture ID (furid) is reported, and other parameters are set to be 0.
In accordance with the methods for injecting a buried point code provided in the foregoing embodiments, an embodiment of the present application further provides a device for injecting a buried point code, and since the device for injecting a buried point code provided in the embodiment of the present application corresponds to the methods for injecting a buried point code provided in the foregoing embodiments, the embodiments of the method for injecting a buried point code are also applicable to the device for injecting a buried point code provided in the embodiment, and will not be described in detail in the embodiment. FIG. 9 is a schematic structural diagram of a buried point code injection apparatus according to an embodiment of the present application. As shown in fig. 9, the buried point code injecting apparatus includes: a buried pointcode acquisition module 910, a buried point injectionposition determination module 920, and a buriedpoint injection module 930.
The embedded pointcode obtaining module 910 is configured to obtain an embedded point code corresponding to an embedded point according to an embedded point requirement; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; a buried point injectionposition determining module 920, configured to determine, according to a buried point requirement, a target position where the buried point requirement can be obtained in a target project; and a buriedpoint injection module 930, configured to inject a buried point code corresponding to the buried point into the target location of the target project.
As a possible implementation manner of the embodiment of the present application, the buried pointcode obtaining module 910 is specifically configured to: acquiring a corresponding target buried point class from a predefined proxy class according to the buried point requirement; acquiring corresponding target parameters from corresponding target buried point classes according to the buried point requirements; and generating a buried point code corresponding to the buried point according to the proxy class, the corresponding target buried point class and the corresponding target parameter.
As a possible implementation manner of the embodiment of the present application, as shown in fig. 10, on the basis of fig. 9, the buried point code injection apparatus further includes: apre-defined module 940.
Specifically, thepredefined module 940 is configured to predefine the proxy class, and predefine all corresponding embedded point classes in the proxy class according to the service requirement of the target project, and define all parameters of each embedded point class in all the embedded point classes.
According to the embedded point code injection device, embedded point codes corresponding to embedded points are obtained according to embedded point requirements; the embedded point code is generated through a predefined proxy class and a predefined embedded point class, wherein the embedded point class is defined in the proxy class; determining a target position capable of acquiring the embedded point requirement in the target project according to the embedded point requirement; and injecting the buried point codes corresponding to the buried points into the target position of the target project. The device can realize that a corresponding embedded point code is generated by a predefined proxy class and a predefined embedded point class through analyzing the embedded point requirement, and then the embedded point code is injected to a corresponding position.
Corresponding to the event reporting methods provided in the foregoing embodiments, an embodiment of the present application further provides an event reporting device, and since the event reporting device provided in the embodiment of the present application corresponds to the event reporting methods provided in the foregoing embodiments, the implementation manner of the event reporting method is also applicable to the event reporting device provided in this embodiment, and is not described in detail in this embodiment. Fig. 11 is a schematic structural diagram of an event reporting apparatus according to an embodiment of the present application. As shown in fig. 11, the event reporting apparatus includes: anevent obtaining module 1110, an extractingmodule 1120, a parameter to be uploaded determiningmodule 1130, an event to be reported statisticalinformation generating module 1140 and areporting module 1150.
Theevent obtaining module 1110 is configured to obtain an event when the event with a preset buried point is triggered; an extractingmodule 1120, configured to extract total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; a to-be-uploadedparameter determination module 1130, configured to determine a target parameter to be uploaded under a buried point according to a scene in which the buried point is injected; a to-be-reported event statisticalinformation generation module 1140, configured to generate corresponding to-be-reported event statistical information according to the target parameter to be uploaded under the embedded point and the total statistical information of the event; areporting module 1150, configured to report the event and the statistical information of the event to be reported.
As a possible implementation manner of the embodiment of the present application, as shown in fig. 12, on the basis of fig. 11, the event reporting apparatus further includes: an event reportingopportunity determination module 1160.
The event reportingopportunity determining module 1160 is configured to determine an event reporting opportunity according to the type of the embedded point; theextraction module 1120 is specifically configured to: and when the current state meets the event reporting opportunity, extracting the total statistical information of the event.
As a possible implementation manner of the embodiment of the present application, the to-be-reported event statisticinformation generating module 1140 is specifically configured to: acquiring statistical information corresponding to the target parameter from the total statistical information of the event; setting statistical information corresponding to other parameters except the target parameter under the buried point as a target threshold; and generating corresponding event statistical information to be reported according to the statistical information corresponding to the target parameters and the statistical information corresponding to other parameters.
As a possible implementation of the embodiment of the present application, the target threshold is thenumber 0 or the character "null".
The event reporting device of the embodiment of the application acquires an event when the event with a preset embedded point is triggered; extracting total statistical information of the event; the total statistical information is obtained based on a buried point code corresponding to the event, wherein the buried point code is generated through a predefined proxy class and a predefined buried point class, and the buried point class is defined in the proxy class; determining target parameters to be uploaded under the buried point according to the scene of the buried point injection; generating corresponding event statistical information to be reported according to target parameters to be uploaded under the buried point and the total statistical information of the events; reporting the event and the statistical information of the event to be reported. The method can improve the efficiency of adding, modifying and understanding the embedded point codes by respectively defining each embedded point into a class in advance, uniformly defining the embedded point classes into an agent class and further generating the corresponding embedded point codes by the predefined agent class and the predefined embedded point class, and can maintain the uniformity of interfaces by calling the embedded point classes in the agent class, so that if a certain embedded point class is required to be found, the agent class can be directly found. In addition, different parameter values are initialized according to the scene injected by the buried point, the target parameter to be uploaded under the buried point is determined, and the corresponding statistical information of the event to be reported is generated according to the target parameter to be uploaded under the buried point and the total statistical information of the event. Therefore, other parameters irrelevant to the reporting behavior are prevented from being reported, and the accuracy of reporting the event is improved.
In order to implement the foregoing embodiments, an electronic device is further provided in an embodiment of the present application, including a processor, a memory, and a computer program stored in the memory and executable on the processor; wherein, the processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to implement the buried point code injection method as described in the above embodiments.
FIG. 13 illustrates a block diagram of an exemplary electronic device suitable for use in implementing embodiments of the present application. The electronic device 12 shown in fig. 13 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present application.
As shown in fig. 13, electronic device 12 is embodied in the form of a general purpose computing device. The components of electronic device 12 may include, but are not limited to: one or more processors orprocessing units 16, asystem memory 28, and abus 18 that couples various system components including thesystem memory 28 and theprocessing unit 16.
Bus 18 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. These architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus, to name a few.
Electronic device 12 typically includes a variety of computer system readable media. Such media may be any available media that is accessible by electronic device 12 and includes both volatile and nonvolatile media, removable and non-removable media.
Memory 28 may include computer system readable media in the form of volatile Memory, such as Random Access Memory (RAM) 30 and/orcache Memory 29. The electronic device 12 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only,storage system 44 may be used to read from and write to non-removable, nonvolatile magnetic media (not shown in FIG. 13, commonly referred to as a "hard drive"). Although not shown in FIG. 13, a disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a Compact disk read Only memory (CD-ROM), a Digital versatile disk read Only memory (DVD-ROM), or other optical media) may be provided. In these cases, each drive may be connected tobus 18 by one or more data media interfaces.Memory 28 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the application.
A program/utility 40 having a set (at least one) of program modules 42 may be stored, for example, inmemory 28, such program modules 42 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. Program modules 42 generally perform the functions and/or methodologies of the embodiments described herein with respect to fig. 1.
Electronic device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device,display 24, etc.), with one or more devices that enable a user to interact with electronic device 12, and/or with any devices (e.g., network card, modem, etc.) that enable electronic device 12 to communicate with one or more other computing devices. Such communication may be through an input/output (I/O)interface 22. Also, the electronic device 12 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public Network such as the Internet) via theNetwork adapter 20. As shown, thenetwork adapter 20 communicates with other modules of the electronic device 12 via thebus 18. It should be understood that although not shown in the figures, other hardware and/or software modules may be used in conjunction with electronic device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
Theprocessing unit 16 executes various functional applications and data processing, such as implementing the buried point code injection method as in the above-described embodiments, by running a program stored in thesystem memory 28.
In order to implement the foregoing embodiments, the present application further proposes a computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the buried point code injection method according to the foregoing embodiments.
In order to implement the foregoing embodiments, the present application further provides another electronic device, which includes a processor, a memory, and a computer program stored in the memory and executable on the processor; the processor reads the executable program code stored in the memory to run the program corresponding to the executable program code, so as to implement the event reporting method described in the above embodiment.
In order to implement the foregoing embodiments, another computer-readable storage medium is further provided in an embodiment of the present application, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the event reporting method according to the foregoing embodiments.
In the description of the present application, it is to be understood that the terms "first", "second" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implying any number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless specifically limited otherwise.
In the description herein, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Although embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application, and that variations, modifications, substitutions and alterations may be made to the above embodiments by those of ordinary skill in the art within the scope of the present application.

Claims (10)

CN201911060651.9A2019-11-012019-11-01Buried point code injection method, event reporting method and related equipment thereofActiveCN110908880B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201911060651.9ACN110908880B (en)2019-11-012019-11-01Buried point code injection method, event reporting method and related equipment thereof

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201911060651.9ACN110908880B (en)2019-11-012019-11-01Buried point code injection method, event reporting method and related equipment thereof

Publications (2)

Publication NumberPublication Date
CN110908880Atrue CN110908880A (en)2020-03-24
CN110908880B CN110908880B (en)2023-10-13

Family

ID=69815907

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201911060651.9AActiveCN110908880B (en)2019-11-012019-11-01Buried point code injection method, event reporting method and related equipment thereof

Country Status (1)

CountryLink
CN (1)CN110908880B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN111639007A (en)*2020-05-292020-09-08北京金山云网络技术有限公司Data processing method, device, terminal and computer readable storage medium
CN112115041A (en)*2020-08-062020-12-22北京健康之家科技有限公司Dynamic point burying method and device for application program, storage medium and computer equipment
CN112306803A (en)*2020-10-292021-02-02金蝶云科技有限公司Performance monitoring method and related equipment
CN113641345A (en)*2021-08-132021-11-12网易(杭州)网络有限公司Mapping configuration-based point burying method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
WO2014138354A1 (en)*2013-03-082014-09-12Insyde Software Corp.A method and device to perform event thresholding in a firmware environment utilizing a scalable sliding time window
CN106844217A (en)*2017-01-262017-06-13网易(杭州)网络有限公司Control to applying bury method and device, readable storage medium storing program for executing a little
CN108551411A (en)*2018-04-282018-09-18努比亚技术有限公司Collecting method, mobile terminal and computer readable storage medium
CN109960633A (en)*2019-03-282019-07-02深圳市跃动运营科技有限公司A kind of data visualization buries point methods, storage medium and intelligent terminal
CN110263070A (en)*2019-05-302019-09-20北京创鑫旅程网络技术有限公司Event report method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
WO2014138354A1 (en)*2013-03-082014-09-12Insyde Software Corp.A method and device to perform event thresholding in a firmware environment utilizing a scalable sliding time window
CN106844217A (en)*2017-01-262017-06-13网易(杭州)网络有限公司Control to applying bury method and device, readable storage medium storing program for executing a little
CN108551411A (en)*2018-04-282018-09-18努比亚技术有限公司Collecting method, mobile terminal and computer readable storage medium
CN109960633A (en)*2019-03-282019-07-02深圳市跃动运营科技有限公司A kind of data visualization buries point methods, storage medium and intelligent terminal
CN110263070A (en)*2019-05-302019-09-20北京创鑫旅程网络技术有限公司Event report method and device

Cited By (6)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN111639007A (en)*2020-05-292020-09-08北京金山云网络技术有限公司Data processing method, device, terminal and computer readable storage medium
CN111639007B (en)*2020-05-292024-05-03北京金山云网络技术有限公司Data processing method, device, terminal and computer readable storage medium
CN112115041A (en)*2020-08-062020-12-22北京健康之家科技有限公司Dynamic point burying method and device for application program, storage medium and computer equipment
CN112115041B (en)*2020-08-062023-08-22北京水滴科技集团有限公司 Application program dynamic burying method, device, storage medium and computer equipment
CN112306803A (en)*2020-10-292021-02-02金蝶云科技有限公司Performance monitoring method and related equipment
CN113641345A (en)*2021-08-132021-11-12网易(杭州)网络有限公司Mapping configuration-based point burying method and device, electronic equipment and storage medium

Also Published As

Publication numberPublication date
CN110908880B (en)2023-10-13

Similar Documents

PublicationPublication DateTitle
CN110908880B (en)Buried point code injection method, event reporting method and related equipment thereof
CN111273969B (en)State switching method, device, equipment and storage medium
US9836346B2 (en)Error troubleshooting using a correlated knowledge base
CN112199296B (en)Page testing method and device, computer equipment and storage medium
CN112363943A (en)Buried point setting method and device, computer equipment and storage medium
CN108804299A (en)Application exception processing method and processing device
CN110909009B (en)Track accompanying behavior analysis method based on ticket, terminal equipment and storage medium
CN108111364B (en)Service system testing method and device
KR102161137B1 (en)Method and system for game data collection
CN109428910B (en)Data processing method, device and system
CN107066536B (en)Comment determining method and device
CN113254315B (en)Reporting method of embedded point information, embedded point method, device, medium and electronic equipment
CN110007921B (en)Code publishing method and device
CN110888628B (en)Method, apparatus, device and storage medium for generating control tool
CN113496017B (en)Verification method, device, equipment and storage medium
CN108197002B (en)Mobile device non-buried point data statistical method, system, terminal and medium
WO2023284877A1 (en)Detection method and apparatus, and electronic device
CN119003574A (en)Automatic optimization method, device, equipment and medium for SQL execution performance
CN112966756A (en)Visual access rule generation method and device, machine readable medium and equipment
CN118035095A (en)Method and device for testing business processing object, computer equipment and storage medium
CN114429360B (en)Conversion rate determination method, conversion rate determination device, electronic device, and computer-readable storage medium
CN112528291B (en)Code auditing method and device based on knowledge graph
CN108459942A (en)A kind of data processing method, device and storage medium
CN110262856B (en)Application program data acquisition method, device, terminal and storage medium
CN116451191A (en)Information auditing method, device, electronic equipment and computer readable storage medium

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp