CN105573733A - Communication method for browser and web front end and web front end and system - Google Patents

Communication method for browser and web front end and web front end and system Download PDF

Info

Publication number
CN105573733A
CN105573733A CN201410549577.8A CN201410549577A CN105573733A CN 105573733 A CN105573733 A CN 105573733A CN 201410549577 A CN201410549577 A CN 201410549577A CN 105573733 A CN105573733 A CN 105573733A
Authority
CN
China
Prior art keywords
web
browser
request event
global variable
command queue
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201410549577.8A
Other languages
Chinese (zh)
Other versions
CN105573733B (en
Inventor
于小军
田淑宁
夏李
曾亮
薄川川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201410549577.8A priority Critical patent/CN105573733B/en
Publication of CN105573733A publication Critical patent/CN105573733A/en
Application granted granted Critical
Publication of CN105573733B publication Critical patent/CN105573733B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention relates to a communication method for a browser and a web front end and the web front end and a system. The method comprises the steps as follows: the web front end responds to an interface call instruction, and generates an id for marking a request event corresponding to the interface call instruction; the web front end obtains interface parameters of the request event according to the interface call instruction; the web front end stores the request event, the id and the interface parameters into a global variable command queue; the web front end transmits the global variable command queue to the browser; and the browser reads the request event, the id and the interface parameters from the global variable command queue after receiving the global variable command queue and processes the request event. By the communication method for the browser and the web front end, the web front end can actively communicate with a browser client; and the browser client can also actively communicate with the web front end and can preserve a function field, so that effective communication between the web front end and the browser client is achieved; and the cost of learning and using an API by a developer is reduced.

Description

The method that browser communicates with web front-end, web front-end and system
Technical field
The present invention relates to picture Processing Technique field, particularly relate to method, web front-end and system that a kind of browser communicates with web front-end.
Background technology
At present, the browser run on ios system is all based on safari kernel, the API that web front-end cannot directly use browser client to provide, and namely web front-end lacks the mechanism with browser client active communication.
For browser client, the overall javascript code of web front-end can be accessed, the javascript code of browser client access web front-end adopts following two kinds of modes usually: the function performing the overall situation function name correspondence that web front-end imports into, or the function body that execution web front-end imports into.
But all there is serious drawback in above-mentioned two kinds of modes: first kind of way requires that the function name imported into needs a corresponding overall situation function, this mode is for disaster only not asynchronous interface, because call an API to mean and need generation global variable, so not only can pollute NameSpace, also can committed memory; The second way can make the action scope chain in the function body imported into lose efficacy, global variable can only be accessed in function body, what this was corresponding is window object, and now function body cannot retain scene, and the existence of these underlying rules will bring larger complexity to web front-end exploitation.
Summary of the invention
Method, web front-end and system that the embodiment of the present invention provides a kind of browser to communicate with web front-end, be intended to the efficient communication realized between web front-end and browser client, reduces developer to the use cost of api interface.
The embodiment of the present invention proposes a kind of method that browser communicates with web front-end, comprising:
Web front-end response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event;
Described web front-end, according to described interface interchange instruction, obtains the interface parameters of described request event;
Described web front-end by described request event, id and described interface parameters stored in global variable command queue;
Described global variable command queue, by the mode of the setting attribute assignment of the label be pre-created, is sent to browser by described web front-end;
After described browser receives described global variable command queue, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
The embodiment of the present invention also propose that a kind of browser communicates with web front-end system, comprising: browser and the web front-end communicated to connect with described browser; Wherein:
Described web front-end, for response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event; According to described interface interchange instruction, obtain the interface parameters of described request event; By described request event, id and described interface parameters stored in global variable command queue; By to the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser;
Described browser, after receiving described global variable command queue, reads described request event, id and described interface parameters, processes described request event from described global variable command queue.
The embodiment of the present invention also proposes a kind of web front-end, comprising:
Generation module, for response interface call instruction, generates the id identifying request event corresponding to described interface interchange instruction;
Acquisition module, for according to described interface interchange instruction, obtains the interface parameters of described request event;
Memory module, for by described request event, id and described interface parameters stored in global variable command queue;
Sending module, for being sent to browser by described global variable command queue; After receiving described global variable command queue by described browser, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
Method, web front-end and system that a kind of browser that the embodiment of the present invention proposes communicates with web front-end, by the iframe label created, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieve the efficient communication between web front-end and browser client, reduce the cost that developer learns to use API.
Accompanying drawing explanation
Fig. 1 is the system architecture schematic diagram that browser that the embodiment of the present invention relates to communicates with web front-end;
Fig. 2 is the mutual time diagram of embodiment of the present invention browser client and web front-end;
Fig. 3 is the web front-end hardware running environment schematic diagram that embodiment of the present invention scheme relates to;
Fig. 4 is the schematic flow sheet of method first embodiment that browser of the present invention communicates with web front-end;
Fig. 5, after browser receives described global variable command queue in the embodiment of the present invention, reads described request event from described global variable command queue, and interface parameters, to the schematic flow sheet that described request event processes;
Fig. 6 is the schematic flow sheet of method second embodiment that browser of the present invention communicates with web front-end;
Fig. 7 is the schematic flow sheet of method the 3rd embodiment that browser of the present invention communicates with web front-end;
Fig. 8 is the schematic flow sheet of method the 4th embodiment that browser of the present invention communicates with web front-end;
Fig. 9 is the schematic flow sheet of method the 5th embodiment that browser of the present invention communicates with web front-end;
Figure 10 is the schematic flow sheet of method the 6th embodiment that browser of the present invention communicates with web front-end;
Figure 11 is the high-level schematic functional block diagram of web front-end first embodiment of the present invention;
Figure 12 is the high-level schematic functional block diagram of web front-end second embodiment of the present invention.
In order to make technical scheme of the present invention clearly, understand, be described in further detail below in conjunction with accompanying drawing.
Embodiment
Should be appreciated that specific embodiment described herein only in order to explain the present invention, be not intended to limit the present invention.
The primary solutions of the embodiment of the present invention is: by the iframe label created, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieve the efficient communication between web front-end and browser client, reduce the cost that developer learns to use API.
As shown in Figure 1, Fig. 1 is the system architecture that browser that embodiment of the present invention scheme relates to communicates with web front-end, and this system architecture comprises: browser client 102 and the web front-end 101 communicated to connect with described browser client 102; Wherein:
Described web front-end 101, for response interface call instruction, generates an id in order to identify request event corresponding to described interface interchange instruction; According to described interface interchange instruction, obtain the interface parameters of described request event; By described request event, id and described interface parameters stored in global variable command queue; By to the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser;
Described browser, after receiving described global variable command queue, reads described request event, id and described interface parameters, processes described request event from described global variable command queue.
Particularly, the present embodiment browser client 102 can be pc client, also can be the mobile terminal that mobile phone, panel computer etc. have web page browsing function.
For the mobile phone terminal of ios system, because the browser on the existing ios of running on system is all based on safari kernel, the API that web front-end 101 cannot directly use browser client 102 to provide, namely web front-end 101 lacks the mechanism with browser client 102 active communication.And for browser client 102, although the overall javascript code of web front-end 101 can be accessed, function scene cannot be retained, bring larger complexity to web front-end 101 exploitation.
The present embodiment scheme can set up the bridge of a communication between web front-end 101 and browser client 102, by this bridge, web front-end 101 can initiatively communicate with browser client 102, browser client 102 also initiatively can communicate with web front-end 101 and retain function scene, realize the efficient communication between web front-end 101 and browser client 102, reduce the cost that developer learns to use API.The interaction flow of the present embodiment browser client 102 and web front-end 101 as shown in Figure 2.
Particularly, create at web front-end 101 and have a label, the present embodiment is illustrated with a hiding iframe label.Web front-end 101 is when giving the src attribute assignment of this iframe label, and can trigger an event, and browser client 102 can capture this event in time, meanwhile, browser also can intercept and capture the src information of iframe label.
Therefore, based on this principle, the bridge of communication between web front-end 101 and browser client 102 can be set up by the mode creating a hiding iframe.Due to web front-end 101 at every turn create iframe label and assignment time all can trigger an event, so be common behavior or a transmission order to distinguish establishment iframe label, the present embodiment defines the special format of src, and the form of this src is consulted to produce, so that browser client 102 can capture src property value in time by web front-end 101 and browser client 102.
The present embodiment definition src adopts following form: mtt:service:action.
Wherein, mtt is character string constant, service and action uniquely determines a behavior of ordering, and service identifies the behavior of large class, and action identifies the segmentation behavior under large class.
By this communication mode, the API that browser client 102 externally provides is asynchronous interface, development of user can import the type of service and action marking command into, and using option as command parameter, suc is as successful call back function, err is as the call back function of failure, and thus, the form of a definition api interface is:
browserApi(service,action,option,suc,err)。
Development of user can call the code library that web front-end 101 provides, and triggers calling client end AP PCI interface.Wherein, the code library of web front-end 101 is specifically as follows javascript code library.
Web front-end 101 responds the interface interchange instruction that development of user triggers, and can produce the request event that sends to browser client 102, initiates an order thus.
Before web front-end 101 pairs of browser clients 102 initiate an order, the meeting random number that generation one is unique automatically identifies this order as id, that is, generate an id in order to identify request event corresponding to described interface interchange instruction.
In addition, web front-end 101 also according to described interface interchange instruction, can obtain the interface parameters of described request event.This interface parameters comprises: the type of request event and the command parameter of request event; Wherein, the type of request event is by above-mentioned service and action mark; The command parameter of request event is identified by option.
The interface parameters of the request event of above-mentioned acquisition is used for sending browser client 102 to, is convenient to browser client 102 pairs of request events and processes.
At web front-end 101, also can safeguard that a command queue queue (the present embodiment claims global variable command queue) preserves these request events (containing id, the type of request event and the command parameter of request event that request event is corresponding).
Why web front-end 101 preserves request event, id and interface parameters by global variable command queue, be consider that development of user repeatedly may call browser client 102API interface within a period of time, and browser client 102 not necessarily can process these request events in time.Therefore, global variable command queue is adopted to preserve these orders of request event, send to browser client 102 in batches, thus the process opportunity of browser client 102 reasonable arrangement request event can be ensured, improve the efficiency of browser side system performance and data processing, also alleviate the data processing pressure of web front-end 101 simultaneously.
Then, web front-end 101 in a predetermined format, to the src attribute assignment of iframe label, triggers the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
Thus, by the mode of the src assignment of the hiding iframe created, the global variable command queue comprising request event and correlation parameter thereof is communicated to browser client 102.
Web front-end 101 passes through to the mode of the src assignment of the hiding iframe created, and when global variable command queue is communicated to browser client 102, can trigger an event, as previously mentioned, browser can capture this event in time.
In browser side, browser client 102 can catch src attribute format and the src property value of iframe label, and judges src attribute format and src property value, judges whether src attribute format is the form of arranging, and whether src property value changes.
Then, according to src attribute format and the src property value of described iframe label, obtain global variable command queue.
Browser client 102 is after receiving described global variable command queue, the queue of calling the overall situation obtains function (getQueue), described request event is read from described global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of described request event, type and command parameter, respective handling is carried out to described request event.
After browser client 102 has processed an order, if process successfully, browser has called an overall successful process function (sucCallback), imports the command parameter of result, described request event and id into described web front-end 101.
When processing unsuccessfully, described browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end 101.
Thus, by above-mentioned three overall situation function getQueue, sucCallback and errCallback (queue of the overall situation obtains function, the successful process function of the overall situation and the failure handling function of the overall situation), the call back function of external API can be made to retain on-the-spot, because whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after follow-up web front-end 101 fill order needs not be the function of the overall situation, and the scene of this call back function can be retained.
The present embodiment passes through such scheme, by the iframe label created, the bridge of a communication is set up between web front-end 101 and browser client 102, by this bridge, web front-end 101 can initiatively communicate with browser client 102, browser client 102 also initiatively can communicate with web front-end 101 and retain function scene, thus achieves the efficient communication between web front-end 101 and browser client 102.
In addition, when specific implementation, by the queue maintenance mechanism providing a basic java script module to encapsulate communication mode between above-mentioned web front-end 101 and browser client 102 and command calls, an API customized externally is provided.Development of user only need can use API by the assembly introducing this lightweight, and realizes without concerned with internal, and without any underlying rule, thus reduce the cost that development of user study uses API.
Further, described web front-end 101, also for according to the result of described browser to described request event, carries out corresponding operating.
Particularly, in the present embodiment, web front-end 101, according to interface interchange instruction, obtains in the interface parameters of request event and also comprises: the successful call back function of request event and failed call back function.
Wherein, web front-end 101 can using the id of request event that gets as key value, using the successful call back function of request event and failed call back function as value value stored in a match objects.
Afterwards, web front-end 101, according to the result of browser to request event, when carrying out corresponding operating, specifically adopts following scheme:
After browser is to request event process success, web front-end 101, according to the id of request event, finds corresponding successful call back function, and performs from described match objects; After described browser is to described request event handling failure, described web front-end 101, according to the id of request event, finds corresponding failed call back function, and performs from described match objects.
Below elaborates browser client 102 and process request, and web front-end 101 obtains the detailed process of carrying out corresponding operating after browser client 102 responds:
Browser client 102 is after receiving global variable command queue, and the queue of calling the overall situation obtains function (getQueue), read requests event from global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of request event, type and command parameter, respective handling is carried out to request event.
After browser client 102 has processed an order, if process successfully, browser has called an overall successful process function (sucCallback), imports the command parameter of result, request event and id into web front-end 101.Web front-end 101 finds corresponding successful call back function according to the id received from match objects, and performs.
When after the failure of browser process request event, browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end 101.Web front-end 101 finds corresponding failed call back function according to the id received from match objects, and performs.
By this method, whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after web front-end 101 fill order needs not be the function of the overall situation, and the scene of this call back function can be retained.
Further, described web front-end 101, also for judging whether the iframe label created for communicating; If so, then by the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser; Otherwise create described iframe label.
Web front-end 101 is by judging, do not have if current to create the iframe label for communicating, then create this iframe label, the iframe label created for communicating is had if current, then by the mode of the setting attribute assignment of the label be pre-created, global variable command queue is sent to browser.
The present embodiment is by upper scheme, by creating iframe label, the bridge of a communication is set up between web front-end 101 and browser client 102, by this bridge, web front-end 101 can initiatively communicate with browser client 102, browser client 102 also initiatively can communicate with web front-end 101 and retain function scene, thus achieves the efficient communication between web front-end 101 and browser client 102, reduces the cost that developer learns to use API.
As shown in Figure 3, Fig. 3 is the web front-end hardware running environment schematic diagram that embodiment of the present invention scheme relates to, and this web front-end can be PC, also can other server.
As shown in Figure 3, this web front-end can comprise: processor 1001, such as CPU, network interface 1004, user interface 1003, storer 1005, communication bus 1002.Wherein, communication bus 1002 is for realizing the connection communication between these assemblies.User interface 1003 can comprise display screen (Display), keyboard (Keyboard), and optional user interface 1003 can also comprise wireline interface, the wave point of standard.Network interface 1004 optionally can comprise wireline interface, the wave point (as WI-FI interface) of standard.Storer 1005 can be high-speed RAM storer, also can be stable storer (non-volatilememory), such as magnetic disk memory.Storer 1005 can also be optionally the memory storage independent of aforementioned processor 1001.As shown in Figure 3, operating system, network communication module, Subscriber Interface Module SIM and communication application program can be comprised as in a kind of storer 1005 of computer-readable storage medium.
In the web front-end shown in Fig. 3, network interface 1004 is mainly used in connecting browser client, carries out data communication with browser client; User interface 1003 is mainly used in carrying out data communication with development of user end; And processor 1001 may be used for calling the communication application program stored in storer 1005, and perform following operation:
Response interface call instruction, generates an id in order to identify request event corresponding to described interface interchange instruction;
According to described interface interchange instruction, obtain the interface parameters of described request event;
By described request event, id and described interface parameters stored in global variable command queue;
By to the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser; After receiving described global variable command queue by described browser, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
Further, in one embodiment, processor 1001 calls the communication application program stored in storer 1005 and can perform following operation:
In a predetermined format, to the src attribute assignment of described iframe label, to trigger the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
Further, in one embodiment, processor 1001 calls the communication application program stored in storer 1005 and can perform following operation:
According to the result of described browser to described request event, carry out corresponding operating.
Further, in one embodiment, processor 1001 calls the communication application program stored in storer 1005 and can perform following operation:
According to described interface interchange instruction, also comprise after obtaining the interface parameters of described request event:
Using described id as key value, using the successful call back function in described interface parameters and failed call back function as value value stored in a match objects;
After described browser is to described request event handling success, according to described id, from described match objects, find corresponding successful call back function, and perform;
After described browser is to described request event handling failure, according to described id, from described match objects, find corresponding failed call back function, and perform.
Further, in one embodiment, processor 1001 calls the communication application program stored in storer 1005 and can perform following operation:
Judge whether the iframe label created for communicating; If so, then by the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser; Otherwise create described iframe label.
The present embodiment passes through such scheme, by creating iframe label, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client, reduces the cost that developer learns to use API.
Based on said system framework and hardware structure, the embodiment of the method that browser of the present invention communicates with web front-end is proposed.
As shown in Figure 4, first embodiment of the invention proposes a kind of method that browser communicates with web front-end, and be specifically related to the method that browser client communicates with web front-end, the method comprises:
Step S101, web front-end response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event;
The present embodiment browser client can be pc client, also can be the mobile terminal that mobile phone, panel computer etc. have web page browsing function.
For the mobile phone terminal of ios system, because the browser on the existing ios of running on system is all based on safari kernel, the API that web front-end cannot directly use browser client to provide, namely web front-end lacks the mechanism with browser client active communication.And for browser client, although the overall javascript code of web front-end can be accessed, function scene cannot be retained, bring larger complexity to web front-end exploitation.
The present embodiment scheme can set up the bridge of a communication between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, realize the efficient communication between web front-end and browser client, reduce the cost that developer learns to use API.
Particularly, create at web front-end and have a label, the present embodiment is illustrated with a hiding iframe label.Web front-end is when giving the src attribute assignment of this iframe label, and can trigger an event, and browser client can capture this event in time, meanwhile, browser also can intercept and capture the src information of iframe label.
Therefore, based on this principle, can set up by the mode creating a hiding iframe bridge communicated between web front-end and browser client.Due to web front-end create iframe label at every turn and assignment time all can trigger an event, so be common behavior or a transmission order to distinguish establishment iframe label, the present embodiment defines the special format of src, and the form of this src is consulted to produce by web front-end and browser client, so that browser client can capture src property value in time.
The present embodiment definition src adopts following form: mtt:service:action.
Wherein, mtt is character string constant, service and action uniquely determines a behavior of ordering, and service identifies the behavior of large class, and action identifies the segmentation behavior under large class.
By this communication mode, the API that browser client externally provides is asynchronous interface, development of user can import the type of service and action marking command into, and using option as command parameter, suc is as successful call back function, err is as the call back function of failure, and thus, the form of a definition api interface is:
browserApi(service,action,option,suc,err)。
Development of user can call the code library that web front-end provides, and triggers calling client end AP PCI interface.Wherein, the code library of web front-end is specifically as follows javascript code library.
The interface interchange instruction that web front-end response development of user triggers, can produce the request event that sends to browser client, initiate an order thus.
Before web front-end initiates an order to browser client, the meeting random number that generation one is unique automatically identifies this order as id, that is, generate an id in order to identify request event corresponding to described interface interchange instruction.
Step S102, described web front-end, according to described interface interchange instruction, obtains the interface parameters of described request event;
In addition, web front-end also according to described interface interchange instruction, can obtain the interface parameters of described request event.This interface parameters comprises: the type of request event and the command parameter of request event; Wherein, the type of request event is by above-mentioned service and action mark; The command parameter of request event is identified by option.
The interface parameters of the request event of above-mentioned acquisition is used for sending browser client to, is convenient to browser client and processes request event.
Step S103, described web front-end by described request event, id and described interface parameters stored in global variable command queue;
At web front-end, also can safeguard that a command queue queue (the present embodiment claims global variable command queue) preserves these request events (containing id, the type of request event and the command parameter of request event that request event is corresponding).
Why web front-end preserves request event, id and interface parameters by global variable command queue, be consider that development of user may repeatedly call browser client api interface within a period of time, and browser client not necessarily can process these request events in time.Therefore, global variable command queue is adopted to preserve these orders of request event, send to browser client in batches, thus the process opportunity of browser client reasonable arrangement request event can be ensured, improve the efficiency of browser side system performance and data processing, also alleviate the data processing pressure of web front-end simultaneously.
Step S104, described global variable command queue is sent to browser by described web front-end;
Then, web front-end in a predetermined format, to the src attribute assignment of iframe label, triggers the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
Thus, by the mode of the src assignment of the hiding iframe created, the global variable command queue comprising request event and correlation parameter thereof is communicated to browser client.
Step S105, after described browser receives described global variable command queue, reads described request event, id and described interface parameters, processes described request event from described global variable command queue.
Web front-end passes through to the mode of the src assignment of the hiding iframe created, and when global variable command queue is communicated to browser client, can trigger an event, as previously mentioned, browser can capture this event in time.
In browser side, browser client can catch src attribute format and the src property value of iframe label, and judges src attribute format and src property value, judges whether src attribute format is the form of arranging, and whether src property value changes.
Then, according to src attribute format and the src property value of described iframe label, obtain global variable command queue.
Browser client is after receiving described global variable command queue, the queue of calling the overall situation obtains function (getQueue), described request event is read from described global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of described request event, type and command parameter, respective handling is carried out to described request event.
After browser client process completes an order, if process successfully, browser calls an overall successful process function (sucCallback), imports the command parameter of result, described request event and id into described web front-end.
When processing unsuccessfully, described browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end.
Thus, by above-mentioned three overall situation function getQueue, sucCallback and errCallback (queue of the overall situation obtains function, the successful process function of the overall situation and the failure handling function of the overall situation), the call back function of external API can be made to retain on-the-spot, because whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after follow-up web front-end fill order needs not be the function of the overall situation, and the scene of this call back function can be retained.
More specifically, as shown in Figure 5, above-mentioned steps S105: after browser receives described global variable command queue, reads described request event from described global variable command queue, and interface parameters, and carrying out process to described request event can comprise:
Step S1051, after browser receives described global variable command queue, the queue of calling the overall situation obtains function, from described global variable command queue, read described request event, and the id of request event, type and command parameter;
Step S1052, described browser processes described request event according to the id of described request event, type and command parameter;
Step S1053, when processing successfully, described browser calls the successful process function of the overall situation, imports the command parameter of result, described request event and id into described web front-end;
Step S1054, when processing unsuccessfully, described browser calls the failure handling function of the overall situation, imports the command parameter of result, described request event and id into described web front-end.
The present embodiment passes through such scheme, by the iframe label created, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client.
In addition, when specific implementation, by the queue maintenance mechanism providing a basic java script module to encapsulate communication mode between above-mentioned web front-end and browser client and command calls, an API customized externally is provided.Development of user only need can use API by the assembly introducing this lightweight, and realizes without concerned with internal, and without any underlying rule, thus reduce the cost that development of user study uses API.
As shown in Figure 6, second embodiment of the invention proposes a kind of method that browser communicates with web front-end, on the basis of the first embodiment shown in above-mentioned Fig. 4:
At above-mentioned steps S102, web front-end, according to described interface interchange instruction, after obtaining the interface parameters of described request event, also comprises:
Step S106, described web front-end using described id as key value, using described successful call back function and failed call back function as value value stored in a match objects.
Also comprise after above-mentioned steps S105:
Step S107, web front-end, according to the result of described browser to described request event, carries out corresponding operating.
The difference of the first embodiment shown in the present embodiment and above-mentioned Fig. 4 is, the present embodiment also comprises web front-end carries out corresponding operating scheme to browser client result.
Particularly, in the present embodiment, web front-end, according to interface interchange instruction, obtains in the interface parameters of request event and also comprises: the successful call back function of request event and failed call back function.
Wherein, web front-end can using the id of request event that gets as key value, using the successful call back function of request event and failed call back function as value value stored in a match objects.
Afterwards, web front-end, according to the result of browser to request event, when carrying out corresponding operating, specifically adopts following scheme:
After browser is to request event process success, web front-end, according to the id of request event, finds corresponding successful call back function, and performs from described match objects; After described browser is to described request event handling failure, described web front-end, according to the id of request event, finds corresponding failed call back function, and performs from described match objects.
Below elaborate browser client process request, and web front-end obtains the detailed process of carrying out corresponding operating after browser client responds:
Browser client is after receiving global variable command queue, and the queue of calling the overall situation obtains function (getQueue), read requests event from global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of request event, type and command parameter, respective handling is carried out to request event.
After browser client process completes an order, if process successfully, browser calls an overall successful process function (sucCallback), imports the command parameter of result, request event and id into web front-end.Web front-end finds corresponding successful call back function according to the id received from match objects, and performs.
When after the failure of browser process request event, browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end.Web front-end finds corresponding failed call back function according to the id received from match objects, and performs.
By this method, whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after web front-end fill order needs not be the function of the overall situation, and can retain the scene of this call back function.
As shown in Figure 7, third embodiment of the invention proposes a kind of method that browser communicates with web front-end, on the basis of the second embodiment shown in above-mentioned Fig. 6, pass through to the mode of the setting attribute assignment of the label be pre-created in above-mentioned steps S104:web front end, also comprise before described global variable command queue is sent to browser:
Step S108, web front-end judges whether the iframe label created for communicating; If so, then step S104 is entered; Otherwise, enter step S109;
Step S109, creates described iframe label, and enters step S104.
The difference of the second embodiment shown in the present embodiment and above-mentioned Fig. 6 is, the present embodiment also comprises the scheme whether creating iframe label.
Web front-end is by judging, not having if current to create the iframe label for communicating, then create this iframe label, having the iframe label created for communicating if current, then by the mode of the setting attribute assignment of the label be pre-created, global variable command queue is sent to browser.
The present embodiment is by upper scheme, by creating iframe label, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client, reduces the cost that developer learns to use API.
As shown in Figure 8, fourth embodiment of the invention proposes a kind of method that browser communicates with web front-end, comprising:
Step S201, web front-end response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event;
Step S202, according to described interface interchange instruction, obtains the interface parameters of described request event;
Step S203, by described request event, id and described interface parameters stored in global variable command queue;
Step S204, is sent to browser by described global variable command queue; After receiving described global variable command queue by described browser, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
Particularly, for the mobile phone terminal of ios system, because the browser on the existing ios of running on system is all based on safari kernel, the API that web front-end cannot directly use browser client to provide, namely web front-end lacks the mechanism with browser client active communication.And for browser client, although the overall javascript code of web front-end can be accessed, function scene cannot be retained, bring larger complexity to web front-end exploitation.
The present embodiment scheme can set up the bridge of a communication between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, realize the efficient communication between web front-end and browser client, reduce the cost that developer learns to use API.
Particularly, create at web front-end and have a label, the present embodiment is illustrated with a hiding iframe label.Web front-end is when giving the src attribute assignment of this iframe label, and can trigger an event, and browser client can capture this event in time, meanwhile, browser also can intercept and capture the src information of iframe label.
Therefore, based on this principle, can set up by the mode creating a hiding iframe bridge communicated between web front-end and browser client.Due to web front-end create iframe label at every turn and assignment time all can trigger an event, so be common behavior or a transmission order to distinguish establishment iframe label, the present embodiment defines the special format of src, and the form of this src is consulted to produce by web front-end and browser client, so that browser client can capture src property value in time.
The present embodiment definition src adopts following form: mtt:service:action.
Wherein, mtt is character string constant, service and action uniquely determines a behavior of ordering, and service identifies the behavior of large class, and action identifies the segmentation behavior under large class.
By this communication mode, the API that browser client externally provides is asynchronous interface, development of user can import the type of service and action marking command into, and using option as command parameter, suc is as successful call back function, err is as the call back function of failure, and thus, the form of a definition api interface is:
browserApi(service,action,option,suc,err)。
Development of user can call the code library that web front-end provides, and triggers calling client end AP PCI interface.Wherein, the code library of web front-end is specifically as follows javascript code library.
The interface interchange instruction that web front-end response development of user triggers, can produce the request event that sends to browser client, initiate an order thus.
Before web front-end initiates an order to browser client, the meeting random number that generation one is unique automatically identifies this order as id, that is, generate an id in order to identify request event corresponding to described interface interchange instruction.
In addition, web front-end also according to described interface interchange instruction, can obtain the interface parameters of described request event.This interface parameters comprises: the type of request event and the command parameter of request event; Wherein, the type of request event is by above-mentioned service and action mark; The command parameter of request event is identified by option.
The interface parameters of the request event of above-mentioned acquisition is used for sending browser client to, is convenient to browser client and processes request event.
At web front-end, also can safeguard that a command queue queue (the present embodiment claims global variable command queue) preserves these request events (containing id, the type of request event and the command parameter of request event that request event is corresponding).
Why web front-end preserves request event, id and interface parameters by global variable command queue, be consider that development of user may repeatedly call browser client api interface within a period of time, and browser client not necessarily can process these request events in time.Therefore, global variable command queue is adopted to preserve these orders of request event, send to browser client in batches, thus the process opportunity of browser client reasonable arrangement request event can be ensured, improve the efficiency of browser side system performance and data processing, also alleviate the data processing pressure of web front-end simultaneously.
Then, web front-end in a predetermined format, to the src attribute assignment of iframe label, triggers the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
Thus, by the mode of the src assignment of the hiding iframe created, the global variable command queue comprising request event and correlation parameter thereof is communicated to browser client.
Web front-end passes through to the mode of the src assignment of the hiding iframe created, and when global variable command queue is communicated to browser client, can trigger an event, as previously mentioned, browser can capture this event in time.
In browser side, browser client can catch src attribute format and the src property value of iframe label, and judges src attribute format and src property value, judges whether src attribute format is the form of arranging, and whether src property value changes.
Then, according to src attribute format and the src property value of described iframe label, obtain global variable command queue.
Browser client is after receiving described global variable command queue, the queue of calling the overall situation obtains function (getQueue), described request event is read from described global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of described request event, type and command parameter, respective handling is carried out to described request event.
After browser client process completes an order, if process successfully, browser calls an overall successful process function (sucCallback), imports the command parameter of result, described request event and id into described web front-end.
When processing unsuccessfully, described browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end.
Thus, by above-mentioned three overall situation function getQueue, sucCallback and errCallback (queue of the overall situation obtains function, the successful process function of the overall situation and the failure handling function of the overall situation), the call back function of external API can be made to retain on-the-spot, because whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after follow-up web front-end fill order needs not be the function of the overall situation, and the scene of this call back function can be retained.
The present embodiment passes through such scheme, by the iframe label created, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client.
In addition, when specific implementation, by the queue maintenance mechanism providing a basic java script module to encapsulate communication mode between above-mentioned web front-end and browser client and command calls, an API customized externally is provided.Development of user only need can use API by the assembly introducing this lightweight, and realizes without concerned with internal, and without any underlying rule, thus reduce the cost that development of user study uses API.
As shown in Figure 9, fifth embodiment of the invention proposes a kind of method that browser communicates with web front-end, on the basis of the 4th embodiment shown in above-mentioned Fig. 8:
After above-mentioned steps S202, also comprise:
Step S205, described web front-end using described id as key value, using the successful call back function in described interface parameters and failed call back function as value value stored in a match objects;
After above-mentioned steps S204, also comprise:
Step S206, described web front-end, according to the result of described browser to described request event, carries out corresponding operating.
The difference of the 4th embodiment shown in the present embodiment and above-mentioned Fig. 8 is, the present embodiment also comprises web front-end carries out corresponding operating scheme to browser client result.
Particularly, in the present embodiment, web front-end, according to interface interchange instruction, obtains in the interface parameters of request event and also comprises: the successful call back function of request event and failed call back function.
Wherein, web front-end can using the id of request event that gets as key value, using the successful call back function of request event and failed call back function as value value stored in a match objects.
Afterwards, web front-end, according to the result of browser to request event, when carrying out corresponding operating, specifically adopts following scheme:
After browser is to request event process success, web front-end, according to the id of request event, finds corresponding successful call back function, and performs from described match objects; After described browser is to described request event handling failure, described web front-end, according to the id of request event, finds corresponding failed call back function, and performs from described match objects.
Below elaborate browser client process request, and web front-end obtains the detailed process of carrying out corresponding operating after browser client responds:
Browser client is after receiving global variable command queue, and the queue of calling the overall situation obtains function (getQueue), read requests event from global variable command queue, and the id of request event, type and command parameter.
Then, according to the id of request event, type and command parameter, respective handling is carried out to request event.
After browser client process completes an order, if process successfully, browser calls an overall successful process function (sucCallback), imports the command parameter of result, request event and id into web front-end.Web front-end finds corresponding successful call back function according to the id received from match objects, and performs.
When after the failure of browser process request event, browser calls the failure handling function (errCallback) of the overall situation, imports the command parameter of result, described request event and id into described web front-end.Web front-end finds corresponding failed call back function according to the id received from match objects, and performs.
By this method, whole system only need safeguard three overall situation function getQueue, sucCallback and errCallback, and the success and failure call back function after web front-end fill order needs not be the function of the overall situation, and can retain the scene of this call back function.
As shown in Figure 10, sixth embodiment of the invention proposes a kind of method that browser communicates with web front-end, on the basis of the 5th embodiment shown in above-mentioned Fig. 9:
Before above-mentioned steps S204, also comprise:
Step S207, described web front-end judges whether the iframe label created for communicating; If so, then enter step 204, otherwise enter step S208;
Step S208, creates described iframe label, and enters step S208.
The difference of the 5th embodiment shown in the present embodiment and above-mentioned Fig. 9 is, the present embodiment also comprises the scheme whether creating iframe label.
Web front-end is by judging, not having if current to create the iframe label for communicating, then create this iframe label, having the iframe label created for communicating if current, then by the mode of the setting attribute assignment of the label be pre-created, global variable command queue is sent to browser.
The present embodiment is by upper scheme, by creating iframe label, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client, reduces the cost that developer learns to use API.
As shown in figure 11, first embodiment of the invention proposes a kind of web front-end, comprising: generation module 301, acquisition module 302, memory module 303 and sending module 304, wherein:
Generation module 301, for response interface call instruction, generates an id in order to identify request event corresponding to described interface interchange instruction;
Acquisition module 302, for according to described interface interchange instruction, obtains the interface parameters of described request event;
Memory module 303, for by described request event, id and described interface parameters stored in global variable command queue;
Sending module 304, for by the mode of the setting attribute assignment of the label be pre-created, is sent to browser by described global variable command queue; After receiving described global variable command queue by described browser, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
As shown in figure 12, second embodiment of the invention proposes a kind of web front-end, on the basis of the first embodiment shown in above-mentioned Figure 11, also comprises:
Operational module 305, for according to the result of described browser to described request event, carries out corresponding operating.
Further, described sending module 304, also for judging whether the iframe label created for communicating; If so, then passed through to the mode of the setting attribute assignment of the label be pre-created by described sending module, described global variable command queue is sent to browser; Otherwise create described iframe label.
The ultimate principle of the embodiment that above-mentioned Figure 11, Figure 12 are corresponding, please refer to the embodiment of the method that above-mentioned Fig. 8, Fig. 9 and Figure 10 are corresponding, does not repeat them here.
The method that embodiment of the present invention browser communicates with web front-end, web front-end and system, by the iframe label created, the bridge of a communication is set up between web front-end and browser client, by this bridge, web front-end can initiatively communicate with browser client, browser client also initiatively can communicate with web front-end and retain function scene, thus achieves the efficient communication between web front-end and browser client, reduces the cost that developer learns to use API.
Also it should be noted that, in this article, term " comprises ", " comprising " or its any other variant are intended to contain comprising of nonexcludability, thus make to comprise the process of a series of key element, method, article or device and not only comprise those key elements, but also comprise other key elements clearly do not listed, or also comprise by the intrinsic key element of this process, method, article or device.When not more restrictions, the key element limited by statement " comprising ... ", and be not precluded within process, method, article or the device comprising this key element and also there is other identical element.
The invention described above embodiment sequence number, just to describing, does not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art can be well understood to the mode that above-described embodiment method can add required general hardware platform by software and realize, hardware can certainly be passed through, but in a lot of situation, the former is better embodiment.Based on such understanding, technical scheme of the present invention can embody with the form of software product the part that prior art contributes in essence in other words, this computer software product is stored in a storage medium (as ROM/RAM, magnetic disc, CD), comprising some instructions in order to make a station terminal equipment (can be mobile phone, computing machine, server, or the network equipment etc.) perform method described in each embodiment of the present invention.
The foregoing is only the preferred embodiments of the present invention; not thereby the scope of the claims of the present invention is limited; every utilize instructions of the present invention and accompanying drawing content to do equivalent structure or flow process conversion; or be directly or indirectly used in other relevant technical field, be all in like manner included in scope of patent protection of the present invention.

Claims (19)

1. the method that communicates with web front-end of browser, is characterized in that, comprising:
Web front-end response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event;
Described web front-end, according to described interface interchange instruction, obtains the interface parameters of described request event;
Described web front-end by described request event, id and described interface parameters stored in global variable command queue;
Described global variable command queue is sent to browser by described web front-end;
After described browser receives described global variable command queue, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
2. method according to claim 1, is characterized in that, the step that described global variable command queue is sent to browser comprises by described web front-end:
Described global variable command queue, by the mode of the setting attribute assignment of the label be pre-created, is sent to browser by described web front-end;
Described label is iframe label, and described web front-end comprises to the step of the setting attribute assignment of the label be pre-created:
Described web front-end in a predetermined format, to the src attribute assignment of described iframe label, to trigger the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
3. method according to claim 1, is characterized in that, described interface parameters comprises: the type of request event and command parameter; After described browser receives described global variable command queue, from described global variable command queue, read described request event, id and interface parameters, the step that described request event processes comprised:
After described browser receives described global variable command queue, the queue of calling the overall situation obtains function, from described global variable command queue, read described request event, and the id of request event, type and command parameter;
Described browser processes described request event according to the id of described request event, type and command parameter;
When processing successfully, described browser calls the successful process function of the overall situation, imports the command parameter of result, described request event and id into described web front-end;
When processing unsuccessfully, described browser calls the failure handling function of the overall situation, imports the command parameter of result, described request event and id into described web front-end.
4. method according to claim 3, is characterized in that, the step that described browser receives described global variable command queue comprises:
Described browser catches src attribute format and the src property value of described iframe label;
According to src attribute format and the src property value of described iframe label, obtain described global variable command queue.
5. method according to claim 1, is characterized in that, also comprises after the step that described browser processes described request event:
Described web front-end, according to the result of described browser to described request event, carries out corresponding operating.
6. method according to claim 5, is characterized in that, described interface parameters also comprises: the successful call back function of described request event and failed call back function;
Described web front-end, according to described interface interchange instruction, also comprises after obtaining the step of the interface parameters of described request event:
Described web front-end using described id as key value, using described successful call back function and failed call back function as value value stored in a match objects;
Described web front-end is according to the result of described browser to described request event, and the step of carrying out corresponding operating comprises:
After described browser is to described request event handling success, described web front-end, according to described id, finds corresponding successful call back function, and performs from described match objects;
After described browser is to described request event handling failure, described web front-end, according to described id, finds corresponding failed call back function, and performs from described match objects.
7. the method according to any one of claim 2-6, is characterized in that, described web front-end passes through to the mode of the setting attribute assignment of the label be pre-created, and also comprises before described global variable command queue is sent to the step of browser:
Described web front-end judges whether the iframe label created for communicating; If so, then
Perform by the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to the step of browser; Otherwise create described iframe label.
8. browser communicate with web front-end a system, it is characterized in that, comprising: browser and the web front-end communicated to connect with described browser; Wherein:
Described web front-end, for response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event; According to described interface interchange instruction, obtain the interface parameters of described request event; By described request event, id and described interface parameters stored in global variable command queue; Described global variable command queue is sent to browser;
Described browser, after receiving described global variable command queue, reads described request event, id and described interface parameters, processes described request event from described global variable command queue.
9. system according to claim 8, is characterized in that,
Described web front-end, also for passing through to the mode of the setting attribute assignment of the iframe label be pre-created, described global variable command queue is sent to browser, wherein, during setting attribute assignment to the label be pre-created, specifically in a predetermined format, to the src attribute assignment of described iframe label, to trigger the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
10. system according to claim 8, is characterized in that, described interface parameters comprises: the type of request event and command parameter;
Described browser, also for after receiving described global variable command queue, the queue of calling the overall situation obtains function, from described global variable command queue, read described request event, and the id of request event, type and command parameter; According to the id of described request event, type and command parameter, described request event is processed; When processing successfully, calling the successful process function of the overall situation, importing the command parameter of result, described request event and id into described web front-end; When processing unsuccessfully, calling the failure handling function of the overall situation, importing the command parameter of result, described request event and id into described web front-end.
11. systems according to claim 10, is characterized in that,
Described browser, also for catching src attribute format and the src property value of described iframe label; According to src attribute format and the src property value of described iframe label, obtain described global variable command queue.
12. systems according to claim 8, is characterized in that,
Described web front-end, also for according to the result of described browser to described request event, carries out corresponding operating.
13. systems according to claim 12, is characterized in that, described interface parameters also comprises: the successful call back function of described request event and failed call back function;
Described web front-end, also for using described id as key value, using described successful call back function and failed call back function as value value stored in a match objects; After described browser is to described request event handling success, according to described id, from described match objects, find corresponding successful call back function, and perform; After described browser is to described request event handling failure, according to described id, from described match objects, find corresponding failed call back function, and perform.
14. systems according to Claim 8 according to any one of-13, is characterized in that,
Described web front-end, also for judging whether the iframe label created for communicating; If so, then by the mode of the setting attribute assignment of the label be pre-created, described global variable command queue is sent to browser; Otherwise create described iframe label.
15. 1 kinds of web front-ends, is characterized in that, comprising:
Generation module, for response interface call instruction, generates the id identifying described interface interchange instruction corresponding requests event;
Acquisition module, for according to described interface interchange instruction, obtains the interface parameters of described request event;
Memory module, for by described request event, id and described interface parameters stored in global variable command queue;
Sending module, for being sent to browser by described global variable command queue; After receiving described global variable command queue by described browser, from described global variable command queue, read described request event, id and described interface parameters, described request event is processed.
16. web front-ends according to claim 15, is characterized in that,
Described sending module, also for passing through to the mode of the setting attribute assignment of the iframe label be pre-created, described global variable command queue is sent to browser, specifically in a predetermined format, to the src attribute assignment of described iframe label, to trigger the transmission of global variable command queue; Described src attribute comprises service field and the action field of the type for identifying described request event.
17. web front-ends according to claim 15, is characterized in that, also comprise:
Operational module, for according to the result of described browser to described request event, carries out corresponding operating.
18. web front-ends according to claim 17, is characterized in that,
Described memory module, also for using described id as key value, using the successful call back function in described interface parameters and failed call back function as value value stored in a match objects;
Described operational module, also for after described browser is to described request event handling success, according to described id, finds corresponding successful call back function, and performs from described match objects; After described browser is to described request event handling failure, according to described id, from described match objects, find corresponding failed call back function, and perform.
19. web front-ends according to any one of claim 15-18, is characterized in that,
Described sending module, also for judging whether the iframe label created for communicating; If so, then passed through to the mode of the setting attribute assignment of the label be pre-created by described sending module, described global variable command queue is sent to browser; Otherwise create described iframe label.
CN201410549577.8A 2014-10-16 2014-10-16 Method, web front-end and the system that browser is communicated with web front-end Active CN105573733B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410549577.8A CN105573733B (en) 2014-10-16 2014-10-16 Method, web front-end and the system that browser is communicated with web front-end

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410549577.8A CN105573733B (en) 2014-10-16 2014-10-16 Method, web front-end and the system that browser is communicated with web front-end

Publications (2)

Publication Number Publication Date
CN105573733A true CN105573733A (en) 2016-05-11
CN105573733B CN105573733B (en) 2019-01-22

Family

ID=55883911

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410549577.8A Active CN105573733B (en) 2014-10-16 2014-10-16 Method, web front-end and the system that browser is communicated with web front-end

Country Status (1)

Country Link
CN (1) CN105573733B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106649470A (en) * 2016-09-28 2017-05-10 郑州云海信息技术有限公司 Table search state storage method
CN107818020A (en) * 2016-09-12 2018-03-20 平安科技(深圳)有限公司 Parameter transfer method and device
CN108255594A (en) * 2017-12-22 2018-07-06 东软集团股份有限公司 For the event-handling method of business process designer, device, medium and electronic equipment
CN109426572A (en) * 2017-08-29 2019-03-05 杭州海康威视数字技术股份有限公司 Task processing method, device and electronic equipment
CN109669739A (en) * 2017-10-16 2019-04-23 阿里巴巴集团控股有限公司 A kind of interface rendering method, device, terminal device and storage medium
CN111352741A (en) * 2018-12-21 2020-06-30 马上消费金融股份有限公司 Interface calling method and device, intelligent terminal and storage device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030018714A1 (en) * 2001-07-20 2003-01-23 Dmytro Mikhailov Proactive browser system
CN102541641A (en) * 2011-12-28 2012-07-04 奇智软件(北京)有限公司 Method and device for browser message processing
CN103226474A (en) * 2013-05-10 2013-07-31 北京奇虎科技有限公司 Method, device and system for interaction between webpage script and browser program
WO2013188317A1 (en) * 2012-06-10 2013-12-19 Kevin Mcgushion Active web page consolidator

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030018714A1 (en) * 2001-07-20 2003-01-23 Dmytro Mikhailov Proactive browser system
CN102541641A (en) * 2011-12-28 2012-07-04 奇智软件(北京)有限公司 Method and device for browser message processing
WO2013188317A1 (en) * 2012-06-10 2013-12-19 Kevin Mcgushion Active web page consolidator
CN103226474A (en) * 2013-05-10 2013-07-31 北京奇虎科技有限公司 Method, device and system for interaction between webpage script and browser program

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107818020A (en) * 2016-09-12 2018-03-20 平安科技(深圳)有限公司 Parameter transfer method and device
CN107818020B (en) * 2016-09-12 2021-04-27 平安科技(深圳)有限公司 Parameter transmission method and device
CN106649470A (en) * 2016-09-28 2017-05-10 郑州云海信息技术有限公司 Table search state storage method
CN109426572A (en) * 2017-08-29 2019-03-05 杭州海康威视数字技术股份有限公司 Task processing method, device and electronic equipment
CN109426572B (en) * 2017-08-29 2021-07-02 杭州海康威视数字技术股份有限公司 Task processing method and device and electronic equipment
CN109669739A (en) * 2017-10-16 2019-04-23 阿里巴巴集团控股有限公司 A kind of interface rendering method, device, terminal device and storage medium
CN108255594B (en) * 2017-12-22 2021-03-02 东软集团股份有限公司 Event processing method, device and medium for flow designer and electronic equipment
CN108255594A (en) * 2017-12-22 2018-07-06 东软集团股份有限公司 For the event-handling method of business process designer, device, medium and electronic equipment
CN111352741A (en) * 2018-12-21 2020-06-30 马上消费金融股份有限公司 Interface calling method and device, intelligent terminal and storage device
CN111352741B (en) * 2018-12-21 2021-04-06 马上消费金融股份有限公司 Interface calling method and device, intelligent terminal and storage device

Also Published As

Publication number Publication date
CN105573733B (en) 2019-01-22

Similar Documents

Publication Publication Date Title
CN105573733A (en) Communication method for browser and web front end and web front end and system
US20150033342A1 (en) Security detection method and system
CN106022483B (en) The method and apparatus converted between machine learning model
US9208235B1 (en) Systems and methods for profiling web applications
CN103777967B (en) Page returning method, page generation method and device
CN107102941B (en) Test case generation method and device
US10915637B2 (en) Method, client, and system for testing application
CN105718313A (en) Application operation method and device
CN103530160A (en) Page loading method and device
US10291492B2 (en) Systems and methods for discovering sources of online content
US20190251019A1 (en) Testing web applications using clusters
US9912522B2 (en) Automatic task tracking
US10516690B2 (en) Physical device detection for a mobile application
US20160335174A1 (en) Generalized snapshots based on multiple partial snapshots
CN104834588B (en) The method and apparatus for detecting resident formula cross site scripting loophole
CN108833500B (en) Service calling method, service providing method, data transmission method and server
CN106484775A (en) A kind of crawler capturing method and system based on selenium
CN105515887A (en) Application test method, server and system
CN111552633A (en) Interface abnormal call testing method and device, computer equipment and storage medium
CN105979316A (en) Input method and device
US10701087B2 (en) Analysis apparatus, analysis method, and analysis program
CN107463434B (en) Distributed task processing method and device
KR101553539B1 (en) Dynamic link providing method and computer readable storage medium for program therefor
CN108108369B (en) Method and device for processing calling error of common interface library
CN108153745B (en) Application data calling method and application development system

Legal Events

Date Code Title Description
C06 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