Detailed Description
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the relevant invention and not restrictive of the invention. It should be noted that, for convenience of description, only the portions related to the related invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
Fig. 1 illustrates anexemplary system architecture 100 to which embodiments of the present method for debugging pages or apparatus for debugging pages may be applied.
As shown in fig. 1, thesystem architecture 100 may include amobile terminal 101, awireless network 102, and acomputer device 103.Wireless network 102 is the medium used to provide wireless communication links betweenmobile terminals 101 andcomputer devices 103.Wireless network 102 may include various wireless connection types. It is noted that the wireless connection types may include, but are not limited to, 3G/4G connections, WiFi connections, bluetooth connections, WiMAX connections, Zigbee connections, uwb (ultra wideband) connections, and other wireless connection types now known or later developed.
A user may usemobile terminal 101 to interact withcomputer device 103 overwireless network 102 to receive or send messages and the like. Themobile terminal 101 may have various communication client applications installed thereon, such as a mobile Web application, a Web browser application, a shopping application, a search application, an instant messaging tool, a mailbox client, social platform software, and the like.
Themobile terminal 101 may be hardware or software. When themobile terminal 101 is hardware, it may be various electronic devices having a display screen and supporting Web page browsing, including but not limited to a smart phone, a tablet computer, an e-book reader, an MP3 player (Moving Picture Experts Group Audio Layer III, motion Picture Experts Group Audio Layer 3), an MP4 player (Moving Picture Experts Group Audio Layer IV, motion Picture Experts Group Audio Layer 4), and so on. When themobile terminal 101 is software, it can be installed in the electronic devices listed above. It may be implemented as multiple pieces of software or software modules, or as a single piece of software or software module. And is not particularly limited herein.
Thecomputer device 103 may be hardware or software. When thecomputer device 103 is hardware, it may be an electronic device having a display screen and supporting web browsing and installed with Chrome developer tools.
Themobile terminal 101 can cooperate with thecomputer device 103 through thewireless network 102 to implement debugging a mobile end Web page in a source code panel or a control panel of a Chrome developer tool installed in thecomputer device 103.
It should be noted that the method for debugging a page provided by the embodiment of the present application is generally executed by thecomputer device 103, and accordingly, the apparatus for debugging a page is generally disposed in thecomputer device 103.
Thecomputer device 103 may be hardware or software. When thecomputer device 103 is hardware, it may be implemented as a distributed server cluster composed of a plurality of servers, or may be implemented as a single server. When thecomputer device 103 is software, it may be implemented as a plurality of software or software modules (for example, to provide distributed services), or as a single software or software module. And is not particularly limited herein.
It should be understood that the number of mobile terminals, networks, and computer devices in fig. 1 is illustrative only. There may be any number of mobile terminals, networks, and computer devices, as desired for an implementation.
With continued reference to FIG. 2, a timing sequence 200 for one embodiment of a system for debugging pages in accordance with the present application is shown.
The system for debugging the page in the embodiment of the application can comprise a computer device and a mobile terminal which are connected through a wireless network and provided with a display.
As shown in FIG. 2, a timing sequence 200 for one embodiment of a system for debugging a page according to the present application may include the steps of:
step 201, in response to detecting a first debugging request on a source code panel or a control panel for a page to be debugged, a computer device loads and executes a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged to obtain an execution result, and sends the obtained execution result to a mobile terminal.
In this embodiment, a Chrome developer tool may be installed in the computer device. The computer device may load and execute a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged first to obtain an execution result when detecting a first debug request for the page to be debugged on a Source code panel (i.e., Source panel) or a control panel (i.e., Console panel). Then, the obtained execution result is transmitted to a mobile terminal wirelessly connected to the computer device.
Here, the computer device may employ various implementations to determine that the first debug request is detected. For example, the computer device may determine that the first debug request is detected upon detecting an operation to open a page to be debugged in a source code panel or a control panel of the Chrome developer tool. The operation of opening the page to be debugged in the source code panel or the control panel of the Chrome developer tool may be an operation triggered by a user or an operation triggered by program code logic.
Here, the computer device may newly create a corresponding thread for the page to be debugged when it is detected for the first time that the page to be debugged is opened. For example, when the page to be debugged includes JavaScript codes, a corresponding Webworker sub-thread may be newly created for the page to be debugged as a thread corresponding to the page to be debugged. Therefore, the code corresponding to the page to be debugged is loaded and executed in the thread corresponding to the page to be debugged, the process of obtaining the execution result can be executed in the newly-built Webworker sub-thread corresponding to the page to be debugged, and the execution process does not influence the operation of the main thread.
Webworker is a JavaScript multithreading solution provided by HTML5, and can give some codes with large calculation amount to Webworker to run without blocking a user main thread, and Webworker uses worker class to load a JavaScript file to create a sub-thread in the current JavaScript main thread, so that the effect of mutual non-blocking running is achieved, and an interface for data exchange between the main thread and the sub-thread is provided: postMessage and onMessage to complete data communication between the main thread and the Webworker sub-thread.
In practice, because the Webworker is an independent environment similar to JavaScript, the environment does not support Windows API (Application Programming Interface) and Document API supported by JavaScript, so a virtual Windows API and Document API need to be implemented in the Webworker, that is, the Webworker also supports Windows API and Document API. That is, loading and executing a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged to obtain an execution result, where the execution result may include: an Object (Object) resulting from calling the Windows API and a DOM (Document Object Model) tree resulting from calling the Document API.
In order to synchronize the page displayed by the mobile terminal with the execution result obtained by executing the code in the computer device, the computer device may send the obtained execution result to the mobile terminal after obtaining the execution result.
In some optional implementations of the embodiment, the mobile terminal and the computer device may perform data communication through a Socket (Socket).
Step 202, in response to receiving the page event information sent by the mobile terminal, the computer device executes a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged based on the received page event information, obtains an execution result, and sends the obtained execution result to the mobile terminal.
In this embodiment, if the computer device receives the page event information sent by the mobile terminal, indicating that the mobile terminal detects the operation of the user on the mobile terminal, the page event information related to the operation is generated, and the generated page event information is sent to the computer device. In this way, the computer device may execute the code corresponding to the page to be debugged based on the received page event information in the thread corresponding to the page to be debugged, obtain an execution result, and send the obtained execution result to the mobile terminal.
Here, the page event information may include various information related to the user operation. For example, the page event information may include, but is not limited to: the page element identification of the user operation, the time the user operation was received, the operation type of the user operation (e.g., click, swipe), the specific information content entered by the user (e.g., the text entered by the user in the text box, or the specific selection item selected by the user in the selection-type page element).
Here, the computer device may execute, in the thread corresponding to the page to be debugged, the operation logic expressed by the code corresponding to the page to be debugged based on the received page event information, and obtain the execution result. It can be understood that, when the thread corresponding to the page to be debugged is a Webworker sub-thread, the code corresponding to the page to be debugged is executed in the thread corresponding to the page to be debugged based on the received page event information, and the obtained execution result may also include: objects (objects) resulting from calls to the Windows API and DOM trees resulting from calls to the Document API.
Here, the development engineer may set breakpoints in the source code panel to debug the code (e.g., JavaScript code) of the page to be debugged. The development engineer may also use the console panel to record diagnostic information or use the console panel as a shell to interact with JavaScript on the page.
And step 203, in response to receiving the execution result sent by the computer device, rendering and presenting the page to be debugged based on the received execution result by the mobile terminal.
In this embodiment, the mobile terminal may render and present the page to be debugged based on the received execution result when receiving the execution result sent by the computer device.
It should be noted that the above-mentioned various methods for rendering and presenting pages are well-known technologies that are widely researched and applied at present, and are not described herein again.
In step 204, the mobile terminal responds to the detected operation of the user for the page to be debugged, generates page event information related to the operation, and sends the generated page event information to the computer equipment.
In this embodiment, the mobile terminal may generate page event information related to the detected operation when detecting an operation of the user for the page to be debugged, and send the generated page event information to the computer device. Thus, the computer device can perform step 202.
In the system for debugging a page provided in the foregoing embodiment of the present application, a page to be debugged is opened in a source code panel or a control panel in a developer tool on a computer device, a code corresponding to the page to be debugged is loaded and executed in a thread corresponding to the page to be debugged, an execution result is obtained, the obtained execution result is sent to a mobile terminal, and the computer device, in response to receiving page event information sent by the mobile terminal, executes a code corresponding to the page to be debugged in the thread corresponding to the page to be debugged based on the received page event information, obtains the execution result, and sends the obtained execution result to the mobile terminal. The mobile terminal renders and presents the page to be debugged based on the received execution result in response to receiving the execution result sent by the computer equipment, and generates page event information related to the operation in response to detecting the operation of the user on the page to be debugged, and sends the generated page event information to the computer equipment. By the aid of the computer equipment and the mobile terminal connected with the computer equipment in a wireless network mode, debugging of the Web page of the mobile terminal in a source code panel or a control panel of a Chrome developer tool installed in the computer equipment is achieved, wired connection between the mobile terminal and the computer equipment is not needed, development and debugging cost is reduced, and debugging efficiency is improved.
With further reference to fig. 3A and 3B, a timing sequence 300 for yet another embodiment of a system for debugging pages is illustrated.
The system for debugging the page in the embodiment of the application can comprise a computer device and a mobile terminal which are connected through a wireless network and provided with a display.
As shown in FIG. 3A, a timing sequence 300 of yet another embodiment of a system for debugging pages according to the present application may comprise the steps of:
step 301, in response to detecting a first debugging request for a page to be debugged on a source code panel or a control panel, a computer device loads and executes a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged, obtains an execution result, and sends the obtained execution result to a mobile terminal.
Step 302, in response to receiving the page event information sent by the mobile terminal, the computer device executes a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged based on the received page event information, obtains an execution result, and sends the obtained execution result to the mobile terminal.
Step 303, in response to receiving the execution result sent by the computer device, the mobile terminal renders and presents the page to be debugged based on the received execution result.
In step 304, the mobile terminal generates page event information related to the operation in response to detecting the operation of the user for the page to be debugged, and sends the generated page event information to the computer device.
In this embodiment, the specific operations of step 301, step 302, step 303, and step 304 are substantially the same as the operations of step 201, step 202, step 203, and step 204 in the embodiment shown in fig. 2, and are not described again here.
Step 305, the computer device loads the page to be debugged on the network panel in response to detecting the second debugging request on the network panel aiming at the page to be debugged.
In this embodiment, a Chrome developer tool may be installed in the computer device, and the Chrome developer tool may include a Network panel (i.e., a Network panel). The computer device may load the page to be debugged at the network panel upon detecting a second debug request at the network panel for the page to be debugged. In this way, the network panel may record details of the network request of the page to be debugged displayed on the computer device, and may specifically include each request resource information (including state, resource type, size, used time, request, response, input parameters, output parameters, and the like) obtained after the HTTP (Hyper-Text Transfer Protocol) request is analyzed from the initiation of the web page request of the page to be debugged, and the development engineer may perform network performance optimization according to the resource request information.
Here, the computer device may employ various implementations to determine that the second debug request is detected. For example, the computer device may determine that the second debug request is detected upon detecting an operation to open a page to be debugged at a network panel of the Chrome developer tool. The operation of opening the page to be debugged in the network panel of the Chrome developer tool can be an operation triggered by a user or an operation triggered by program code logic.
In step 306, the computer device displays the received network request detail information in the network panel in response to receiving the network request detail information sent by the mobile terminal.
In this embodiment, the computer device may display the received network request detail information in a network panel of a Chrome developer tool of the computer device, upon receiving the network request detail information sent by the mobile terminal.
And 307, the mobile terminal sends the network request detail information corresponding to the page to be debugged to the computer equipment.
In this embodiment, the mobile terminal may send, in real time, the network request detail information corresponding to the page to be debugged displayed on the mobile terminal to the computer device.
In practice, the mobile terminal may send the network request detail information corresponding to the page to be debugged displayed in the mobile terminal to the computer device through the socket according to the protocol in the network panel in the Chrome developer tool by using the browser native Resource Timing API. Here, the network request detail information corresponding to the page to be debugged displayed on the mobile terminal may specifically include each request resource information (including a state, a resource type, a size, a used time, a request, a response, an input parameter, an output parameter, and the like) obtained after the HTTP request is analyzed from the beginning after the web page request of the page to be debugged is initiated on the mobile terminal.
Through steps 305 to 307, the mobile terminal Web page can be debugged in the network panel of the Chrome developer tool installed in the computer device without the need of wired connection between the mobile terminal and the computer device, so that the development and debugging cost is reduced, and the debugging efficiency is improved.
In step 308, the computer device loads the page to be debugged in the application panel in response to detecting the third debug request in the application panel for the page to be debugged.
In this embodiment, the computer device may load the page to be debugged in the Application panel (i.e., the Application panel; some versions are also referred to as resource panels) upon detecting a third debug request at the Application panel for the page to be debugged. The development engineer may use the application panel to inspect all resources loaded, including IndexEDDB, Web SQL databases, local storage, session storage, browser cache (Cookie), application cache, images, fonts, and style sheets.
In step 309, the computer device displays the received storage information data in the application panel in response to receiving the storage information data sent by the mobile terminal.
In this embodiment, the computer device may display the received storage information data in an application panel of a Chrome developer tool of the computer device, that is, display the storage information data of the page to be debugged in the mobile terminal, when receiving the storage information data sent by the mobile terminal.
And 310, the mobile terminal sends the storage information data corresponding to the page to be debugged to the computer equipment.
In this embodiment, the mobile terminal may send, in real time, the storage information data corresponding to the page to be debugged displayed on the mobile terminal to the computer device.
In practice, the mobile terminal may obtain, by using the LocalStorage API and the SessionStorage API, storage information data corresponding to a page to be debugged displayed in the mobile terminal. Here, the storage information data corresponding to the page to be debugged displayed on the mobile terminal may specifically include IndexedDB, a Web SQL database, a local storage, a session storage, a browser cache (Cookie), an application cache, an image, a font, and a style sheet.
Through steps 308 to 310, the mobile terminal Web page can be debugged in the application panel of the Chrome developer tool installed in the computer device without the need of wired connection between the mobile terminal and the computer device, so that the development and debugging cost is reduced, and the debugging efficiency is improved.
In some optional implementations of this embodiment, the timing sequence 300 may further include steps 311 to 314 as shown in fig. 3B:
step 311, in response to detecting the fourth debugging request on the element panel for the page to be debugged, the computer device opens the page to be debugged on the element panel, and sends the DOM tree of the page to be debugged to the mobile terminal.
Here, the computer device may, in the event that a fourth debug request for a page to be debugged at an element panel (i.e., Elements panel) is detected, first open the page to be debugged at the element panel of the Chrome developer tool installed in the computer device. Here, a DOM tree of the page to be debugged is extracted and displayed in the element panel, any page element of the page to be debugged can be searched through the DOM tree, a development engineer can edit each tag attribute and style attribute of any page element in real time, and the modification of the tag attribute and the style attribute caused by the real-time editing can be fed back in the browser in real time. Then, the computer device may transmit the DOM tree of the page to be debugged extracted and displayed in the element panel to the mobile terminal.
In step 312, the computer device re-renders and presents the page to be debugged based on the received DOM tree in response to receiving the DOM tree sent by the mobile terminal.
Here, if the computer device receives the DOM tree sent by the mobile terminal, indicating that the mobile terminal has detected the update operation of the DOM tree, and sends the latest updated DOM tree, the computer device may re-render and present the page to be debugged based on the received DOM tree, thereby implementing synchronization of DOM trees of the page to be debugged displayed in the computer device and the mobile terminal.
It should be noted that rendering and presenting pages based on a DOM tree is a well-known technology that is currently widely researched and applied, and is not described herein again.
Step 313, in response to receiving the DOM tree sent by the computer device, the mobile terminal renders and presents the page to be debugged based on the received DOM tree.
Here, if the mobile terminal receives the DOM tree sent by the computer device, indicating that a development engineer edits the attribute of the page element of the page to be debugged in the element panel in the Chrome developer tool installed on the computer device, resulting in a change in the DOM tree of the page to be debugged displayed on the computer device, the mobile terminal also needs to synchronize the DOM tree of the page to be debugged displayed on the computer device, and the mobile terminal may render and present the page to be debugged based on the received DOM tree.
In step 314, the mobile terminal sends the updated DOM tree to the computer device in response to detecting the DOM tree update operation for the page to be debugged.
Here, the mobile terminal may transmit the updated DOM tree of the page to be debugged displayed in the mobile terminal to the computer device, in a case where the DOM tree update operation for the page to be debugged is detected. In this way, the computer device can synchronize the latest DOM tree of the mobile terminal in real time.
Through steps 311 to 314, the mobile-side Web page can be debugged in the element panel of the Chrome developer tool installed in the computer device without the need of wired connection between the mobile terminal and the computer device, thereby reducing the development and debugging cost and improving the debugging efficiency.
As can be seen from fig. 3, compared with the embodiment corresponding to fig. 2, the process 300 of the system for debugging pages in the present embodiment has more steps for debugging the mobile Web page in the Web panel, the application panel and the element panel of the Chrome developer tool installed in the computer device. Therefore, the scheme described in the embodiment can realize debugging of the mobile terminal Web page in the panels of more Chrome developer tools.
Referring now to FIG. 4, aflowchart 400 of one embodiment of a method for debugging a page is shown for a computer device in a system for debugging pages. The system for debugging the page comprises computer equipment and a mobile terminal which are connected through a wireless network and provided with a display. Theprocess 400 of the method for debugging a page includes the steps of:
step 401, in response to detecting a first debugging request for a page to be debugged on a source code panel or a control panel, loading and executing a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged to obtain an execution result, and sending the obtained execution result to the mobile terminal.
Step 402, in response to receiving the page event information sent by the mobile terminal, executing a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged based on the received page event information to obtain an execution result, and sending the obtained execution result to the mobile terminal.
In this embodiment, the specific operations ofstep 401 and step 402 are substantially the same as the operations of step 201 and step 202 in the embodiment shown in fig. 2, and are not described again here.
Through thesteps 401 and 402, debugging of the mobile-side Web page in the source code panel or the control panel of the Chrome developer tool installed in the computer device is realized.
In some optional implementation manners of this embodiment, the method for debugging a page may further include the followingsteps 403 and 404:
and 403, in response to detecting a second debugging request aiming at the page to be debugged at the network panel, loading the page to be debugged at the network panel.
In response to receiving the network request detail information sent by the mobile terminal,step 404, the received network request detail information is displayed in the network panel.
In this embodiment, the specific operations ofstep 403 and step 404 are substantially the same as the operations of step 305 and step 306 in the embodiment shown in fig. 3A, and are not described again here.
Throughsteps 403 and 404, debugging the mobile-side Web page in the network panel of the Chrome developer tool installed in the computer device is realized.
In some optional implementation manners of this embodiment, the method for debugging a page may further include the followingsteps 405 and 406:
step 405, in response to detecting a third debugging request in the application panel for the page to be debugged, loading the page to be debugged in the application panel.
And step 406, responding to the received storage information data sent by the mobile terminal, and displaying the received storage information data in the application panel.
In this embodiment, the specific operations ofstep 405 and step 406 are substantially the same as the operations of step 308 and step 309 in the embodiment shown in fig. 3A, and are not described again here.
Throughsteps 405 and 406, debugging the mobile-side Web page in the application panel of the Chrome developer tool installed in the computer device is achieved.
In some optional implementations of this embodiment, the method for debugging a page may further include the followingsteps 407 and 408:
step 407, in response to detecting that the user requests the fourth debugging on the element panel for the page to be debugged, opening the page to be debugged on the element panel, and sending the Document Object Model (DOM) tree of the page to be debugged to the mobile terminal.
And step 408, in response to receiving the DOM tree sent by the mobile terminal, re-rendering and presenting the page to be debugged based on the received DOM tree.
In this embodiment, the specific operations ofstep 407 and step 408 are substantially the same as the operations of step 311 and step 312 in the embodiment shown in fig. 3B, and are not described herein again.
Throughsteps 407 and 408, debugging the mobile-side Web page in the element panel of the Chrome developer tool installed in the computer device is achieved.
In some alternative implementations of the present embodiment, the mobile terminal and the computer device may communicate data through a socket.
According to the method for debugging the page, the debugging of the Web page of the mobile terminal in the source code panel or the control panel of the Chrome developer tool installed in the computer equipment is realized through the computer equipment and the mobile terminal connected with the computer equipment in a wireless network, and the mobile terminal is not required to be connected with the computer equipment through a wire, so that the development and debugging cost is reduced, and the debugging efficiency is improved.
With further reference to fig. 5, as an implementation of the methods shown in the above-mentioned figures, the present application provides an embodiment of an apparatus for debugging a page, which is applied to a computer device in a system for debugging a page, where the system for debugging a page includes a computer device provided with a display and a mobile terminal connected by a wireless network, and the embodiment of the apparatus corresponds to the embodiment of the method shown in fig. 2, and the apparatus can be applied to various electronic devices in particular.
As shown in fig. 5, theapparatus 500 for debugging a page of the present embodiment includes: a first executionresult transmission unit 501 and a second executionresult transmission unit 502. The first executionresult sending unit 501 is configured to, in response to detecting a first debugging request for a page to be debugged on a source code panel or a control panel, load and execute a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged, obtain an execution result, and send the obtained execution result to the mobile terminal; a second executionresult sending unit 502, configured to, in response to receiving the page event information sent by the mobile terminal, execute, in a thread corresponding to the page to be debugged, a code corresponding to the page to be debugged based on the received page event information, obtain an execution result, and send the obtained execution result to the mobile terminal.
In this embodiment, specific processing of the first executionresult sending unit 501 and the second executionresult sending unit 502 of theapparatus 500 for debugging a page and technical effects brought by the processing can refer to related descriptions of step 201 and step 202 in the corresponding embodiment of fig. 2, which are not described herein again.
In some optional implementations of this embodiment, theapparatus 500 may further include: a firstpage loading unit 503, configured to load the page to be debugged on the network panel in response to detecting a second debug request on the network panel for the page to be debugged; afirst display unit 504 configured to display the received network request detail information in the network panel in response to receiving the network request detail information transmitted by the mobile terminal.
In some optional implementations of this embodiment, theapparatus 500 may further include: a secondpage loading unit 505, configured to, in response to detecting a third debugging request in an application panel for the page to be debugged, load the page to be debugged in the application panel; asecond display unit 506 configured to display the received storage information data in the application panel in response to receiving the storage information data transmitted by the mobile terminal.
In some optional implementations of this embodiment, theapparatus 500 may further include: a document objectmodel sending unit 507 configured to open the page to be debugged on the element panel and send a DOM tree of the page to be debugged to the mobile terminal in response to detecting a fourth debugging request of the user on the element panel for the page to be debugged; and the page rendering and presentingunit 508 is configured to re-render and present the page to be debugged based on the received DOM tree in response to receiving the DOM tree sent by the mobile terminal.
In some optional implementations of this embodiment, the mobile terminal and the computer device may perform data communication through a socket.
It should be noted that details of implementation and technical effects of each unit in the apparatus for debugging a page provided in the embodiment of the present application may refer to descriptions of other embodiments in the present application, and are not described herein again.
Referring now to FIG. 6, shown is a block diagram of acomputer system 600 suitable for use in implementing the computer devices of embodiments of the present application. The computer device shown in fig. 6 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. 6, thecomputer system 600 includes a Central Processing Unit (CPU)601, which can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 602 or a program loaded from astorage section 608 into a Random Access Memory (RAM) 603. In theRAM 603, various programs and data necessary for the operation of thesystem 600 are also stored. TheCPU 601,ROM 602, andRAM 603 are connected to each other via abus 604. An Input/Output (I/O)interface 605 is also connected tobus 604.
The following components are connected to the I/O interface 605: aninput portion 606 including a keyboard, a mouse, and the like; anoutput section 607 including a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, a speaker, and the like; astorage section 608 including a hard disk and the like; and acommunication section 609 including a Network interface card such as a LAN (Local Area Network) card, a modem, or the like. Thecommunication section 609 performs communication processing via a network such as the internet. Thedriver 610 is also connected to the I/O interface 605 as needed. Aremovable medium 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on thedrive 610 as necessary, so that a computer program read out therefrom is mounted in thestorage section 608 as necessary.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through thecommunication section 609, and/or installed from theremovable medium 611. The computer program performs the above-described functions defined in the method of the present application when executed by a Central Processing Unit (CPU) 601. It should be noted that the computer readable medium mentioned above in the present application may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present application, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In this application, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present application may be implemented by software or hardware. The described units may also be provided in a processor, and may be described as: a processor includes a first execution result transmission unit and a second execution result transmission unit. The names of the units do not limit the unit itself in some cases, for example, the first execution result sending unit may also be described as a unit that sends an execution result obtained by executing the code corresponding to the page to be debugged to the mobile terminal.
As another aspect, the present application also provides a computer-readable medium, which may be contained in the apparatus described in the above embodiments; or may be present separately and not assembled into the device. The computer readable medium carries one or more programs which, when executed by the apparatus, cause the apparatus to: in response to detecting a first debugging request aiming at a page to be debugged on a source code panel or a control panel, loading and executing a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged to obtain an execution result, and sending the obtained execution result to the mobile terminal; and responding to the received page event information sent by the mobile terminal, executing a code corresponding to the page to be debugged in a thread corresponding to the page to be debugged based on the received page event information to obtain an execution result, and sending the obtained execution result to the mobile terminal.
The above description is only a preferred embodiment of the application and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the invention herein disclosed is not limited to the particular combination of features described above, but also encompasses other arrangements formed by any combination of the above features or their equivalents without departing from the spirit of the invention. For example, the above features may be replaced with (but not limited to) features having similar functions disclosed in the present application.