Check patentability & draft patents in minutes with Patsnap Eureka AI!

Communication method and device between js module and java module

A communication method and object technology, which is applied in the computer field, can solve problems such as increasing terminal memory usage, reducing application performance, and reducing communication efficiency between JavaScript and Java, so as to achieve the effects of reducing memory usage, improving communication efficiency, and improving operating performance

Active Publication Date: 2022-01-07
TENCENT TECH (SHENZHEN) CO LTD
View PDF7 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

However, the main function of WebView is to display pages. In some scenarios that do not need to open pages, if the communication between JavaScript and Java is implemented through WebView, the memory usage of the terminal will be increased.
At the same time, when the page is relatively busy, using this method will reduce the communication efficiency between JavaScript and Java, thereby reducing the running performance of the application

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Communication method and device between js module and java module
  • Communication method and device between js module and java module
  • Communication method and device between js module and java module

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0019] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0020] The embodiment of the invention discloses a communication method and device between a JS module and a Java module, which can reduce the occupation of terminal memory, improve the communication efficiency between JavaScript and Java, and thereby improve the operating performance of applications. Each will be described in detail below.

[0021] see figure 1 , figure 1 It is a schematic flowchart of a communication method between a JS module and a Java module...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The embodiment of the invention discloses a communication method and device between a JS module and a Java module. Wherein, the method includes: when the application needs to call the Java interface through the JS module to realize a certain function, the communication device between the JS module and the Java module can search the Java object from the Java module through the Java object pre-injected in the JavaScript engine of the JS module. For the target Java object, when the target Java object is found, it is determined that there is a target method corresponding to the target Java object in the Java module, and the JavaScript engine invokes the target method to perform operations corresponding to the target Java object on the target Java object. Through the embodiment of the present invention, the communication between the JS module and the Java module can be realized without using a network view, thereby reducing the memory occupation of the terminal, improving the communication efficiency, and improving the operating performance of the application.

Description

technical field [0001] The invention relates to the field of computer technology, in particular to a communication method and device between a JS module and a Java module. Background technique [0002] With the continuous development of terminal technology, more and more applications can be installed on terminals such as smartphones and tablet computers to enrich people's lives, and have now become indispensable electronic devices in people's work and life. On the current Android device, the communication between JavaScript and Java in the application needs to be realized through the web view WebView. However, the main function of WebView is to display pages. In some scenarios that do not need to open pages, if the communication between JavaScript and Java is implemented through WebView, the memory usage of the terminal will be increased. At the same time, when the page is relatively busy, using this method will reduce the communication efficiency between JavaScript and Jav...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F9/54
CPCG06F9/543
Inventor 王勇
Owner TENCENT TECH (SHENZHEN) CO LTD
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More