CN111143206A - Data acquisition method and device, electronic equipment and storage medium - Google Patents
Data acquisition method and device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN111143206A CN111143206A CN201911322801.9A CN201911322801A CN111143206A CN 111143206 A CN111143206 A CN 111143206A CN 201911322801 A CN201911322801 A CN 201911322801A CN 111143206 A CN111143206 A CN 111143206A
- Authority
- CN
- China
- Prior art keywords
- page
- level
- page level
- core data
- controller
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 44
- 230000004044 response Effects 0.000 claims description 53
- 238000012544 monitoring process Methods 0.000 claims description 9
- 238000004590 computer program Methods 0.000 claims description 7
- 230000002159 abnormal effect Effects 0.000 abstract description 7
- 238000010586 diagram Methods 0.000 description 16
- 230000005856 abnormality Effects 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 239000002904 solvent Substances 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/362—Software debugging
- G06F11/366—Software debugging using diagnostics
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- User Interface Of Digital Computer (AREA)
Abstract
The application provides a data acquisition method, a data acquisition device, electronic equipment and a storage medium. Then, respectively acquiring page controllers corresponding to each preorder page level and the current page level; finally, core data of a corresponding page level can be acquired by the page controller. Therefore, the data acquisition method provided by the application can acquire the data of all the pages on all the page levels associated with the screen capture picture to serve as a data basis for determining the abnormal reason of the pages, so that the accuracy for determining the abnormal reason of the pages is effectively improved.
Description
Technical Field
The present application relates to the field of application program maintenance technologies, and in particular, to a data acquisition method and apparatus, an electronic device, and a storage medium.
Background
When a user uses an application program, various problems can be encountered, such as page jump failure, page display abnormity and the like, and the user is required to react to the problems to seek solution and feedback of the server. Generally, a user needs to capture a screen of a current page and feed back a captured picture to a server. After receiving the screen capture picture, the server analyzes the picture and the text information presented on the screen capture picture, such as error, and the abnormal state presented by the screen capture picture, such as the current problem with mosaic, blue screen and other analysis applications.
However, the above-described method of analyzing application exceptions by screenshot has some problems. The user usually operates the application program based on the response chain rule to obtain the page required by the user, so the page displayed on the terminal usually corresponds to a certain page level in the response chain, and further, if the user obtains the page where the screen capture operation is performed through multiple touch operations, the operation for obtaining the page correspondingly leaves data on a preamble page level before the page level where the page is located. Obviously, obtaining screenshot pages requires support for corresponding data at the level of these preamble pages.
However, analyzing the cause of an anomaly of an application by a screenshot can only be analyzed from the screenshot, but most of the time, the screenshot is only one result presented by the problem, and data that produces the cause of the problem may exist at other page levels. Therefore, by simply analyzing the screen shot picture, the acquired data is incomplete, and the cause of the abnormality may not be accurately known.
Disclosure of Invention
The application provides a data acquisition method, a data acquisition device, electronic equipment and a storage medium, which are used for acquiring all data corresponding to a screenshot picture, so that the accuracy of judging the page abnormity reason is improved.
In a first aspect, an embodiment of the present application provides a data acquisition method, including:
determining a corresponding current page level of the screen capture picture in the response chain;
determining a preamble page level associated with the screenshot picture by combining the response chain and the current page level, wherein the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored by each preamble page level are protocol pages which are used for providing core data;
respectively acquiring page controllers corresponding to the preorder page levels and the current page level;
and acquiring core data of a corresponding page level by using the page controller.
In a possible implementation manner of the first aspect of the embodiment of the present invention, the determining that the screenshot picture is before the corresponding current page level in the response chain includes:
monitoring whether a screen capture event exists in the system;
and if so, acquiring a screen capture picture from the screen capture event.
In a possible implementation manner of the first aspect of the embodiment of the present invention, the page controller that respectively obtains each of the preamble page hierarchies includes:
using each page level as a starting point, and inquiring the next responder corresponding to each page level step by step according to the sequence of the response chain;
and determining a page controller corresponding to each page level, wherein the page controller is the first page controller appearing in the next responder of each page level.
In a possible implementation manner of the first aspect of the embodiment of the present invention, the acquiring, by using a page controller, core data of a corresponding page hierarchy includes:
judging whether a navigation stack exists in the page controller, wherein the navigation stack is composed of a plurality of stacks, and each stack is used for correspondingly acquiring core data of different pages in the same page level;
if not, acquiring the page in the corresponding page level;
and acquiring the core data of the page as the core data of the page hierarchy by utilizing the page controller.
In a possible implementation manner of the first aspect of the embodiment of the present invention, the obtaining, by using the page controller, core data of a corresponding page hierarchy further includes
If so, traversing the navigation stack to acquire sub-core data corresponding to each stack in the navigation stack;
and summarizing the sub-core data corresponding to all stacks in the same navigation stack to obtain the core data corresponding to the page level corresponding to the page controller.
In a possible implementation manner of the first aspect of the embodiment of the present invention, the obtaining, by using a page controller, core data of a corresponding page hierarchy further includes:
and acquiring core data of each page level according to the sequence from the first page level to the current page level in the response chain.
In a second aspect, an embodiment of the present application provides a data obtaining apparatus, including:
the current page level determining module is used for determining the corresponding current page level of the screen capture picture in the response chain;
a preamble page level determining module, configured to determine, in combination with the response chain and the current page level, a preamble page level associated with the screenshot picture, where the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored in each of the preamble page levels are protocol pages used for providing core data;
a page controller obtaining module, configured to obtain page controllers corresponding to each of the preamble page levels and the current page level respectively;
and the core data acquisition module is used for acquiring the core data of the corresponding page hierarchy by using the page controller.
In a possible implementation manner of the second aspect of the embodiment of the present invention, the apparatus further includes:
the monitoring module is used for monitoring whether a screen capture event exists in the system;
and the screen capture picture acquisition module is used for acquiring the screen capture picture from the screen capture event if the screen capture event is positive.
In a possible implementation manner of the second aspect of the embodiment of the present invention, the page controller obtaining module includes:
the query module is used for querying the next responder corresponding to each page level step by taking each page level as a starting point according to the sequence of the response chain;
and the page controller determining module is used for determining the page controller corresponding to each page level, and the page controller is the first page controller appearing in the next responder of each page level.
In a possible implementation manner of the second aspect of the embodiment of the present invention, the core data obtaining module includes:
the navigation stack judging module is used for judging whether a navigation stack exists in the page controller or not, the navigation stack is composed of a plurality of stacks, and each stack is used for correspondingly acquiring core data of different pages in the same page level;
the page acquisition module is used for acquiring the page in the corresponding page level if the page is not acquired;
and the single-page data acquisition module is used for acquiring the core data of the page as the core data of the page hierarchy by using the page controller.
In a possible implementation manner of the second aspect of the embodiment of the present invention, the core data obtaining module further includes
The sub-core data acquisition module is used for traversing the navigation stack and acquiring sub-core data corresponding to each stack in the navigation stack if the navigation stack is the current stack;
and the summarizing module is used for summarizing the sub-core data corresponding to all stacks in the same navigation stack to obtain the core data corresponding to the page level corresponding to the page controller.
In a possible implementation manner of the second aspect of the embodiment of the present invention, the core data obtaining module obtains the core data of each page level according to an order from the first page level to the current page level in the response chain.
In a third aspect, an embodiment of the present invention provides an electronic device, including:
a processor, and
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform the data acquisition method via execution of the executable instructions.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to implement the data acquisition method.
According to the above technology, the present application provides a data acquisition method, an apparatus, an electronic device, and a storage medium, and first, a current page level corresponding to a screenshot picture in a response chain is determined, and then, a preamble page level associated with the screenshot picture is determined in combination with the response chain and the current page level, where the current page level and pages stored in each of the preamble page levels are protocol pages, and the protocol pages are used for providing core data. Then, respectively acquiring page controllers corresponding to each preorder page level and the current page level; finally, core data of a corresponding page level can be acquired by the page controller. Therefore, the data acquisition method provided by the application can acquire the data of all the pages on all the page levels associated with the screen capture picture to serve as a data basis for determining the abnormal reason of the pages, so that the accuracy for determining the abnormal reason of the pages is effectively improved.
Drawings
In order to more clearly explain the technical solution of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious to those skilled in the art that other drawings can be obtained according to the drawings without any creative effort.
Fig. 1 is a flowchart of a data acquisition method according to an embodiment of the present application;
fig. 2 is a schematic page level distribution diagram of a response chain according to an embodiment of the present disclosure;
fig. 3 is a flowchart of a method for acquiring a screenshot picture according to an embodiment of the present disclosure;
fig. 4 is a flowchart of a method for determining a page controller corresponding to a page level according to an embodiment of the present disclosure;
fig. 5 is a schematic diagram illustrating a correspondence relationship between a page level and a page controller according to an embodiment of the present application;
fig. 6 is a schematic diagram of multiple pages corresponding to a page level according to an embodiment of the present disclosure;
fig. 7 is a flowchart of a method for acquiring core data according to an embodiment of the present application;
fig. 8 is a schematic diagram of a sequence for acquiring core data according to an embodiment of the present application;
fig. 9 is a schematic structural diagram of a first data acquisition apparatus according to an embodiment of the present application;
fig. 10 is a schematic structural diagram of a second data acquisition apparatus according to an embodiment of the present application;
fig. 11 is a schematic structural diagram of a third embodiment of a data acquisition device according to the present application;
fig. 12 is a schematic structural diagram of a fourth embodiment of a data acquisition apparatus according to the present application;
fig. 13 is a schematic structural diagram of a fifth embodiment of a data acquisition apparatus according to an embodiment of the present application;
fig. 14 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be described clearly and completely with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a flowchart of a data acquisition method provided in an embodiment of the present application, and as shown in fig. 1, the data acquisition method provided in the embodiment includes:
and S1, determining the corresponding current page level of the screen capture picture in the response chain.
Generally, when a user uses an application program, the user is based on a response chain mechanism, as shown in fig. 2, the outermost frame shown in fig. 2 corresponds to a display screen of a terminal device executing the application program, each rectangular frame above represents different page levels, and when the user uses the application program, the user needs to enter each page level step by step to obtain a response of a certain page level to a page instruction issued by the user, so that a page meeting the user instruction requirement is also shown on the page level. For example, the page command issued by the user is to open a chat interface with a in the application software P. At this time, it is necessary to click a virtual key on the page level subView, for example, an icon displaying the application software P, after the click, the page level jumps to the next page level superview, at this time, a login interface is displayed on the page level, by performing a login operation on the page level, the page level continues to jump to the next page level UI View, at this time, all service virtual keys of the application software P, including a chat key, are displayed on the page level, and by clicking the chat key, the page level jumps to the next page level UI Window, at this time, the page level displays a chat interface with a, that is, the page level can complete a response to a user page instruction, and the user completes a series of touch operations. It can be seen that, when the server responds to a certain user page instruction, it needs to execute a series of touch operations based on the response chain, and accordingly, data corresponding to the operations will be left on the passing page level. If the user has a page abnormality in the chat process of the user A, for example, the page display is incomplete, or the chat data is missing, and the user needs to intercept the picture of the current interface as the basis of the page abnormality problem feedback and feed the picture back to the server, the page level corresponding to the screenshot picture is the UI Window at this time.
Specifically, the same server may correspond to different application software simultaneously, and the same application software may correspond to different users simultaneously, so that the same server may receive the page abnormality problem fed back from a large number of users simultaneously, and receive a large number of screen shots simultaneously, specifically, as shown in fig. 3, the method includes:
s101, monitoring whether a screen capture event exists in a system;
and S102, if so, acquiring a screen capture picture from the screen capture event.
The screen capturing action of the user is reflected in the system to be a screen capturing event, namely, one screen capturing picture corresponds to the screen capturing event, the server monitors whether the screen capturing event exists in the system in real time, namely, whether the user needs to solve the problem of page abnormity in real time, and if the screen capturing event exists, the screen capturing picture needs to be obtained from the screen capturing event. Generally, a screenshot event will carry a lot of information, such as the device ID from which the screenshot came, the time of the screenshot, and the screenshot. Specifically, a screen capture event may be listened to in the appdelete class.
Furthermore, the server can select to acquire the screenshot picture in real time according to the actual working environment so as to meet the timeliness fed back to the user; meanwhile, the screen capture pictures can be periodically acquired from the screen capture events, so that the workload brought to the server by high concurrency is avoided.
Further, after the screen capture picture is acquired, the page level of the screen capture picture can be accurately determined through the saving path of the screen capture picture.
Therefore, the embodiment provided by the application can accurately monitor the screen capture event in the system and accurately acquire the screen capture picture for subsequent data acquisition.
S2, determining a preamble page level associated with the screenshot picture by combining the response chain and the current page level, wherein the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored by each preamble page level are protocol pages used for providing core data.
After the current page level of the screenshot picture is determined, the response chain can determine which preamble page levels between the current page levels are available. The order of the response chain is fixed, and thus, after determining the current page level, the preamble page level associated with the screenshot picture may be determined, where the preamble page level is the page level through which the current page level is obtained based on the response chain. For example, if the current page level is UI Window, the preamble levels are sub View, super View and UI View. If the current page level is UI Application, its preamble level is sub View, super View, UI View and UI Window.
Meanwhile, the embodiment of the application provides that the pages stored in each layer are protocol pages, that is, the protocol pages can provide core data. The protocol may be (NSDictionary)*) CurrentLogData, the core data adopts a dictionary type, and the dictionary content is self-defined by each page developer. The core data comprises user ID, background operation data corresponding to the page and the like which cannot be directly displayed on the display page.
Therefore, the technical scheme provided by the embodiment of the application provides a technical basis for accurately providing the page data subsequently, and ensures that the core data corresponding to the page level can be obtained by subsequent data acquisition operation so as to determine the reason of the page abnormity through the deeper data.
S3, respectively obtaining the page controllers corresponding to the preamble page levels and the current page level.
Each object in the response chain for responding to a user page command may be referred to as a responder, which includes different page levels and also includes page controllers corresponding to the different page levels. As shown in FIG. 2, the next responder of the UI View is the View Controller, i.e., the page Controller. The page controller is a tool layer for processing data corresponding to each page level, and a response chain may include a plurality of page controllers, each corresponding to a page level; or may include only one page controller for processing data corresponding to all page levels.
In the case that a plurality of page controllers are included in the response chain, the page controllers process data of adjacent page levels according to the proximity principle, and specifically, as shown in fig. 4, the page controller corresponding to a page level may be determined through the following process.
S301, with each page level as a starting point, inquiring the next responder corresponding to each page level step by step according to the sequence of the response chain;
s302, determining a page controller corresponding to each page level, wherein the page controller is a first page controller appearing in a next responder of each page level.
For example, in fig. 5, a page Controller of a page level UI View is searched, and a next responder of the UI View is queried step by step according to a sequence of response chains, where it can be known that a View Controller C is a first page Controller appearing in all the next responders of the UI View, and thus the View Controller C is the page Controller of the UI View; and for the page level UIWindow, inquiring the next responder of the UI Window step by step, wherein the view Controller D is the first page Controller appearing in all the next responders of the UI Window, and therefore, the view Controller D is the page Controller of the UI Window.
By the method for querying the page controller step by step, the problem that the page controller does not correspond to the page hierarchy can be effectively prevented, and therefore the accuracy of the page controller for acquiring the page hierarchy data is effectively guaranteed.
And S4, acquiring core data of the corresponding page level by using the page controller.
The page controller can acquire core data of corresponding page levels, specifically, the data of each page level are correspondingly stored in a corresponding database, and the page controller can extract all the core data of the page level from the database.
Generally, a plurality of pages exist in a certain page level, as shown in fig. 6, View B and View C, View D and View E are a plurality of pages in the same page level, core data of the page level actually corresponds to a summary of the core data of the page in the page level, and for a case that the same page level includes a plurality of pages, the summary is a summary of sub-core data corresponding to each page. Therefore, for a page hierarchy containing different numbers of pages, the core data corresponding to the page hierarchy may be obtained according to one method for obtaining core data shown in fig. 7. In particular, the amount of the solvent to be used,
s401, judging whether a navigation stack exists in the page controller, wherein the navigation stack is composed of a plurality of stacks, and each stack is used for correspondingly acquiring core data of different pages in the same page level;
s402, if not, acquiring a page in a corresponding page level;
s403, acquiring the core data of the page as the core data of the page hierarchy by using the page controller.
Generally, when a page controller processes data of pages in a page hierarchy, a one-to-one corresponding processing mode is adopted, so that if a plurality of pages exist in the same page hierarchy, in order to control the number of the page controllers, a navigation stack structure can be added in the page controller, the navigation stack is composed of a plurality of stacks, and each stack can be used for processing the data of one page; whereas if only one page is contained in the same page level, no navigation stack structure is needed. Therefore, whether a plurality of pages exist in the same page level can be judged according to whether a navigation stack structure exists in the page controller.
Specifically, if there is no navigation stack structure in the page controller, it indicates that only one page is included in the page hierarchy, and at this time, the page controller may be used to directly obtain core data of the page, where the core data of the page is the core data of the page hierarchy.
As shown in fig. 7, the method further comprises:
s404, if yes, traversing the navigation stack to obtain sub-core data corresponding to each stack in the navigation stack;
s405, gathering sub-core data corresponding to all stacks in the same navigation stack to obtain core data corresponding to the page level corresponding to the page controller.
If the navigation stack exists in the page controller, the page hierarchy contains a plurality of pages, at this time, each stack in the navigation stack needs to be used for respectively acquiring sub-core data of the corresponding page, and the sub-core data are gathered together to form the core data corresponding to the page hierarchy.
Specifically, the core data of the page level can be acquired by calling currentLogData method of the page controller. For the page controller with the navigation stack, the navigation stack is circularly traversed, a currentLogData method of the controller in the stack is called, and at the moment, data of each page is stored in an internal memory in an array form.
Further, as shown in fig. 8, core data of each page level is obtained in an order from the first page level to the current page level in the response chain.
Suppose that page a corresponds to a first page level in the response chain, page B corresponds to a second page level in the response chain, page C corresponds to a third page level in the response chain, and page C is also the current page level, i.e., the page level where the screenshot picture is located. The sequence of acquiring the core data is consistent with the operation sequence of acquiring the screen capture pictures by the user, so that the acquired core data has the operation sequence and time sequence, can accord with the operation logic, and is convenient for analyzing the reason of page abnormity according to the core data.
Further, after all core data associated with the screen capture picture are acquired, a page can be popped up to show the screen capture picture to a user, a dialog box for inputting problems is provided for the user, and finally the screen capture picture, the core data and the problems input by the user are all fed back to the server so that the server can determine the reason of the page abnormity.
The format of the specific transmission feedback data may be as follows:
according to the above technology, the present application provides a data acquisition method, an apparatus, an electronic device, and a storage medium, and first, a current page level corresponding to a screenshot picture in a response chain is determined, and then, a preamble page level associated with the screenshot picture is determined in combination with the response chain and the current page level, where the current page level and pages stored in each of the preamble page levels are protocol pages, and the protocol pages are used for providing core data. Then, respectively acquiring page controllers corresponding to each preorder page level and the current page level; finally, core data of a corresponding page level can be acquired by the page controller. Therefore, the data acquisition method provided by the application can acquire the data of all the pages on all the page levels associated with the screen capture picture to serve as a data basis for determining the abnormal reason of the pages, so that the accuracy for determining the abnormal reason of the pages is effectively improved.
Fig. 9 is a schematic structural diagram of a first data acquisition apparatus according to an embodiment of the present application, including: the current page level determining module 1 is used for determining a current page level corresponding to the screen capture picture in the response chain; a preamble page level determining module 2, configured to determine, in combination with the response chain and the current page level, a preamble page level associated with the screenshot picture, where the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored in each of the preamble page levels are protocol pages used for providing core data; a page controller obtaining module 3, configured to obtain page controllers corresponding to each of the preamble page levels and the current page level, respectively; and the core data acquisition module 4 is used for acquiring the core data of the corresponding page level by using the page controller.
Fig. 10 is a schematic structural diagram of a second embodiment of a data acquisition apparatus provided in the embodiment of the present application, where the apparatus further includes: the monitoring module 5 is used for monitoring whether a screen capture event exists in the system; and the screen capture picture acquisition module 6 is used for acquiring the screen capture picture from the screen capture event if the screen capture event is positive.
Fig. 11 is a schematic structural diagram of a third embodiment of a data acquisition apparatus according to an embodiment of the present application, where the page controller acquiring module 3 includes: the query module 31 is configured to query, by taking each page level as a starting point, a next responder corresponding to each page level step by step according to the sequence of the response chain; a page controller determining module 32, configured to determine a page controller corresponding to each page level, where the page controller is a first page controller appearing in a next responder of each page level.
Fig. 12 is a schematic structural diagram of a fourth embodiment of a data acquisition apparatus according to an embodiment of the present application, where the core data acquisition module 4 includes: a navigation stack determining module 41, configured to determine whether a navigation stack exists in the page controller, where the navigation stack is formed by multiple stacks, and each stack is used to correspondingly obtain core data of different pages in the same page level; the page obtaining module 42 is configured to, if the page is not in the corresponding page hierarchy, obtain a page in the corresponding page hierarchy; a single-page data obtaining module 43, configured to obtain, by using the page controller, core data of the page as core data of the page hierarchy.
Fig. 13 is a schematic structural diagram of a fifth embodiment of the data acquisition apparatus provided in the embodiment of the present application, where the core data acquisition module 4 further includes a sub-core data acquisition module 44, configured to traverse the navigation stack to acquire sub-core data corresponding to each stack in the navigation stack if the sub-core data acquisition module is configured to traverse the navigation stack; and a summarizing module 45, configured to summarize sub-core data corresponding to all stacks in the same navigation stack, so as to obtain core data corresponding to a page level corresponding to the page controller.
Further, the core data obtaining module obtains the core data of each page level according to the sequence from the first page level to the current page level in the response chain.
Fig. 14 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present invention. The electronic device includes: a memory 101 and a processor 102;
a memory 101 for storing a computer program;
the processor 102 is configured to execute the computer program stored in the memory to implement the data acquisition method in the above embodiments. Reference may be made in particular to the description relating to the method embodiments described above.
Alternatively, the memory 101 may be separate or integrated with the processor 102.
When the memory 101 is a device independent of the processor 102, the electronic apparatus may further include:
a bus 103 for connecting the memory 101 and the processor 102.
The electronic device provided in the embodiment of the present invention may be configured to execute any one of the data acquisition methods shown in the above embodiments, and the implementation manner and the technical effect are similar, and details of the embodiment of the present invention are not described herein again.
An embodiment of the present invention further provides a readable storage medium, where a computer program is stored in the readable storage medium, and when at least one processor of a message sending apparatus executes the computer program, the message sending apparatus executes the data acquisition method described in any of the foregoing embodiments.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program described above may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention.
Claims (14)
1. A method of data acquisition, comprising:
determining a corresponding current page level of the screen capture picture in the response chain;
determining a preamble page level associated with the screenshot picture by combining the response chain and the current page level, wherein the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored by each preamble page level are protocol pages which are used for providing core data;
respectively acquiring page controllers corresponding to the preorder page levels and the current page level;
and acquiring core data of a corresponding page level by using the page controller.
2. The method of claim 1, wherein determining that the screenshot is prior to the corresponding current page level in the response chain comprises:
monitoring whether a screen capture event exists in the system;
and if so, acquiring a screen capture picture from the screen capture event.
3. The method of claim 1 wherein said separately obtaining a page controller corresponding to each of said preamble page levels comprises:
using each page level as a starting point, and inquiring the next responder corresponding to each page level step by step according to the sequence of the response chain;
and determining a page controller corresponding to each page level, wherein the page controller is the first page controller appearing in the next responder of each page level.
4. The method of claim 1, wherein the obtaining core data of the corresponding page level by using the page controller comprises:
judging whether a navigation stack exists in the page controller, wherein the navigation stack is composed of a plurality of stacks, and each stack is used for correspondingly acquiring core data of different pages in the same page level;
if not, acquiring the page in the corresponding page level;
and acquiring the core data of the page as the core data of the page hierarchy by utilizing the page controller.
5. The method of claim 4, wherein obtaining core data of a corresponding page level using a page controller further comprises
If so, traversing the navigation stack to acquire sub-core data corresponding to each stack in the navigation stack;
and summarizing the sub-core data corresponding to all stacks in the same navigation stack to obtain the core data corresponding to the page level corresponding to the page controller.
6. The method of claim 1, wherein the obtaining core data of the corresponding page level by using the page controller further comprises:
and acquiring core data of each page level according to the sequence from the first page level to the current page level in the response chain.
7. A data acquisition apparatus, comprising:
the current page level determining module is used for determining the corresponding current page level of the screen capture picture in the response chain;
a preamble page level determining module, configured to determine, in combination with the response chain and the current page level, a preamble page level associated with the screenshot picture, where the preamble page level is a page level experienced by the current page level obtained based on the response chain, and the current page level and pages stored in each of the preamble page levels are protocol pages used for providing core data;
a page controller obtaining module, configured to obtain page controllers corresponding to each of the preamble page levels and the current page level respectively;
and the core data acquisition module is used for acquiring the core data of the corresponding page hierarchy by using the page controller.
8. The apparatus of claim 7, further comprising:
the monitoring module is used for monitoring whether a screen capture event exists in the system;
and the screen capture picture acquisition module is used for acquiring the screen capture picture from the screen capture event if the screen capture event is positive.
9. The apparatus of claim 7, wherein the page controller obtaining module comprises:
the query module is used for querying the next responder corresponding to each page level step by taking each page level as a starting point according to the sequence of the response chain;
and the page controller determining module is used for determining the page controller corresponding to each page level, and the page controller is the first page controller appearing in the next responder of each page level.
10. The apparatus of claim 7, wherein the core data acquisition module comprises:
the navigation stack judging module is used for judging whether a navigation stack exists in the page controller or not, the navigation stack is composed of a plurality of stacks, and each stack is used for correspondingly acquiring core data of different pages in the same page level;
the page acquisition module is used for acquiring the page in the corresponding page level if the page is not acquired;
and the single-page data acquisition module is used for acquiring the core data of the page as the core data of the page hierarchy by using the page controller.
11. The apparatus of claim 10, wherein the core data acquisition module further comprises
The sub-core data acquisition module is used for traversing the navigation stack and acquiring sub-core data corresponding to each stack in the navigation stack if the navigation stack is the current stack;
and the summarizing module is used for summarizing the sub-core data corresponding to all stacks in the same navigation stack to obtain the core data corresponding to the page level corresponding to the page controller.
12. The apparatus according to claim 7, wherein the core data obtaining module obtains the core data of each page level in an order from a first page level in the response chain to the current page level.
13. An electronic device, characterized in that the electronic device comprises:
a processor, and
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform the data acquisition method of any of claims 1-6 via execution of the executable instructions.
14. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the data acquisition method of any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911322801.9A CN111143206B (en) | 2019-12-19 | 2019-12-19 | Data acquisition method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911322801.9A CN111143206B (en) | 2019-12-19 | 2019-12-19 | Data acquisition method and device, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111143206A true CN111143206A (en) | 2020-05-12 |
CN111143206B CN111143206B (en) | 2024-03-22 |
Family
ID=70519060
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201911322801.9A Active CN111143206B (en) | 2019-12-19 | 2019-12-19 | Data acquisition method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111143206B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112463282A (en) * | 2020-12-14 | 2021-03-09 | 网易(杭州)网络有限公司 | Interface display method, device, storage medium and electronic device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105867736A (en) * | 2016-03-29 | 2016-08-17 | 努比亚技术有限公司 | Multi-level interface screenshot device and method |
CN107168607A (en) * | 2017-05-22 | 2017-09-15 | 努比亚技术有限公司 | The management method and mobile terminal of a kind of page setup |
CN107818163A (en) * | 2017-11-01 | 2018-03-20 | 平安科技(深圳)有限公司 | Page display method, device, computer equipment and storage medium |
CN108182060A (en) * | 2018-01-31 | 2018-06-19 | 北京腾云天下科技有限公司 | Point methods, mobile terminal and system are buried in a kind of mixing application |
CN109561266A (en) * | 2016-07-26 | 2019-04-02 | 青岛海信电器股份有限公司 | The screenshotss method and TV of TV |
-
2019
- 2019-12-19 CN CN201911322801.9A patent/CN111143206B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105867736A (en) * | 2016-03-29 | 2016-08-17 | 努比亚技术有限公司 | Multi-level interface screenshot device and method |
CN109561266A (en) * | 2016-07-26 | 2019-04-02 | 青岛海信电器股份有限公司 | The screenshotss method and TV of TV |
CN107168607A (en) * | 2017-05-22 | 2017-09-15 | 努比亚技术有限公司 | The management method and mobile terminal of a kind of page setup |
CN107818163A (en) * | 2017-11-01 | 2018-03-20 | 平安科技(深圳)有限公司 | Page display method, device, computer equipment and storage medium |
CN108182060A (en) * | 2018-01-31 | 2018-06-19 | 北京腾云天下科技有限公司 | Point methods, mobile terminal and system are buried in a kind of mixing application |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112463282A (en) * | 2020-12-14 | 2021-03-09 | 网易(杭州)网络有限公司 | Interface display method, device, storage medium and electronic device |
CN112463282B (en) * | 2020-12-14 | 2023-02-24 | 网易(杭州)网络有限公司 | Interface display method, device, storage medium and electronic device |
Also Published As
Publication number | Publication date |
---|---|
CN111143206B (en) | 2024-03-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110928772B (en) | Test method and device | |
US9734005B2 (en) | Log analytics for problem diagnosis | |
KR101791623B1 (en) | Visualizing realationships between a transaction trace graph and a map of logical subsystems | |
US9280451B2 (en) | Testing device | |
KR101837109B1 (en) | Visualizing transaction traces as flows through a map of logical subsystems | |
US20180174155A1 (en) | Mapping user actions to historical paths to determine a predicted endpoint | |
CN108595343A (en) | The test method and device of application program | |
US11176169B2 (en) | Recommending visual and execution templates to enable automation of control and data exploration across systems | |
CN110851324B (en) | Log-based routing inspection processing method and device, electronic equipment and storage medium | |
CN108628739A (en) | A kind of method that Lua scripts are debugged, client, server and debugger | |
US9697107B2 (en) | Testing applications | |
CN113051514A (en) | Element positioning method and device, electronic equipment and storage medium | |
CN103649924A (en) | Embedded apparatus, program generation apparatus, and program | |
CN107908525B (en) | Alarm processing method, equipment and readable storage medium | |
CN111143206A (en) | Data acquisition method and device, electronic equipment and storage medium | |
US20130307854A1 (en) | Method and System for Visualising a System Model | |
WO2024097232A1 (en) | Systems and methods for providing a timeline view of log information for a client application | |
CN112612469A (en) | Interface element processing method and device and electronic equipment | |
CN112363707A (en) | Control layer general scheduling method based on JAVA reflection technology | |
CN114371866A (en) | Version reconfiguration test method, device and equipment of service system | |
CN113220596B (en) | Application testing method, device, equipment, storage medium and program product | |
US11960560B1 (en) | Methods for analyzing recurring accessibility issues with dynamic web site behavior and devices thereof | |
CN112306680B (en) | Heterogeneous resource arrangement method, device, equipment and storage medium | |
JP7116671B2 (en) | System development support device and system development support method | |
US20240104011A1 (en) | Method of testing software |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |