Inter-process communication method and device

A technology of inter-process communication and process, applied in the direction of inter-program communication, multi-program device, etc., can solve the problems of increasing the complexity of inter-process communication

Active Publication Date: 2014-03-12
BEIJING QIHOO TECH CO LTD
View PDF4 Cites 23 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] Generally speaking, the main program will run the corresponding main process during the running process. Based on the needs of different tasks, it often needs to start and

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
  • Inter-process communication method and device
  • Inter-process communication method and device
  • Inter-process communication method and device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0112] refer to figure 1 , figure 1 An inter-process communication method provided by an embodiment of the present invention is shown, and the method includes:

[0113] S101. The main process creates a sub-process host object, and assigns a corresponding sub-process identifier to the sub-process host object.

[0114] In the embodiment of the present invention, the main process creates and manages sub-process host objects, each sub-process host object corresponds to a sub-process, and has the same sub-process identifier as the corresponding sub-process.

[0115] S102. The main process uses the created sub-process host object to start the sub-process, and sends a first command to the sub-process, where the first command line carries the sub-process identifier and the main process communication interface handle.

[0116] The subprocess host object provides a method for creating and starting a subprocess, and provides a data communication interface for sending the first command ...

Embodiment 2

[0137] refer to figure 2 , figure 2 An inter-process communication method provided by an embodiment of the present invention is shown, and the method includes:

[0138] S201, the main process creates a new browser sub-window.

[0139] S202. The main process creates a sub-process rendering host object, and assigns a corresponding rendering object identifier to the sub-process rendering host object.

[0140] S203. The main process invokes the subprocess host object rendering method, creates a subprocess host object in the method, and assigns a corresponding subprocess identifier to the subprocess host object.

[0141] S204, the main process uses the created sub-process host object to start the sub-process, and sends a first command to the sub-process, where the first command line carries the sub-process identifier and the main process communication interface handle.

[0142] S205, the subprocess starts and receives a first command from the main process.

[0143] S206, the ...

Embodiment 3

[0168] This embodiment takes a specific data object model as an example to describe an inter-process communication method provided by the present invention, and the involved data object model is defined as follows:

[0169] CApplication application

[0170] -CMainProcess main process

[0171] -CChildProcess child process

[0172] Among them, the data model provided by the main process CMainProcess is shown in Table 1; the data model provided by the child process CChildProcess is shown in Table 2:

[0173]

[0174] Table 1

[0175]

[0176] Table 2

[0177] refer to image 3 , image 3 An inter-process communication method provided by an embodiment of the present invention is shown, and the method includes:

[0178] S301, the main process creates a new browser sub-window.

[0179] S302. The main process creates a sub-process rendering host object CRenderViewHost, and assigns a corresponding rendering object identifier viewid to the sub-process rendering host object...

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 invention discloses an inter-process communication method which comprises the steps that a main process establishes a subprocess host object; the main process starts a subprocess through the established subprocess host object and sends a first command to the subprocess; the subprocess is started to receive the first command from the main process; the subprocess establishes a corresponding subprocess object; the subprocess object sends a start response message to the main process; the main process determines the corresponding subprocess host object according to a subprocess identifier in the received start response message and sets a corresponding subprocess communication interface handle for the subprocess host object; the main process and the subprocess build a communication channel for data transmission. According to such an inter-process communication mechanism, even if the main process needs to operate more subprocesses, the complexity of the inter-process communication is not increased, and the cost of operating and maintaining communication between a plurality of inter-processes is effectively reduced.

Description

technical field [0001] The invention relates to the technical field of human-computer interaction, in particular to an inter-process communication method and device. Background technique [0002] A process is the smallest unit for allocating resources in a computer system. Each process has its own part of independent system resources, which are isolated from each other. In order to enable different processes to access resources and coordinate work with each other, there is Inter-Process Communication (IPC). The so-called IPC communication refers to the dissemination or exchange of information between processes. [0003] Generally speaking, the main program will run the corresponding main process during the running process. Based on the needs of different tasks, it often needs to start and run multiple corresponding sub-processes at the same time. With the increase of the number of sub-processes, the complexity of inter-process communication The degree also increased accor...

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
IPC IPC(8): G06F9/54
Inventor 李超张菊元
Owner BEIJING QIHOO TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products