CN105573733B - Method, web front-end and the system that browser is communicated with web front-end - Google Patents
Method, web front-end and the system that browser is communicated with web front-end Download PDFInfo
- Publication number
- CN105573733B CN105573733B CN201410549577.8A CN201410549577A CN105573733B CN 105573733 B CN105573733 B CN 105573733B CN 201410549577 A CN201410549577 A CN 201410549577A CN 105573733 B CN105573733 B CN 105573733B
- Authority
- CN
- China
- Prior art keywords
- browser
- web front
- 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.)
- Active
Links
Landscapes
- Information Transfer Between Computers (AREA)
- Stored Programmes (AREA)
Abstract
Method, web front-end and the system communicated the present invention relates to a kind of browser with web front-end, method include: web front-end response interface call instruction, generate the id to identify interface call instruction corresponding requests event;According to interface call instruction, the interface parameters of acquisition request event;Request event, id and interface parameters are stored in global variable command queue;Global variable command queue is sent to browser;After browser receives global variable command queue, read requests event, id and interface parameters, handle request event from global variable command queue.The invention enables web front-ends actively to communicate with browser client, browser client actively can also communicate with web front-end and retain function scene, the efficient communication between web front-end and browser client is realized, the cost that developer's study uses API is reduced.
Description
Technical field
A kind of communicated the present invention relates to image processing technology more particularly to browser with web front-end method, web
Front end and system.
Background technique
Currently, the browser run on ios system is all based on safari kernel, web front-end can not be used directly
The API that browser client provides, i.e. web front-end lack the mechanism with browser client active communication.
For browser client, the global javascript code of accessible web front-end, browser client access
The javascript code of web front-end generallys use following two mode: it is corresponding to execute the incoming overall situation function name of web front-end
Function, or execute the incoming function body of web front-end.
But above two mode all has serious drawback: first way requires incoming function name to need corresponding one
A overall situation function, this mode just disaster for asynchronous interface a, because API is called to be intended to generation one
A global variable can not only pollute NameSpace in this way, also can committed memory;The second way can make in incoming function body
Scope chain fails, and can only access global variable in function body, this corresponding is window object, and function body will be unable at this time
Retain scene, the presence of these underlying rules will be developed to web front-end brings bigger complexity.
Summary of the invention
The embodiment of the present invention provides a kind of method, web front-end and system that browser is communicated with web front-end, it is intended to realize
Efficient communication 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 is communicated with web front-end, comprising:
Web front-end response interface call instruction generates the id to identify the interface call instruction corresponding requests event;
The web front-end obtains the interface parameters of the request event according to the interface call instruction;
The request event, id and the interface parameters are stored in global variable command queue by the web front-end;
The web front-end is ordered the global variable by way of the setting attribute assignment to the label being pre-created
Queue is enabled to be sent to browser;
After the browser receives the global variable command queue, institute is read from the global variable command queue
Request event, id and the interface parameters are stated, the request event is handled.
The embodiment of the present invention also proposes a kind of system that browser is communicated with web front-end, comprising: browser and with it is described
The web front-end of browser communication connection;Wherein:
The web front-end is used for response interface call instruction, generates to identify the interface call instruction corresponding requests
The id of event;According to the interface call instruction, the interface parameters of the request event is obtained;By the request event, id with
And in interface parameters deposit global variable command queue;Pass through the side of the setting attribute assignment to the label being pre-created
The global variable command queue is sent to browser by formula;
The browser, after receiving the global variable command queue, from the global variable command queue
The request event, id and the interface parameters are read, the request event is handled.
The embodiment of the present invention also proposes a kind of web front-end, comprising:
Generation module is used for response interface call instruction, generates to identify the corresponding request of the interface call instruction
The id of event;
Module is obtained, for obtaining the interface parameters of the request event according to the interface call instruction;
Memory module, for the request event, id and the interface parameters to be stored in global variable command queue;
Sending module, for the global variable command queue to be sent to browser;Institute is received by the browser
After stating global variable command queue, the request event, id and the interface are read from the global variable command queue
Parameter handles the request event.
Method, web front-end and the system that a kind of browser that the embodiment of the present invention proposes is communicated with web front-end, pass through wound
The iframe label built establishes the bridge of a communication between web front-end and browser client, by the bridge, before web
Holding actively to communicate with browser client, and browser client can also active be with web front-end communication and reservation function shows
, it is thus achieved that the efficient communication between web front-end and browser client, reduce developer study using API at
This.
Detailed description of the invention
Fig. 1 be the present embodiments relate to the system architecture schematic diagram that is communicated with web front-end of browser;
Fig. 2 is the interaction time diagram of browser client of the embodiment of the present invention and web front-end;
Fig. 3 is the web front-end hardware running environment schematic diagram that the embodiment of the present invention is related to;
Fig. 4 is the flow diagram for the method first embodiment that browser of the present invention is communicated with web front-end;
Fig. 5 is after browser receives the global variable command queue in the embodiment of the present invention, from the global variable
The request event and interface parameters are read in command queue, the flow diagram handled the request event;
Fig. 6 is the flow diagram for the method second embodiment that browser of the present invention is communicated with web front-end;
Fig. 7 is the flow diagram for the method 3rd embodiment that browser of the present invention is communicated with web front-end;
Fig. 8 is the flow diagram for the method fourth embodiment that browser of the present invention is communicated with web front-end;
Fig. 9 is the flow diagram for the 5th embodiment of method that browser of the present invention is communicated with web front-end;
Figure 10 is the flow diagram for the method sixth embodiment that browser of the present invention is communicated with web front-end;
Figure 11 is the functional block diagram of web front-end first embodiment of the present invention;
Figure 12 is the functional block diagram of web front-end second embodiment of the present invention.
In order to keep technical solution of the present invention clearer, clear, it is described in further detail below in conjunction with attached drawing.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The primary solutions of the embodiment of the present invention are: by the iframe label of creation, in web front-end and browser visitor
The bridge that a communication is established between the end of family, by the bridge, web front-end can be communicated actively with browser client, browsing
Device client actively can also communicate with web front-end and retain function scene, it is thus achieved that web front-end and browser client
Between efficient communication, reduce developer study use API cost.
The system architecture that the browser being related to as shown in FIG. 1, FIG. 1 is the embodiment of the present invention is communicated with web front-end, should
System architecture includes: browser client 102 and the web front-end 101 with the browser client 102 communication connection;Wherein:
The web front-end 101 is used for response interface call instruction, generates an id to identify the interface call instruction
Corresponding request event;According to the interface call instruction, the interface parameters of the request event is obtained;By the request thing
In part, id and interface parameters deposit global variable command queue;It is assigned by the setting attribute to the label being pre-created
The global variable command queue is sent to browser by the mode of value;
The browser, after receiving the global variable command queue, from the global variable command queue
The request event, id and the interface parameters are read, the request event is handled.
Specifically, the present embodiment browser client 102 can be pc client, or mobile phone, tablet computer etc.
Mobile terminal with web page browsing function.
By taking the mobile phone terminal of ios system as an example, since the currently running browser on ios system is all based on
Safari kernel, the API that web front-end 101 can not be provided directly using browser client 102, i.e. web front-end 101 lack with
The mechanism of 102 active communication of browser client.And for browser client 102, although accessible web front-end 101
Global javascript code, but function scene can not be retained, bigger complexity is brought to the exploitation of web front-end 101.
This embodiment scheme can establish the bridge of a communication between web front-end 101 and browser client 102,
By the bridge, web front-end 101 can be communicated actively with browser client 102, and browser client 102 can also be actively
Function scene is communicated and retained with web front-end 101, realizes the efficient communication between web front-end 101 and browser client 102,
Reduce the cost that developer's study uses API.The interaction flow of the present embodiment browser client 102 and web front-end 101 is as schemed
Shown in 2.
Specifically, there is a label in the creation of web front-end 101, the present embodiment is carried out with a hiding iframe label
Citing.Web front-end 101 can trigger an event when giving the src attribute assignment of this iframe label, and browser clients
End 102 can capture this event in time, and at the same time, browser can also intercept and capture the src information of iframe label.
Therefore, it is based on this principle, can establish 101 He of web front-end by way of creating a hiding iframe
The bridge communicated between browser client 102.Due to can all be touched when web front-end 101 creates iframe label and assignment every time
An event is sent out, so being common one order of behavior or transmitting to distinguish creation iframe label, the present embodiment is fixed
The justice special format of src, and the format of the src is negotiated to generate by web front-end 101 and browser client 102, so as to clear
Device client 102 of looking at can capture src attribute value in time.
The present embodiment defines src using following format: mtt:service:action.
Wherein, mtt is character string constant, and service and action uniquely determine the behavior of an order, service mark
Know the behavior of major class, action identifies the subdivision behavior under major class.
By this communication mode, the API that browser client 102 externally provides is asynchronous interface, and development of user can
To be passed to the type of service and action marking command, and using option as command parameter, suc, which is used as, successfully to be adjusted back
Function, call back function of the err as failure, defines the format of an api interface as a result, are as follows:
BrowserApi (service, action, option, suc, err).
The code library that development of user can call web front-end 101 to provide triggers the calling to client end AP PCI interface.Its
In, the code library of web front-end 101 is specifically as follows javascript code library.
Web front-end 101 responds the interface call instruction of development of user triggering, can generate one and be sent to browser client
Thus 102 request event initiates an order.
Before web front-end 101 initiates an order to browser client 102, a unique random number can be automatically generated
The order is identified as id, that is, generate an id to identify the corresponding request event of the interface call instruction.
In addition, web front-end 101 can also obtain the interface parameters of the request event according to the interface call instruction.It should
Interface parameters includes: the type of request event and the command parameter of request event;Wherein, the type of request event passes through 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 convenient for browser clients for sending browser client 102 to
102 pairs of request events are held to handle.
In web front-end 101, it can also safeguard that a command queue queue (the present embodiment claims global variable command queue) comes
Save these request events (containing the corresponding id of request event, the type of request event and the command parameter of request event).
Web front-end 101 is to examine why by global variable command queue preservation request event, id and interface parameters
Browser client 102API interface may repeatedly be called whithin a period of time by considering development of user, and browser client
102 can not necessarily handle these request events in time.Therefore, these lives of request event are saved using global variable command queue
It enables, is sent to browser client 102 in batches, thereby may be ensured that the place of 102 reasonable arrangement request event of browser client
Reason opportunity improves the efficiency of browser side system performance and data processing, while also alleviating at the data of web front-end 101
Manage pressure.
Then, web front-end 101 in a predetermined format, to the src attribute assignment of iframe label, triggers global variable order
The transmission of queue;The src attribute includes the service field and action word for identifying the type of the request event
Section.
As a result, by way of the src assignment to hiding iframe created, request event and its related ginseng will be included
Several global variable command queues are passed to browser client 102.
Web front-end 101 is by way of the src assignment to hiding iframe created, by global variable command queue
When being passed to browser client 102, an event can be triggered, as previously mentioned, browser can capture this event in time.
In browser side, browser client 102 can capture the src attribute format and src attribute value of iframe label, and
Judge src attribute format and src attribute value judge whether src attribute format is the format arranged, and src attribute value is
No generation variation.
Then, according to the src attribute format and src attribute value of the iframe label, global variable command queue is obtained.
Browser client 102 calls global queue to obtain function after receiving the global variable command queue
(getQueue), id, type and the life of the request event and request event are read from the global variable command queue
Enable parameter.
Then, respective handling is carried out to the request event according to the id of the request event, type and command parameter.
After an order is completed in the processing of browser client 102, if handling successfully, browser calls a global success
It handles function (sucCallback), processing result, the command parameter of the request event and id is passed to the web front-end
101。
After processing failure, the browser calls global failure handling function (errCallback), and processing is tied
Fruit, the command parameter of the request event and id are passed to the web front-end 101.
Pass through above three overall situation function getQueue, sucCallback and errCallback (global queue as a result,
Obtain function, the global failure handling function for being successfully processed function and the overall situation), the call back function of external API can be made to protect
Scene is stayed, because whole system need to only safeguard three overall situation functions getQueue, sucCallback and errCallback, then
Continuous web front-end 101 executes the success after order and failure call back function needs not be global function, and can retain the readjustment letter
Several scenes.
The present embodiment through the above scheme, by the iframe label of creation, in web front-end 101 and browser client
The bridge that a communication is established between 102, by the bridge, web front-end 101 can be communicated actively with browser client 102,
Browser client 102 actively can also communicate with web front-end 101 and retain function scene, it is thus achieved that web front-end 101
With the efficient communication between browser client 102.
In addition, in specific implementation, encapsulating above-mentioned web front-end by providing a basic java script module
The queue maintenance mechanism of communication mode and command calls between 101 and browser client 102 externally provides a customization
API.Only API need to can be used by introducing the component of this lightweight in development of user, and does not have to concerned with internal and realize, and do not have
Any underlying rule, to reduce the cost that development of user study uses API.
Further, the web front-end 101 is also used to the processing result according to the browser to the request event,
Carry out corresponding operating.
Specifically, in the present embodiment, web front-end 101 is according to interface call instruction, the interface parameters of acquisition request event
In further include: the successful call back function and failure call back function of request event.
Wherein, the id for the request event that web front-end 101 can will acquire is as key value, by the successful readjustment of request event
Function and failure call back function are as in one matching object of value value deposit.
Later, web front-end 101 when carrying out corresponding operating, is specifically used according to browser to the processing result of request event
Following scheme:
After browser handles successfully request event, web front-end 101 is according to the id of request event, from the matching pair
Corresponding success call back function is found as in, and is executed;It is described after the browser is to the request event processing failure
Web front-end 101 finds corresponding failure call back function, and execute according to the id of request event from the matching object.
The processing of browser client 102 request detailed below and web front-end 101 obtain browser client 102
The detailed process of corresponding operating is carried out after response:
Browser client 102 calls global queue to obtain function after receiving global variable command queue
(getQueue), the id of read requests event and request event, type and command parameter from global variable command queue.
Then, respective handling is carried out to request event according to the id of request event, type and command parameter.
After an order is completed in the processing of browser client 102, if handling successfully, browser calls a global success
It handles function (sucCallback), processing result, the command parameter of request event and id is passed to web front-end 101.Web front-end
101 find corresponding success call back function according to the id received from matching object, and execute.
After browser processing request event failure, browser calls global failure handling function (errCallback),
Processing result, the command parameter of the request event and id are passed to the web front-end 101.Web front-end 101 is according to receiving
Id corresponding failure call back function is found from matching object, and execute.
By this method, whole system need to only safeguard three overall situation functions getQueue, sucCallback and
ErrCallback, and web front-end 101 executes the success after order and failure call back function needs not be global function, and meeting
Retain the scene of the call back function.
Further, the web front-end 101 is also used to judge whether that creation has the iframe label for communication;If
It is then by way of the setting attribute assignment to the label being pre-created, the global variable command queue to be sent to clear
Look at device;Otherwise the iframe label is created.
Web front-end 101 is by judgement, if the iframe label currently without creation for communication, creates the iframe
Label passes through the setting attribute assignment to the label being pre-created if currently there is iframe label of the creation for communication
Global variable command queue is sent to browser by mode.
The present embodiment is by upper scheme, by creating iframe label, web front-end 101 and browser client 102 it
Between establish the bridge of a communication, by the bridge, web front-end 101 can be communicated actively with browser client 102, browsing
Device client 102 can also actively and web front-end 101 communication and retain function scene, it is thus achieved that web front-end 101 with it is clear
The efficient communication look between device client 102 reduces the cost that developer's study uses API.
As shown in figure 3, Fig. 3 is the web front-end hardware running environment schematic diagram that the embodiment of the present invention is related to, the web
Front end can be PC, can also be with other servers.
As shown in figure 3, the web front-end may include: processor 1001, such as CPU, network interface 1004, user interface
1003, memory 1005, communication bus 1002.Wherein, communication bus 1002 is for realizing the connection communication between these components.
User interface 1003 may include display screen (Display), keyboard (Keyboard), and optional user interface 1003 can also include
Standard wireline interface and wireless interface.Network interface 1004 optionally may include standard wireline interface and wireless interface (such as
WI-FI interface).Memory 1005 can be high speed RAM memory, be also possible to stable memory (non-volatile
), such as magnetic disk storage memory.Memory 1005 optionally can also be the storage dress independently of aforementioned processor 1001
It sets.As shown in figure 3, as may include operating system, network communication mould in a kind of memory 1005 of computer storage medium
Block, Subscriber Interface Module SIM and communication application program.
In web front-end shown in Fig. 3, network interface 1004 is mainly used for connecting browser client, with browser visitor
Family end carries out data communication;User interface 1003 is mainly used for carrying out data communication with development of user end;And processor 1001 can
For calling the communication application program stored in memory 1005, and the following operation of execution:
Response interface call instruction generates an id to identify the corresponding request event of the interface call instruction;
According to the interface call instruction, the interface parameters of the request event is obtained;
The request event, id and the interface parameters are stored in global variable command queue;
By way of the setting attribute assignment to the label being pre-created, the global variable command queue is sent to
Browser;After receiving the global variable command queue by the browser, read from the global variable command queue
The request event, id and the interface parameters, handle the request event.
Further, in one embodiment, processor 1001 calls the communication application program stored in memory 1005
Following operation can be executed:
In a predetermined format, to the src attribute assignment of the iframe label, to trigger the hair of global variable command queue
It send;The src attribute includes the service field and action field for identifying the type of the request event.
Further, in one embodiment, processor 1001 calls the communication application program stored in memory 1005
Following operation can be executed:
According to the browser to the processing result of the request event, corresponding operating is carried out.
Further, in one embodiment, processor 1001 calls the communication application program stored in memory 1005
Following operation can be executed:
According to the interface call instruction, after the interface parameters for obtaining the request event further include:
Using the id as key value, using in the interface parameters successful call back function and failure call back function as
In one matching object of value value deposit;
After the browser handles successfully the request event, according to the id, found from the matching object
Corresponding success call back function, and execute;
After the browser is to the request event processing failure, according to the id, found from the matching object
Corresponding failure call back function, and execute.
Further, in one embodiment, processor 1001 calls the communication application program stored in memory 1005
Following operation can be executed:
Judge whether that creation has the iframe label for communication;If so, passing through the setting to the label being pre-created
The global variable command queue is sent to browser by the mode of attribute assignment;Otherwise the iframe label is created.
The present embodiment through the above scheme, by creating iframe label, is built between web front-end and browser client
The bridge of a vertical communication, by the bridge, web front-end can be communicated actively with browser client, browser client
Actively it can communicate with web front-end and retain function scene, it is thus achieved that effective between web front-end and browser client
Communication reduces the cost that developer's study uses API.
Based on above system framework and hardware structure, the embodiment of the method that browser of the present invention is communicated with web front-end is proposed.
As shown in figure 4, first embodiment of the invention proposes a kind of method that browser is communicated with web front-end, and in particular to
The method that browser client is communicated with web front-end, this method comprises:
Step S101, web front-end response interface call instruction are generated to identify the interface call instruction corresponding requests
The id of event;
The present embodiment browser client can be pc client, or mobile phone, tablet computer etc. have webpage clear
Look at the mobile terminal of function.
By taking the mobile phone terminal of ios system as an example, since the currently running browser on ios system is all based on
Safari kernel, the API that web front-end can not be provided directly using browser client, i.e. web front-end lack and browser clients
Hold the mechanism of active communication.And for browser client, although the global javascript code of accessible web front-end,
But function scene can not be retained, bigger complexity is brought to web front-end exploitation.
This embodiment scheme can establish the bridge of a communication between web front-end and browser client, by this
Bridge, web front-end can actively and browser client communication, browser client can also actively and web front-end communication and
Retain function scene, realize the efficient communication between web front-end and browser client, reduces developer's study and use API's
Cost.
Specifically, there is a label in web front-end creation, the present embodiment is lifted with a hiding iframe label
Example.Web front-end can trigger an event when giving the src attribute assignment of this iframe label, and browser client meeting and
When capture this event, at the same time, browser can also intercept and capture the src information of iframe label.
Therefore, it is based on this principle, can establish web front-end and browsing by way of creating a hiding iframe
The bridge communicated between device client.An event can be all triggered when creating iframe label and assignment every time due to web front-end,
So being common one order of behavior or transmitting to distinguish creation iframe label, the present embodiment defines the spy of src
Different format, and the format of the src is negotiated to generate by web front-end and browser client, so as to browser client can and
When capture src attribute value.
The present embodiment defines src using following format: mtt:service:action.
Wherein, mtt is character string constant, and service and action uniquely determine the behavior of an order, service mark
Know the behavior of major class, action identifies the subdivision behavior under major class.
By this communication mode, the API that browser client externally provides is asynchronous interface, and development of user can pass
Enter the type of service and action marking command, and using option as command parameter, suc is used as successfully call back function,
Call back function of the err as failure, defines the format of an api interface as a result, are as follows:
BrowserApi (service, action, option, suc, err).
The code library that development of user can call web front-end to provide triggers the calling to client end AP PCI interface.Wherein,
The code library of web front-end is specifically as follows javascript code library.
Web front-end responds the interface call instruction of development of user triggering, can generate one and be sent to browser client
Thus request event initiates an order.
Before web front-end initiates an order to browser client, a unique random number can be automatically generated as id
To identify the order, that is, generate an id to identify the corresponding request event of the interface call instruction.
Step S102, the web front-end obtain the interface parameters of the request event according to the interface call instruction;
In addition, web front-end can also obtain the interface parameters of the request event according to the interface call instruction.This connects
Mouth parameter includes: the type of request event and the command parameter of request event;Wherein, the type of request event passes through 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 convenient for browser client pair for sending browser client to
Request event is handled.
The request event, id and the interface parameters are stored in global variable order by step S103, the web front-end
In queue;
In web front-end, command queue queue (the present embodiment claims global variable command queue) can be also safeguarded to save
These request events (containing the corresponding id of request event, the type of request event and the command parameter of request event).
Why web front-end, which passes through global variable command queue, saves request event, id and interface parameters, allows for
Development of user may repeatedly call browser client api interface whithin a period of time, and browser client is different surely
It is enough to handle these request events in time.Therefore, these orders of request event are saved using global variable command queue, sent in batches
To browser client, it thereby may be ensured that the processing opportunity of browser client reasonable arrangement request event, improve browsing
The efficiency of device side system performance and data processing, while also alleviating the data processing pressure of web front-end.
The global variable command queue is sent to browser by step S104, the web front-end;
Then, web front-end in a predetermined format, to the src attribute assignment of iframe label, triggers global variable command queue
Transmission;The src attribute includes the service field and action field for identifying the type of the request event.
As a result, by way of the src assignment to hiding iframe created, request event and its related ginseng will be included
Several global variable command queues are passed to browser client.
Step S105, after the browser receives the global variable command queue, from global variable order team
The request event, id and the interface parameters are read in column, and the request event is handled.
Web front-end is conveyed global variable command queue by way of the src assignment to hiding iframe created
When to browser client, an event can be triggered, as previously mentioned, browser can capture this event in time.
In browser side, browser client can capture the src attribute format and src attribute value of iframe label, and right
Src attribute format and src attribute value are judged judge whether src attribute format is the format arranged, and whether is src attribute value
Generate variation.
Then, according to the src attribute format and src attribute value of the iframe label, global variable command queue is obtained.
Browser client calls global queue to obtain function after receiving the global variable command queue
(getQueue), id, type and the life of the request event and request event are read from the global variable command queue
Enable parameter.
Then, respective handling is carried out to the request event according to the id of the request event, type and command parameter.
After an order is completed in browser client processing, if handling successfully, browser calls a global successful place
It manages function (sucCallback), processing result, the command parameter of the request event and id is passed to the web front-end.
After processing failure, the browser calls global failure handling function (errCallback), and processing is tied
Fruit, the command parameter of the request event and id are passed to the web front-end.
Pass through above three overall situation function getQueue, sucCallback and errCallback (global queue as a result,
Obtain function, the global failure handling function for being successfully processed function and the overall situation), the call back function of external API can be made to protect
Scene is stayed, because whole system need to only safeguard three overall situation functions getQueue, sucCallback and errCallback, then
Continuous web front-end executes the success after order and failure call back function needs not be global function, and can retain the call back function
Scene.
More specifically, as shown in figure 5, above-mentioned steps S105: after browser receives the global variable command queue,
The request event and interface parameters are read from the global variable command queue, the request event is handled
May include:
Step S1051 after browser receives the global variable command queue, calls global queue to obtain function,
Id, type and the command parameter of the request event and request event are read from the global variable command queue;
Step S1052, the browser is according to the id of the request event, type and command parameter to the request event
It is handled;
Step S1053, after handling successfully, the browser calling overall situation is successfully processed function, by processing result, institute
The command parameter and id for stating request event are passed to the web front-end;
Step S1054, after processing failure, the browser calls global failure handling function, by processing result, institute
The command parameter and id for stating request event are passed to the web front-end.
The present embodiment through the above scheme, through the iframe label of creation, between web front-end and browser client
The bridge for establishing a communication, by the bridge, web front-end can be communicated actively with browser client, browser client
Actively it can also communicate with web front-end and retain function scene, it is thus achieved that having between web front-end and browser client
Effect communication.
In addition, in specific implementation, encapsulating above-mentioned web front-end by providing a basic java script module
The queue maintenance mechanism of communication mode and command calls between browser client externally provides the API of a customization.Exploitation
Only API need to can be used by introducing the component of this lightweight in user, and does not have to concerned with internal and realize, and without any latent rule
Then, to reduce the cost that development of user study uses API.
As shown in fig. 6, second embodiment of the invention proposes a kind of method that browser is communicated with web front-end, in above-mentioned Fig. 4
Shown on the basis of first embodiment:
In above-mentioned steps S102, web front-end obtains the interface parameters of the request event according to the interface call instruction
Later, further includes:
Step S106, the web front-end by the success call back function and unsuccessfully adjust back letter using the id as key value
Number is as in one matching object of value value deposit.
After above-mentioned steps S105 further include:
Step S107, web front-end, to the processing result of the request event, carry out corresponding operating according to the browser.
The present embodiment and the difference of above-mentioned first embodiment shown in Fig. 4 are that the present embodiment further includes web front-end to clear
The scheme of device client process result of looking at progress corresponding operating.
Specifically, in the present embodiment, web front-end is according to interface call instruction, in the interface parameters of acquisition request event
Further include: the successful call back function and failure call back function of request event.
Wherein, the id for the request event that web front-end can will acquire is as key value, by the successful readjustment letter of request event
Number and failure call back function are as in one matching object of value value deposit.
Later, web front-end according to browser to the processing result of request event, when carrying out corresponding operating, specifically use with
Lower scheme:
After browser handles successfully request event, web front-end is according to the id of request event, from the matching object
Corresponding success call back function is found, and is executed;After the browser is to the request event processing failure, before the web
End corresponding failure call back function is found, and execute from the matching object according to the id of request event.
It is laggard that browser client processing request detailed below and web front-end obtain browser client response
The detailed process of row corresponding operating:
Browser client calls global queue to obtain function after receiving global variable command queue
(getQueue), the id of read requests event and request event, type and command parameter from global variable command queue.
Then, respective handling is carried out to request event according to the id of request event, type and command parameter.
After an order is completed in browser client processing, if handling successfully, browser calls a global successful place
It manages function (sucCallback), processing result, the command parameter of request event and id is passed to web front-end.Web front-end according to
The id received finds corresponding success call back function from matching object, and executes.
After browser processing request event failure, browser calls global failure handling function (errCallback),
Processing result, the command parameter of the request event and id are passed to the web front-end.Web front-end according to the id received from
Corresponding failure call back function is found in matching object, and is executed.
By this method, whole system need to only safeguard three overall situation functions getQueue, sucCallback and
ErrCallback, and web front-end executes the success after order and failure call back function needs not be global function, and can protect
Stay the scene of the call back function.
As shown in fig. 7, third embodiment of the invention proposes a kind of method that browser is communicated with web front-end, in above-mentioned Fig. 6
Shown on the basis of second embodiment, pass through in the front end above-mentioned steps S104:web to the setting attribute for the label being pre-created
The global variable command queue is sent to before browser by the mode of assignment further include:
Step S108, web front-end judge whether that creation has the iframe label for communication;If so, entering step
S104;Otherwise, S109 is entered step;
Step S109 creates the iframe label, and enters step S104.
The present embodiment and the difference of above-mentioned second embodiment shown in fig. 6 are the present embodiment further includes whether creating
The scheme of iframe label.
Web front-end is by judgement, if the iframe label currently without creation for communication, creates iframe mark
Label pass through the side of the setting attribute assignment to the label being pre-created if currently there is iframe label of the creation for communication
Global variable command queue is sent to browser by formula.
The present embodiment is established between web front-end and browser client by upper scheme by creating iframe label
The bridge of one communication, by the bridge, web front-end can be communicated actively with browser client, and browser client can also
Actively to be communicated with web front-end and retain function scene, it is thus achieved that effective logical between web front-end and browser client
Letter reduces the cost that developer's study uses API.
As shown in figure 8, fourth embodiment of the invention proposes a kind of method that browser is communicated with web front-end, comprising:
Step S201, web front-end response interface call instruction are generated to identify the interface call instruction corresponding requests
The id of event;
Step S202 obtains the interface parameters of the request event according to the interface call instruction;
The request event, id and the interface parameters are stored in global variable command queue by step S203;
The global variable command queue is sent to browser by step S204;It is received by the browser described complete
After office's variable command queue, the request event, id and the interface parameters are read from the global variable command queue,
The request event is handled.
Specifically, by taking the mobile phone terminal of ios system as an example, since the currently running browser on ios system is all
Based on safari kernel, the API that web front-end can not be provided directly using browser client, i.e. web front-end lack and browser
The mechanism of client active communication.And for browser client, although the global javascript generation of accessible web front-end
Code, but function scene can not be retained, bigger complexity is brought to web front-end exploitation.
This embodiment scheme can establish the bridge of a communication between web front-end and browser client, by this
Bridge, web front-end can actively and browser client communication, browser client can also actively and web front-end communication and
Retain function scene, realize the efficient communication between web front-end and browser client, reduces developer's study and use API's
Cost.
Specifically, there is a label in web front-end creation, the present embodiment is lifted with a hiding iframe label
Example.Web front-end can trigger an event when giving the src attribute assignment of this iframe label, and browser client meeting and
When capture this event, at the same time, browser can also intercept and capture the src information of iframe label.
Therefore, it is based on this principle, can establish web front-end and browsing by way of creating a hiding iframe
The bridge communicated between device client.An event can be all triggered when creating iframe label and assignment every time due to web front-end,
So being common one order of behavior or transmitting to distinguish creation iframe label, the present embodiment defines the spy of src
Different format, and the format of the src is negotiated to generate by web front-end and browser client, so as to browser client can and
When capture src attribute value.
The present embodiment defines src using following format: mtt:service:action.
Wherein, mtt is character string constant, and service and action uniquely determine the behavior of an order, service mark
Know the behavior of major class, action identifies the subdivision behavior under major class.
By this communication mode, the API that browser client externally provides is asynchronous interface, and development of user can pass
Enter the type of service and action marking command, and using option as command parameter, suc is used as successfully call back function,
Call back function of the err as failure, defines the format of an api interface as a result, are as follows:
BrowserApi (service, action, option, suc, err).
The code library that development of user can call web front-end to provide triggers the calling to client end AP PCI interface.Wherein,
The code library of web front-end is specifically as follows javascript code library.
Web front-end responds the interface call instruction of development of user triggering, can generate one and be sent to browser client
Thus request event initiates an order.
Before web front-end initiates an order to browser client, a unique random number can be automatically generated as id
To identify the order, that is, generate an id to identify the corresponding request event of the interface call instruction.
In addition, web front-end can also obtain the interface parameters of the request event according to the interface call instruction.This connects
Mouth parameter includes: the type of request event and the command parameter of request event;Wherein, the type of request event passes through 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 convenient for browser client pair for sending browser client to
Request event is handled.
In web front-end, command queue queue (the present embodiment claims global variable command queue) can be also safeguarded to save
These request events (containing the corresponding id of request event, the type of request event and the command parameter of request event).
Why web front-end, which passes through global variable command queue, saves request event, id and interface parameters, allows for
Development of user may repeatedly call browser client api interface whithin a period of time, and browser client is different surely
It is enough to handle these request events in time.Therefore, these orders of request event are saved using global variable command queue, sent in batches
To browser client, it thereby may be ensured that the processing opportunity of browser client reasonable arrangement request event, improve browsing
The efficiency of device side system performance and data processing, while also alleviating the data processing pressure of web front-end.
Then, web front-end in a predetermined format, to the src attribute assignment of iframe label, triggers global variable command queue
Transmission;The src attribute includes the service field and action field for identifying the type of the request event.
As a result, by way of the src assignment to hiding iframe created, request event and its related ginseng will be included
Several global variable command queues are passed to browser client.
Web front-end is conveyed global variable command queue by way of the src assignment to hiding iframe created
When to browser client, an event can be triggered, as previously mentioned, browser can capture this event in time.
In browser side, browser client can capture the src attribute format and src attribute value of iframe label, and right
Src attribute format and src attribute value are judged judge whether src attribute format is the format arranged, and whether is src attribute value
Generate variation.
Then, according to the src attribute format and src attribute value of the iframe label, global variable command queue is obtained.
Browser client calls global queue to obtain function after receiving the global variable command queue
(getQueue), id, type and the life of the request event and request event are read from the global variable command queue
Enable parameter.
Then, respective handling is carried out to the request event according to the id of the request event, type and command parameter.
After an order is completed in browser client processing, if handling successfully, browser calls a global successful place
It manages function (sucCallback), processing result, the command parameter of the request event and id is passed to the web front-end.
After processing failure, the browser calls global failure handling function (errCallback), and processing is tied
Fruit, the command parameter of the request event and id are passed to the web front-end.
Pass through above three overall situation function getQueue, sucCallback and errCallback (global queue as a result,
Obtain function, the global failure handling function for being successfully processed function and the overall situation), the call back function of external API can be made to protect
Scene is stayed, because whole system need to only safeguard three overall situation functions getQueue, sucCallback and errCallback, then
Continuous web front-end executes the success after order and failure call back function needs not be global function, and can retain the call back function
Scene.
The present embodiment through the above scheme, through the iframe label of creation, between web front-end and browser client
The bridge for establishing a communication, by the bridge, web front-end can be communicated actively with browser client, browser client
Actively it can also communicate with web front-end and retain function scene, it is thus achieved that having between web front-end and browser client
Effect communication.
In addition, in specific implementation, encapsulating above-mentioned web front-end by providing a basic java script module
The queue maintenance mechanism of communication mode and command calls between browser client externally provides the API of a customization.Exploitation
Only API need to can be used by introducing the component of this lightweight in user, and does not have to concerned with internal and realize, and without any latent rule
Then, to 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 is communicated with web front-end, in above-mentioned Fig. 8
Shown on the basis of fourth embodiment:
After above-mentioned steps S202, further includes:
Step S205, the web front-end is using the id as key value, by the successful call back function in the interface parameters
With failure call back function as in one matching object of value value deposit;
After above-mentioned steps S204, further includes:
Step S206, the web front-end, to the processing result of the request event, are accordingly grasped according to the browser
Make.
The present embodiment and the difference of above-mentioned fourth embodiment shown in Fig. 8 are that the present embodiment further includes web front-end to clear
The scheme of device client process result of looking at progress corresponding operating.
Specifically, in the present embodiment, web front-end is according to interface call instruction, in the interface parameters of acquisition request event
Further include: the successful call back function and failure call back function of request event.
Wherein, the id for the request event that web front-end can will acquire is as key value, by the successful readjustment letter of request event
Number and failure call back function are as in one matching object of value value deposit.
Later, web front-end according to browser to the processing result of request event, when carrying out corresponding operating, specifically use with
Lower scheme:
After browser handles successfully request event, web front-end is according to the id of request event, from the matching object
Corresponding success call back function is found, and is executed;After the browser is to the request event processing failure, before the web
End corresponding failure call back function is found, and execute from the matching object according to the id of request event.
It is laggard that browser client processing request detailed below and web front-end obtain browser client response
The detailed process of row corresponding operating:
Browser client calls global queue to obtain function after receiving global variable command queue
(getQueue), the id of read requests event and request event, type and command parameter from global variable command queue.
Then, respective handling is carried out to request event according to the id of request event, type and command parameter.
After an order is completed in browser client processing, if handling successfully, browser calls a global successful place
It manages function (sucCallback), processing result, the command parameter of request event and id is passed to web front-end.Web front-end according to
The id received finds corresponding success call back function from matching object, and executes.
After browser processing request event failure, browser calls global failure handling function (errCallback),
Processing result, the command parameter of the request event and id are passed to the web front-end.Web front-end according to the id received from
Corresponding failure call back function is found in matching object, and is executed.
By this method, whole system need to only safeguard three overall situation functions getQueue, sucCallback and
ErrCallback, and web front-end executes the success after order and failure call back function needs not be global function, and can protect
Stay the scene of the call back function.
As shown in Figure 10, sixth embodiment of the invention proposes a kind of method that browser is communicated with web front-end, in above-mentioned figure
On the basis of 5th embodiment shown in 9:
Before above-mentioned steps S204, further includes:
Step S207, the web front-end judge whether that creation has the iframe label for communication;If so, entering step
Rapid 204, otherwise enter step S208;
Step S208 creates the iframe label, and enters step S208.
The present embodiment and the difference of above-mentioned 5th embodiment shown in Fig. 9 are the present embodiment further includes whether creating
The scheme of iframe label.
Web front-end is by judgement, if the iframe label currently without creation for communication, creates iframe mark
Label pass through the side of the setting attribute assignment to the label being pre-created if currently there is iframe label of the creation for communication
Global variable command queue is sent to browser by formula.
The present embodiment is established between web front-end and browser client by upper scheme by creating iframe label
The bridge of one communication, by the bridge, web front-end can be communicated actively with browser client, and browser client can also
Actively to be communicated with web front-end and retain function scene, it is thus achieved that effective logical between web front-end and browser client
Letter reduces the cost that developer's study uses API.
As shown in figure 11, first embodiment of the invention proposes a kind of web front-end, comprising: generation module 301 obtains module
302, memory module 303 and sending module 304, in which:
Generation module 301 is used for response interface call instruction, and it is corresponding to identify the interface call instruction to generate an id
Request event;
Module 302 is obtained, for obtaining the interface parameters of the request event according to the interface call instruction;
Memory module 303, for the request event, id and the interface parameters to be stored in global variable command queue
In;
Sending module 304, for by way of the setting attribute assignment to the label being pre-created, the overall situation to be become
Amount command queue is sent to browser;After receiving the global variable command queue by the browser, from the global change
The request event, id and the interface parameters are read in amount command queue, the request event is handled.
As shown in figure 12, second embodiment of the invention proposes a kind of web front-end, the first embodiment shown in above-mentioned Figure 11
On the basis of, further includes:
Operation module 305 carries out corresponding operating for the processing result according to the browser to the request event.
Further, the sending module 304 is also used to judge whether that creation has the iframe label for communication;If
It is then to be ordered the global variable by way of the setting attribute assignment to the label being pre-created by the sending module
Queue is enabled to be sent to browser;Otherwise the iframe label is created.
The basic principle of the corresponding embodiment of above-mentioned Figure 11, Figure 12, please refers to the corresponding method of above-mentioned Fig. 8, Fig. 9 and Figure 10
Embodiment, details are not described herein.
Method, web front-end and the system that browser of the embodiment of the present invention is communicated with web front-end, pass through the iframe of creation
Label establishes the bridge of a communication between web front-end and browser client, and by the bridge, web front-end can be actively
It is communicated with browser client, browser client can also actively and web front-end communicates and retain function scene, is achieved in
Efficient communication between web front-end and browser client reduces the cost that developer's study uses API.
It should also be noted that, herein, the terms "include", "comprise" or its any other variant are intended to non-
It is exclusive to include, so that the process, method, article or the device that include a series of elements not only include those elements,
It but also including other elements that are not explicitly listed, or further include solid by this process, method, article or device
Some elements.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including
There is also other identical elements in the process, method of the element, article or device.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side
Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases
The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art
The part contributed out can be embodied in the form of software products, which is stored in a storage medium
In (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal device (can be mobile phone, computer, clothes
Business device or the network equipment etc.) execute method described in each embodiment of the present invention.
The above description is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all utilizations
Equivalent structure made by description of the invention and accompanying drawing content or process transformation, are applied directly or indirectly in other relevant skills
Art field, is included within the scope of the present invention.
Claims (20)
1. a kind of method that browser is communicated with web front-end characterized by comprising
Web front-end response interface call instruction generates the mark id to identify the interface call instruction corresponding requests event;
The web front-end obtains the interface parameters of the request event according to the interface call instruction;
The web front-end will be in the request event, mark id and interface parameters deposit global variable command queue;
The web front-end is by way of the setting attribute assignment to the label being pre-created, by global variable order team
Column are sent to browser;
After the browser receives the global variable command queue, asked described in reading from the global variable command queue
Event, mark id and the interface parameters are asked, the request event is handled.
2. the method according to claim 1, wherein
The label is embedded frame iframe label, and the web front-end gives the setting attribute assignment for the label being pre-created
The step of include:
The web front-end in a predetermined format, to the src attribute assignment of the embedded frame iframe label, with triggering by institute
It states global variable command queue and is sent to browser method and step;The src attribute includes for identifying the request event
The service field and action field of type.
3. the method according to claim 1, wherein the interface parameters includes: the type and life of request event
Enable parameter;After the browser receives the global variable command queue, institute is read from the global variable command queue
The step of stating request event, mark id and interface parameters, handling the request event include:
After the browser receives the global variable command queue, global queue is called to obtain function, from the overall situation
Mark id, type and the command parameter of the request event and request event are read in variable command queue;
The browser is handled the request event according to mark id, type and the command parameter of the request event;
After handling successfully, the browser calling overall situation is successfully processed function, by processing result, the life of the request event
Parameter and mark id is enabled to be passed to the web front-end;
After processing failure, the browser calls global failure handling function, by processing result, the life of the request event
Parameter and mark id is enabled to be passed to the web front-end.
4. according to the method described in claim 2, it is characterized in that, the browser receives the global variable command queue
Step includes:
The browser captures the src attribute format and src attribute value of the embedded frame iframe label;
According to the src attribute format and src attribute value of the embedded frame iframe label, the global variable order is obtained
Queue.
5. the method according to claim 1, wherein the step that the browser handles the request event
After rapid further include:
The web front-end, to the processing result of the request event, carries out corresponding operating according to the browser.
6. according to the method described in claim 5, it is characterized in that, the interface parameters further include: the request event at
Function call back function and failure call back function;
The web front-end is also wrapped after the step of obtaining the interface parameters of the request event according to the interface call instruction
It includes:
The web front-end using the mark id as key value, using the success call back function and failure call back function as
In one matching object of value value deposit;
According to the browser to the processing result of the request event, the step of carrying out corresponding operating includes: the web front-end
After the browser handles successfully the request event, the web front-end is according to the mark id, from the matching
Corresponding success call back function is found in object, and is executed;
After the browser is to the request event processing failure, the web front-end is according to the mark id, from the matching
Corresponding failure call back function is found in object, and is executed.
7. the method according to any one of claim 2-6, which is characterized in that the web front-end is by being pre-created
Label setting attribute assignment mode, also wrapped before the step of global variable command queue is sent to browser
It includes:
The web front-end judges whether that creation has the embedded frame iframe label for communication;If so,
It executes by way of the setting attribute assignment to the label being pre-created, the global variable command queue is sent to
The step of browser;Otherwise the embedded frame iframe label is created.
8. the system that a kind of browser is communicated with web front-end characterized by comprising browser and logical with the browser
Believe the web front-end of connection;Wherein:
The web front-end is used for response interface call instruction, generates to identify the interface call instruction corresponding requests event
Mark id;According to the interface call instruction, the interface parameters of the request event is obtained;By the request event, mark
Id and the interface parameters are stored in global variable command queue;By to the embedded frame iframe label being pre-created
Setting attribute assignment mode, the global variable command queue is sent to browser;
The browser is read from the global variable command queue after receiving the global variable command queue
The request event, mark id and the interface parameters, handle the request event.
9. system according to claim 8, which is characterized in that
When the web front-end gives the setting attribute assignment for the label being pre-created, it is specifically used in a predetermined format, giving the insertion
The src attribute assignment of formula frame iframe label, to trigger the step of global variable command queue is sent to browser;
The src attribute includes the service field and action field for identifying the type of the request event.
10. system according to claim 8, which is characterized in that the interface parameters includes: the type and life of request event
Enable parameter;
The browser after being also used to receive the global variable command queue, calls global queue to obtain function, from institute
State mark id, type and the command parameter that the request event and request event are read in global variable command queue;According to
Mark id, type and the command parameter of the request event handle the request event;After handling successfully, call complete
Office is successfully processed function, and processing result, the command parameter of the request event and mark id are passed to the web front-end;When
After processing failure, global failure handling function is called, processing result, the command parameter of the request event and mark id are passed
Enter the web front-end.
11. system according to claim 9, which is characterized in that
The browser is also used to capture the src attribute format and src attribute value of the embedded frame iframe label;Root
According to the src attribute format and src attribute value of the embedded frame iframe label, the global variable command queue is obtained.
12. system according to claim 8, which is characterized in that
The web front-end is also used to the processing result according to the browser to the request event, carries out corresponding operating.
13. system according to claim 12, which is characterized in that the interface parameters further include: the request event
Success call back function and failure call back function;
The web front-end is also used to using the mark id as key value, by the success call back function and failure call back function
As in one matching object of value value deposit;After the browser handles successfully the request event, according to the mark
Id finds corresponding success call back function from the matching object, and executes;At the browser is to the request event
After reason failure, according to the mark id, corresponding failure call back function is found from the matching object, and execute.
14. the system according to any one of claim 8-13, which is characterized in that
The web front-end is also used to judge whether that creation has the embedded frame iframe label for communication;If so, logical
It crosses to the mode of the setting attribute assignment for the label being pre-created, the global variable command queue is sent to browser;It is no
Then create the embedded frame iframe label.
15. a kind of web front-end characterized by comprising
Generation module is used for response interface call instruction, generates to identify the interface call instruction corresponding requests event
Identify id;
Module is obtained, for obtaining the interface parameters of the request event according to the interface call instruction;
Memory module, for the request event, mark id and the interface parameters to be stored in global variable command queue;
Sending module, for inciting somebody to action by way of the setting attribute assignment to the embedded frame iframe label being pre-created
The global variable command queue is sent to browser;After receiving the global variable command queue by the browser, from
The request event, mark id and the interface parameters are read in the global variable command queue, to the request event
It is handled.
16. web front-end according to claim 15, which is characterized in that
The sending module is specifically used in a predetermined format, to the src attribute assignment of the embedded frame iframe label,
The step of global variable command queue is sent to browser with triggering;The src attribute includes for identifying described ask
Ask the service field and action field of the type of event.
17. web front-end according to claim 15, which is characterized in that further include:
Operation module carries out corresponding operating for the processing result according to the browser to the request event.
18. web front-end according to claim 17, which is characterized in that
The memory module, is also used to using the mark id as key value, by the interface parameters successful call back function and
Failure call back function is as in one matching object of value value deposit;
The operation module is also used to after the browser handles successfully the request event, according to the mark id, from
Corresponding success call back function is found in the matching object, and is executed;Request event processing is lost in the browser
After losing, according to the mark id, corresponding failure call back function is found from the matching object, and execute.
19. web front-end described in any one of 5-18 according to claim 1, which is characterized in that
The sending module is also used to judge whether that creation has the embedded frame iframe label for communication;If so, by
The sending module is sent out the global variable command queue by way of the setting attribute assignment to the label being pre-created
It send to browser;Otherwise the embedded frame iframe label is created.
20. a kind of computer storage medium, feature is being, including computer-readable application code, is used for right of execution
Benefit requires the step of method described in 1-7 any one.
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 CN105573733A (en) | 2016-05-11 |
CN105573733B true 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) |
Families Citing this family (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
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 |
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 |
CN111352741B (en) * | 2018-12-21 | 2021-04-06 | 马上消费金融股份有限公司 | Interface calling method and device, intelligent terminal and storage device |
CN110990167B (en) * | 2019-11-26 | 2023-07-28 | 网易(杭州)网络有限公司 | Front-end communication method and device, storage medium and electronic equipment |
CN111538485B (en) * | 2020-03-26 | 2022-04-05 | 郑州信大捷安信息技术股份有限公司 | Web application development method and system based on TypeScript |
CN113569180B (en) * | 2021-07-28 | 2024-01-26 | 中国电子科技集团公司第二十八研究所 | Universal browser expansion system |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
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 |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6990534B2 (en) * | 2001-07-20 | 2006-01-24 | Flowfinity Wireless, Inc. | Method for a proactive browser system for implementing background frame maintenance and asynchronous frame submissions |
WO2013188317A1 (en) * | 2012-06-10 | 2013-12-19 | Kevin Mcgushion | Active web page consolidator |
-
2014
- 2014-10-16 CN CN201410549577.8A patent/CN105573733B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
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 |
Also Published As
Publication number | Publication date |
---|---|
CN105573733A (en) | 2016-05-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105573733B (en) | Method, web front-end and the system that browser is communicated with web front-end | |
CN105940409B (en) | Network services sandbox system | |
CN104426885B (en) | Abnormal account providing method and device | |
EP3324325B1 (en) | Method, client, and system for testing application | |
KR101781339B1 (en) | Method and device for updating client | |
US20160241589A1 (en) | Method and apparatus for identifying malicious website | |
JP5238851B2 (en) | Screen generation system, screen generation method, and screen generation program | |
CN104049986A (en) | Plugin loading method and device | |
CN105871587A (en) | Log uploading method and device | |
CN109672580A (en) | Full link monitoring method, apparatus, terminal device and storage medium | |
CN104883384B (en) | A kind of method and apparatus for the end ability that client is provided for light application | |
US20230033804A1 (en) | Information sharing chain generation method and apparatus, electronic device, and storage medium | |
Liu et al. | Characterizing restful web services usage on smartphones: A tale of native apps and web apps | |
WO2018171572A1 (en) | Malicious web address identification method, computer apparatus and storage medium | |
WO2021098393A1 (en) | Method and apparatus for intelligent system resource monitoring, electronic device, and storage medium | |
CN109522021B (en) | Parameter callback processing method and device, electronic equipment and storage medium | |
CN106209584B (en) | User information processing method, client and server Internet-based | |
CN108833500B (en) | Service calling method, service providing method, data transmission method and server | |
JP2005228183A (en) | Program execution method and computer system for executing the program | |
CN112286815A (en) | Interface test script generation method and related equipment thereof | |
JP2018506783A (en) | Generating element identifiers | |
WO2017133229A1 (en) | Mobile terminal image display method and device | |
JP5643449B1 (en) | Server and method for displaying display screen on terminal device | |
CN107168648B (en) | File storage method and device and terminal | |
CN110262856B (en) | Application program data acquisition method, device, terminal and storage medium |
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 | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20221010 Address after: 430000, No.1, Yangguang fifth road, Miaoshan, Jiangxia Economic Development Zone, Wuhan City, Hubei Province Patentee after: Tencent Technology (Wuhan) Co.,Ltd. Address before: 2, 518000, East 403 room, SEG science and Technology Park, Zhenxing Road, Shenzhen, Guangdong, Futian District Patentee before: TENCENT TECHNOLOGY (SHENZHEN) Co.,Ltd. |