Application layer management method and system for Yocto project and electronic equipment
By applying layer management methods to the server for applying layer management methods in the Yocto project, the problem of lack of layer management for applications in the Yocto project is solved, and the flexibility of the application interface and development efficiency are improved.
Patent Information
- Application Number
- CN202510583463.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-07
- Publication Date
- 2025-08-15
AI Technical Summary
The lack of layer management functions among applications in the Yocto project leads to inefficient development and it is difficult to effectively manage the hierarchical relationships of application layers.
By applying for the data storage space of each application layer to the server side and storing the layers in the corresponding data storage space, the server side sorts each application layer according to the layer ranking to form a layer display interface with layer hierarchical relationships.
It realizes flexible layer management between different applications and between application layers, improving the flexibility and development efficiency of the application interface.
Smart Images

Figure CN120491960A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of application layer management, and in particular to an application layer management method, system, and electronic device for a Yocto project. Background Art
[0002] The Yocto Project is an open-source collaborative project that supports multiple hardware architectures. It aims to help developers create customized systems suitable for embedded product development, such as automotive instrument clusters. By providing templates, tools, and methods, it simplifies the embedded system building process, making the development process simpler and more reliable.
[0003] However, since the Yocto Project itself does not have layer management capabilities, there is no hierarchical concept in the program interfaces between applications and the application layers within applications. In other words, there is no layer Z-axis, which means that the application layers are simply updated according to the rendering order, making it difficult for developers to manage application layers, resulting in reduced development efficiency. Summary of the Invention
[0004] In order to provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. The summary is not an extensive review, nor is it intended to identify key / critical elements or delineate the scope of protection of these embodiments, but rather serves as a prelude to the detailed description that follows.
[0005] In view of the shortcomings of the prior art described above, the present application provides an application layer management method, system, and electronic device for the Yocto Project, so that application layers have a layer hierarchical relationship, thereby facilitating layer management.
[0006] The present application provides an application layer management method for the Yocto Project, which is applied to an application in the Yocto Project, wherein the application is connected to a server. The method comprises: obtaining a layer sequence corresponding to one or more application layers; applying to the server for a data storage space corresponding to each of the application layers, and storing each of the layer sequences in the corresponding data storage space, wherein the server is configured to sort each of the application layers according to the layer sequence to obtain a layer display interface having a layer hierarchy.
[0007] In one embodiment of the present application, the application includes: an interface process, which is used to manage the layer data corresponding to each of the application layers, wherein the layer data includes at least one of layer order, pixel data, storage identifier and initialization data, and the initialization data includes at least one of layer coordinates, layer height, layer width and layer transparency; an interface client, connected to the server, and the interface client is used to generate a layer display interface based on the layer data using the server, and filter the feedback data sent by the server to the interface client to send the filtered feedback data to the interface process.
[0008] In one embodiment of the present application, the interface client applies to the server for the data storage space corresponding to each application layer in the following manner: sending the initialization data corresponding to any application layer to the server, wherein the server is used to obtain the storage identifier corresponding to the application layer and the data storage space corresponding to the storage identifier, so as to store the initialization data corresponding to the application layer in the corresponding data storage space, and feedback the storage identifier and / or storage allocation result; receiving the storage identifier and / or the storage allocation result, and sending the received storage identifier to the interface process.
[0009] In one embodiment of the present application, the method further includes: using the interface client to obtain a cache handle corresponding to the application layer from the server, wherein the cache handle points to the pixel data of the application layer in the data storage space; using the interface process to draw the pixel data of the application layer in the data storage space according to the cache handle, and generate drawing position information corresponding to the drawing area; using the interface client to send the drawing position information and the storage identifier corresponding to the drawing position information to the server, wherein the server is used to extract the data to be rendered from the corresponding data storage space according to the storage identifier corresponding to the drawing position information, so as to perform layer rendering according to the extracted data to be rendered according to the corresponding drawing position information to obtain the application layer, and the data to be rendered includes initialization data and / or pixel data.
[0010] In one embodiment of the present application, the method further includes: obtaining a layer to be released, wherein the layer to be released includes any application layer; using the interface client to send a storage identifier corresponding to the layer to be released to the server, wherein the server is used to delete the data storage space corresponding to the layer to be released from each data storage space according to the storage identifier corresponding to the layer to be released.
[0011] In one embodiment of the present application, the interface client is further used to: obtain the connection waiting time and send a connection request to the server to establish a data link between the interface client and the server; if the connection waiting time belongs to the preset target value, then after the interface client receives the connection result fed back by the server based on the connection request, the interface client applies to the server for the data storage space corresponding to each of the application layers; if the connection waiting time does not belong to the preset target value, then after the interface client receives the connection result fed back by the server based on the connection request, the interface client waits according to the connection waiting time, and then applies to the server for the data storage space corresponding to each of the application layers.
[0012] The present application provides an application layer management method for the Yocto Project, which is applied to a server side, wherein the server side is connected to an application in the Yocto Project. The method comprises: obtaining data storage spaces corresponding to one or more application layers; storing the layer sequence corresponding to each of the application layers in the corresponding data storage space; and sorting the application layers according to the layer sequence to obtain a layer display interface with a layer hierarchy relationship.
[0013] In one embodiment of the present application, each of the application layers is sorted according to the layer order to obtain a layer display interface with a layer hierarchical relationship, including: the data storage space also stores data to be rendered; a queue to be rendered is obtained, and the queue to be rendered is queried according to a preset query cycle; if the drawing position information corresponding to any application layer and the storage identifier corresponding to the drawing position information are obtained, the drawing position information and the storage identifier corresponding to the drawing position information are stored in the queue to be rendered; if it is found that there is a queue to be rendered and a storage identifier in the queue to be rendered, a copy queue corresponding to the queue to be rendered is generated, and the queue to be rendered is cleared; the layer order and the data to be rendered are extracted from the corresponding data storage space according to the storage identifier in the amplitude queue, layer rendering is performed according to the data to be rendered according to the corresponding drawing position information to obtain the application layer, and the application layer is unioned with the current layer display interface according to the layer order to obtain a new layer display interface.
[0014] The present application provides an application layer management system for the Yocto Project, comprising: an application in the Yocto Project connected to a server, the application being used to obtain layer sequences corresponding to one or more application layers; the server being used to obtain data storage spaces corresponding to the one or more application layers; storing the layer sequences corresponding to the application layers in the corresponding data storage spaces; and sorting the application layers according to the layer sequences to obtain a layer display interface having a layer hierarchy.
[0015] The present application provides an electronic device, comprising: a processor and a memory; the memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the electronic device performs the method as described above.
[0016] Beneficial effects of this application:
[0017] By requesting data storage space corresponding to each application layer in the application from the server, and storing the layer order of each application layer in the corresponding data storage space, the server can sort the application layers according to the layer order, thereby obtaining a layer display interface with a layer hierarchy. In this way, by introducing data storage space storing layer orders on the server side, and sorting the layer hierarchy between application layers according to the layer order, a layer display interface is formed, thereby providing layer management services to the application, facilitating layer management between different applications and different application layers, and thus making the implementation of the application interface more flexible. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 This is a schematic diagram of the structure of an application environment for implementing the application layer management method of the Yocto Project in an embodiment of the present application;
[0019] Figure 2 This is a flowchart of an application layer management method for the Yocto Project in an embodiment of the present application;
[0020] Figure 3 This is a flow chart of a method for connecting an interface client and a server in an embodiment of the present application;
[0021] Figure 4 This is a flow chart of a method for applying for data storage space in an embodiment of the present application;
[0022] Figure 5 This is a flowchart of an application layer rendering method in an embodiment of the present application;
[0023] Figure 6 This is a flowchart of a method for deleting a data storage space in an embodiment of the present application;
[0024] Figure 7 This is a flowchart of another application layer management method for the Yocto Project in an embodiment of the present application;
[0025] Figure 8 This is a schematic diagram of the structure of an application layer management system for the Yocto Project in an embodiment of the present application;
[0026] Figure 9 It is a schematic structural diagram of an electronic device in an embodiment of the present invention. DETAILED DESCRIPTION
[0027] The following describes the embodiments of the present invention through specific examples. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through different specific embodiments. The details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and sub-samples in the embodiments can be combined with each other unless there is a conflict.
[0028] It should be noted that the illustrations provided in the following embodiments are merely schematic illustrations of the basic concept of the present invention. Therefore, the illustrations only show components related to the present invention and are not drawn according to the number, shape, and size of components in actual implementation. In actual implementation, the type, quantity, and proportion of each component may be changed arbitrarily, and the component layout may also be more complex.
[0029] In the following description, numerous details are discussed to provide a more thorough explanation of the embodiments of the present invention. However, it will be apparent to those skilled in the art that the embodiments of the present invention may be practiced without these specific details. In other embodiments, well-known structures and devices are shown in block diagram form rather than in detail to avoid obscuring the embodiments of the present invention.
[0030] The terms "first," "second," and the like in the specification and claims of this application and the accompanying drawings are used to distinguish similar items and are not necessarily used to describe a particular order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate for the embodiments of the present application described herein. In addition, the terms "including," "having," and any variations thereof are intended to cover non-exclusive inclusions.
[0031] Unless otherwise stated, the term "plurality" means two or more.
[0032] In this application, the character " / " indicates that the preceding and following objects are in an "or" relationship. For example, A / B means: A or B.
[0033] The term "and / or" describes an association between objects, indicating that three relationships can exist. For example, A and / or B means: A or B, or A and B.
[0034] Combine Figure 1As shown, the present application provides an application environment for implementing an application layer management method for the Yocto project, including an application 101 and a server 102, wherein data communication is performed between the application and the server via a network.
[0035] The application 101 is developed based on the Yocto project, and an interface process 1011 and an interface client 1012 are provided in the application.
[0036] The interface process 1011 is used to manage the layer data corresponding to each application layer, wherein the layer data includes at least one of layer order, pixel data, storage identifier and initialization data, and the initialization data includes at least one of layer coordinates, layer height, layer width and layer transparency.
[0037] The interface client (FdbusScreenClient) 1012 is connected to the server. The interface client is used to generate a layer display interface based on the layer data using the server, and filter the feedback data sent by the server to the interface client to send the filtered feedback data to the interface process.
[0038] The server side 102 includes a data interaction module 1021 , a cache management module 1022 and a layer rendering module 1023 .
[0039] The data interaction module (FdbusScreenSever) 1021 is used to communicate with the interface client and send the interface client's request to the cache management module or the layer rendering module.
[0040] The cache management module (ScreenBufferManager) 1022 is used to manage the data storage space corresponding to the application layer.
[0041] The layer rendering module (RenderManager) 1023 is used to render the application layer according to the data in the data storage space, and sort the application layers according to the layer sequence to obtain a layer display interface with a layer hierarchy relationship.
[0042] Combine Figure 2 As shown, the present application provides an application layer management method for the Yocto Project, which is applied to an application in the Yocto Project. The method includes:
[0043] Step S201: Obtain the layer sequence corresponding to one or more application layers;
[0044] Step S202: Apply to the server for data storage space corresponding to each application layer, and store each layer in sequence in the corresponding data storage space;
[0045] Among them, the server side is used to sort the application layers according to the layer sequence to obtain a layer display interface with a layer hierarchical relationship.
[0046] The application layer management method for the Yocto Project provided in this application utilizes a method that applies to a server for data storage space corresponding to each application layer in the application, and stores the layer order of each application layer in the corresponding data storage space. This allows the server to sort the application layers according to the layer order, thereby obtaining a layer display interface with a layer hierarchy. In this way, by introducing a data storage space storing the layer order on the server side, and sorting the layer hierarchy between the application layers according to the layer order, a layer display interface is formed, thereby providing layer management services to the application, facilitating layer management between different applications and between different application layers, and thereby making the implementation of the application interface more flexible.
[0047] Optionally, the application includes: an interface process, which is used to manage layer data corresponding to each application layer, wherein the layer data includes at least one of layer order, pixel data, storage identifier and initialization data, and the initialization data includes at least one of layer coordinates, layer height, layer width and layer transparency; an interface client, connected to the server, the interface client is used to generate a layer display interface based on the layer data using the server, and filter the feedback data sent by the server to the interface client, so as to send the filtered feedback data to the interface process.
[0048] In some embodiments, an interface client FdbusScreenClient is defined in the application for communicating with the server side, and the interface process obtains the interface client through instantiation, wherein the interface client is developed based on the communication middleware of the RPC protocol (Remote Procedure Call), allowing the application to call the server side method or function like calling a local method, thereby simplifying the complexity of the underlying network communication. The communication middleware of the RPC protocol includes Fdbus, Someip, etc.
[0049] In some embodiments, the interface client is used to implement at least a part of the connection establishment interface, storage application interface, rendering push interface and storage release interface, wherein the connection establishment interface is used to establish a data link between the interface client and the server side, the storage application interface is used to apply to the server side for data storage space corresponding to the application layer, the rendering push interface is used to apply to the server side for rendering the application layer, and the storage release interface is used to request the server side to delete the data storage space corresponding to certain application layers.
[0050] In some embodiments, the application only communicates with the server through the interface client, hides the data interface between the interface client and the server from the interface process, and only sends filtered feedback data to the interface process to ensure data isolation between the interface client and the interface process.
[0051] In this way, not only is the data security of the application improved through data isolation, but there is also no need to redevelop the interface process, thereby improving development efficiency.
[0052] Optionally, the interface client is also used to: obtain the connection waiting time and send a connection request to the server to establish a data link between the interface client and the server; if the connection waiting time belongs to the preset target value, then after the interface client receives the connection result based on the connection request feedback from the server, the interface client applies to the server for the data storage space corresponding to each application layer; if the connection waiting time does not belong to the preset target value, then after the interface client receives the connection result based on the connection request feedback from the server, the interface client waits according to the connection waiting time, and then applies to the server for the data storage space corresponding to each application layer.
[0053] In some embodiments, the interface client establishes a data link between the interface client and the server by implementing a connection establishment interface. The return value of the connection establishment interface is the connection result fed back by the server based on the connection request, and the interface client does not expose the connection establishment interface to the client process, wherein the connection establishment interface includes a blocking function intinit (uint32_twaitMs=-1); if the connection waiting time waitMs belongs to the preset target value -1, it means that the connection establishment interface will block the storage application interface until the connection result fed back by the server based on the connection request is received; if the connection waiting time waitMs is a specific time value, then after receiving the connection result fed back by the server based on the connection request, it will wait according to the connection waiting time waitMs. The storage application interface will be blocked during the waiting period, and after the waiting time, the storage application interface will be allowed to be implemented.
[0054] Combine Figure 3 As shown, the present application provides a method for connecting an interface client and a server, including:
[0055] Step S301, the interface process instantiates the interface client;
[0056] Step S302: The interface client sends a connection request to the data interaction module through the connection establishment interface;
[0057] Among them, the server side includes a data interaction module;
[0058] Step S303: The data interaction module establishes a data link between the interface client and the data interaction module.
[0059] Optionally, the interface client applies to the server for the data storage space corresponding to each application layer in the following manner: sending the initialization data corresponding to any application layer to the server, wherein the server is used to obtain the storage identifier corresponding to the application layer and the data storage space corresponding to the storage identifier, so as to store the initialization data corresponding to the application layer in the corresponding data storage space, and feedback the storage identifier and / or storage allocation result; receiving the storage identifier and / or storage allocation result, and sending the received storage identifier to the interface process.
[0060] In some embodiments, the interface client applies to the server for data storage space corresponding to the application layer by implementing the storage application interface, wherein the storage application interface includes a cache creation function void AsyncCreateBuffer(Buffer desc, std::function <void(std::shared_ptr <buffer>pBuffer)>), the type of data storage space is a temporary cache space Buffer, the Buffer structure includes at least one of layer sequence, pixel data, storage identifier and initialization data, and the initialization data includes at least one of layer coordinates, layer height, layer width and layer transparency, as shown in Table 1.
[0061] Table 1
[0062]
[0063] In some embodiments, the server side will feedback the storage identifier and mapping address to the interface client. The mapping address stores the pixel data of the application layer in the data storage space, but the interface client does not expose the mapping address to the interface process. Instead, it converts the mapping address into a cache handle and sends the cache handle to the interface process.
[0064] In this way, the UI process uses the cache handle as an abstract identifier to indirectly access the pixel data corresponding to the mapping address, thereby hiding the actual changes of the mapping address and ensuring that the UI process does not need to care about changes in the mapping address.
[0065] Combine Figure 4 As shown, this application provides a method for applying for data storage space, including:
[0066] Step S401: The interface client sends a data cache request corresponding to the application layer to the data interaction module through the storage application interface;
[0067] The data cache request includes layer sequence and initialization data;
[0068] Step S402: The data interaction module sends a data cache request to the cache management module;
[0069] Step S403: The cache management module obtains the storage identifier corresponding to the application layer;
[0070] Step S404: the cache management module allocates data storage space corresponding to the storage identifier from the preset cache space;
[0071] The cache management module uses the shm_open instruction to open the preset cache space, which is represented by / share_buffer_{id}, and then uses the ftruncate instruction to allocate the corresponding data storage space for the storage identifier;
[0072] Step S405: The cache management module stores the storage identifier, layer sequence, pixel data, and initialization data into the data storage space;
[0073] Step S406: The cache management module sends the storage identifier and mapping address to the data interaction module;
[0074] The mapping address stores pixel data of the application layer in the data storage space;
[0075] Step S407: the data interaction module sends the storage identifier and mapping address to the interface client;
[0076] Step S408, the interface client points to the mapping address through the cache handle;
[0077] Step S409: The interface client sends a storage identifier and a cache handle to the interface process.
[0078] Optionally, the method also includes: using the interface client to obtain a cache handle corresponding to the application layer from the server, wherein the cache handle points to the pixel data of the application layer in the data storage space; using the interface process to draw the pixel data of the application layer in the data storage space according to the cache handle, and generate drawing position information corresponding to the drawing area; using the interface client to send the drawing position information and the storage identifier corresponding to the drawing position information to the server, wherein the server is used to extract the data to be rendered from the corresponding data storage space according to the storage identifier corresponding to the drawing position information, so as to perform layer rendering according to the corresponding drawing position information based on the extracted data to be rendered, and obtain the application layer, and the data to be rendered includes initialization data and / or pixel data.
[0079] In some embodiments, the interface process uses its own interface to edit the pixel data pointed to by the cache handle, thereby drawing the application layer, and after the drawing is completed, the drawing position information Rect and the storage identifier Buffer_id are sent to the interface client; the interface client sends the drawing position information Rect and the storage identifier Buffer_id to the server by implementing the rendering push interface to apply to the server for rendering the application layer, wherein the rendering push interface includes a push function int AsyncPostBuffer(int bufferId,Rect rect,std::function<void(uint16_t int)> ), the drawing position information includes the region boundary coordinates and / or region size, as shown in Table 2.
[0080] Table 2
[0081]
[0082] Combine Figure 5 As shown, the present application provides an application layer rendering method, including:
[0083] Step S501: the interface process sends drawing position information and storage identifier to the interface client;
[0084] Step S502: the interface client sends the drawing position information and storage identifier to the data interaction module;
[0085] Step S503: The data interaction module sends the drawing position information and storage identifier to the layer rendering module;
[0086] Step S504: The layer rendering module extracts the data to be rendered from the corresponding data storage space according to the storage identifier corresponding to the drawing position information;
[0087] The data to be rendered includes initialization data and / or pixel data;
[0088] Step S504: The layer rendering module performs layer rendering according to the extracted data to be rendered and the corresponding drawing position information, obtains an application layer, and generates a layer rendering result;
[0089] Step S505: the layer rendering module sends the layer rendering result to the data interaction module;
[0090] Step S506: the data interaction module sends the layer rendering result to the interface client;
[0091] Step S507: The interface client sends the layer rendering result to the interface process.
[0092] Optionally, the method also includes: obtaining the layer to be released, wherein the layer to be released includes any application layer; using the interface client to send the storage identifier corresponding to the layer to be released to the server, wherein the server is used to delete the data storage space corresponding to the layer to be released from each data storage space according to the storage identifier corresponding to the layer to be released.
[0093] In some embodiments, when the interface process no longer uses the application layer, the application layer is treated as a layer to be released, and the interface process sends a storage identifier corresponding to the layer to be released to the interface client; the interface client sends the storage identifier corresponding to the layer to be released to the server side by implementing a storage release interface to request the server side to delete the data storage space corresponding to the layer to be released, wherein the storage release interface includes a push function void ReleaseBuffer(int buffer_id).
[0094] In some embodiments, when the interface client disconnects the data link with the server, the server automatically deletes all data storage spaces corresponding to the interface client.
[0095] Combine Figure 6 As shown, the present application provides a method for deleting data storage space, including:
[0096] Step S601: The interface process sends a storage identifier corresponding to the layer to be released to the interface client;
[0097] Step S602: The interface client sends a storage identifier corresponding to the layer to be released to the data interaction module;
[0098] Step S603: The data interaction module sends the storage identifier corresponding to the layer to be released to the cache management module;
[0099] Step S604: The cache management module deletes the data storage space corresponding to the layer to be released from each data storage space according to the storage identifier corresponding to the layer to be released;
[0100] Step S605: The cache management module generates a storage release result;
[0101] Step S606: The cache management module sends a storage release result to the data interaction module;
[0102] Step S607: The data interaction module sends the storage release result to the interface client.
[0103] Combine Figure 7 As shown, the present application provides an application layer management method for the Yocto Project, which is applied to a server side, and the server side is connected to an application in the Yocto Project. The method includes:
[0104] Step S701: Obtain data storage space corresponding to one or more application layers;
[0105] Step S702: storing the layer sequence corresponding to each application layer in the corresponding data storage space;
[0106] Step S703 : sorting the application layers according to the layer sequence to obtain a layer display interface with a layer hierarchy.
[0107] The application layer management method for the Yocto Project provided in this application utilizes a method that applies to a server for data storage space corresponding to each application layer in the application, and stores the layer order of each application layer in the corresponding data storage space. This allows the server to sort the application layers according to the layer order, thereby obtaining a layer display interface with a layer hierarchy. In this way, by introducing a data storage space storing the layer order on the server side, and sorting the layer hierarchy between the application layers according to the layer order, a layer display interface is formed, thereby providing layer management services to the application, facilitating layer management between different applications and between different application layers, and thereby making the implementation of the application interface more flexible.
[0108] Optionally, each application layer is sorted according to the layer order to obtain a layer display interface with a layer hierarchy relationship, including: the data storage space also stores data to be rendered; a queue to be rendered is obtained, and the queue to be rendered is queried according to a preset query cycle; if the drawing position information corresponding to any application layer and the storage identifier corresponding to the drawing position information are obtained, the drawing position information and the storage identifier corresponding to the drawing position information are stored in the queue to be rendered; if it is found that there is a queue to be rendered and a storage identifier in the queue to be rendered, a copy queue corresponding to the queue to be rendered is generated, and the queue to be rendered is cleared; the layer order and the data to be rendered are extracted from the corresponding data storage space according to the storage identifier in the amplitude queue, and layer rendering is performed according to the corresponding drawing position information based on the data to be rendered to obtain the application layer, and the application layer is unioned with the current layer display interface according to the layer order to obtain a new layer display interface.
[0109] In some embodiments, the layer rendering module on the server side uses the Enque interface to send the drawing position information Rect and the storage identifier Buffer_id to the queue to be rendered Queue <pair<int,Rect> >dirtyQueue, and maintain a thread to query the rendering queue according to the preset query cycle, where the preset query cycle is determined according to business needs and system performance, for example, the preset query cycle is 20ms (milliseconds); if the query shows that the rendering queue is not empty, a deep copy of the rendering queue is made to obtain the copy queue, and the rendering queue is cleared; the layer is rendered according to the drawing position information in the copy queue, and the current layer display interface is unioned according to the layer sequence to obtain a new layer display interface; the layer rendering result is fed back to all interface clients with data storage areas through the data interaction module.
[0110] Combine Figure 8 As shown, the present application provides an application layer management system for the Yocto project, including an application 101 and a server 102 in the Yocto project.
[0111] The application 101 is connected to the server side, and is used to obtain the layer sequence corresponding to one or more application layers.
[0112] The server side 102 is used to obtain data storage spaces corresponding to one or more application layers; store the layer sequence corresponding to each application layer in the corresponding data storage space; and sort each application layer according to the layer sequence to obtain a layer display interface with a layer hierarchical relationship.
[0113] The application layer management system for the Yocto Project provided in this application is used. By applying to the server for data storage space corresponding to each application layer in the application, and storing the layer sequence of each application layer in the corresponding data storage space, the server can sort the application layers according to the layer sequence, thereby obtaining a layer display interface with a layer hierarchy. In this way, by introducing data storage space storing layer sequences on the server side, and sorting the layer hierarchy relationships between application layers according to the layer sequence, a layer display interface is formed, thereby providing layer management services to applications, facilitating layer management between different applications and different application layers, and thus making the implementation of the application interface more flexible.
[0114] The present application also provides an electronic device, comprising: a processor and a memory; the memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the electronic device performs the above method.
[0115] Figure 9 The following is a schematic diagram showing the structure of a computer system suitable for implementing an electronic device according to an embodiment of the present application. Figure 9 The computer system 900 of the electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0116] like Figure 9 As shown, the computer system 900 includes a central processing unit (CPU) 901, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 902 or the program loaded from the storage part 908 into the random access memory (RAM) 903, such as executing the method in the above embodiment. Various programs and data required for system operation are also stored in the RAM 903. The CPU 901, ROM 902 and RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0117] The following components are connected to the I / O interface 905: an input section 906 including a keyboard, a mouse, and the like; an output section 907 including devices such as a cathode ray tube (CRT), a liquid crystal display (LCD), and a speaker; a storage section 908 including a hard disk and the like; and a communication section 909 including a network interface card such as a LAN (Local Area Network) card or a modem. The communication section 909 performs communication processing via a network such as the Internet. A drive 910 is also connected to the I / O interface 905 as needed. Removable media 911, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, and the like, are installed in the drive 910 as needed, so that computer programs read therefrom can be installed into the storage section 908 as needed.
[0118] The electronic device disclosed in this embodiment includes a processor, a memory, a transceiver, and a communication interface. The memory and the communication interface are connected to the processor and the transceiver and complete communication with each other. The memory is used to store computer programs, the communication interface is used to communicate, and the processor and the transceiver are used to run the computer program, so that the electronic device executes each step of the above method.
[0119] The above description and the accompanying drawings sufficiently illustrate the embodiments of the present disclosure to enable those skilled in the art to practice them. Other embodiments may include structural, logical, electrical, process and other changes. The embodiments represent only possible variations. Unless expressly required, individual components and functions are optional, and the order of operations may vary. Parts and subsamples of some embodiments may be included in or replace parts and subsamples of other embodiments. Moreover, the terms used in this application are only used to describe the embodiments and are not used to limit the claims. As used in the description of the embodiments and claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to also include the plural forms. Similarly, the term "and / or" as used in this application refers to any and all possible combinations of one or more associated listings. In addition, when used in this application, the term "comprise" and its variations "comprises" and / or comprising refer to the presence of stated subsamples, wholes, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other subsamples, wholes, steps, operations, elements, components and / or groups of these. In the absence of further restrictions, an element defined by the statement "comprises a..." does not exclude the presence of other identical elements in the process, method or device that includes the element. In this article, each embodiment may focus on the differences from other embodiments, and the same and similar parts between the various embodiments can be referenced to each other. For the methods, products, etc. disclosed in the embodiments, if they correspond to the method part disclosed in the embodiments, then the relevant parts can be found in the description of the method part.
[0120] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software may depend on the specific application and design constraints of the technical solution. Technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application. Technicians can clearly understand that for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0121] In the embodiments disclosed herein, the disclosed methods and products (including but not limited to devices, equipment, etc.) can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of units can be merely a logical functional division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some sub-samples can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between each other shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, and can be electrical, mechanical or other forms. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to implement this embodiment. In addition, the functional units in this application may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0122] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of the systems, methods, and computer program products of the present application. In this regard, each block in a flowchart or block diagram may represent a module, program segment, or portion of code, which contains one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions marked in the blocks may occur in an order different from that marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, or they may sometimes be executed in the opposite order, depending on the functions involved. In the descriptions corresponding to the flowcharts and block diagrams in the accompanying drawings, the operations or steps corresponding to different blocks may also occur in an order different from that disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps may actually be executed substantially in parallel, or they may sometimes be executed in the opposite order, depending on the functions involved. Each block in the block diagram and / or flowchart, as well as combinations of blocks in the block diagram and / or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or action, or may be implemented using a combination of dedicated hardware and computer instructions.< / buffer>
Claims
1. A method for managing application layers in a Yocto project, characterized in that: An application program in the Yocto Project, wherein the application program is connected to a server, and the method includes: Get the layer order corresponding to one or more application layers; Apply to the server side for data storage space corresponding to each of the application layers, and store the order of each layer in the corresponding data storage space, wherein the server side is used to sort the application layers according to the order of the layers to obtain a layer display interface with a layer hierarchical relationship.
2. The method according to claim 1, characterized in that The applications include: An interface process for managing layer data corresponding to each of the application layers, wherein the layer data includes at least one of a layer sequence, pixel data, a storage identifier, and initialization data, and the initialization data includes at least one of layer coordinates, layer height, layer width, and layer transparency; An interface client is connected to the server, and is used to generate a layer display interface based on the layer data using the server, and to filter the feedback data sent by the server to the interface client, so as to send the filtered feedback data to the interface process.
3. The method according to claim 2, characterized in that The interface client applies to the server for the data storage space corresponding to each application layer in the following manner: Sending the initialization data corresponding to any application layer to the server, wherein the server is used to obtain the storage identifier corresponding to the application layer and the data storage space corresponding to the storage identifier, so as to store the initialization data corresponding to the application layer in the corresponding data storage space, and feedback the storage identifier and / or storage allocation result; Receive the storage identifier and / or the storage allocation result, and send the received storage identifier to the interface process.
4. The method according to claim 3, characterized in that The method further comprises: Obtaining a cache handle corresponding to the application layer from the server using the interface client, wherein the cache handle points to pixel data of the application layer in the data storage space; Using the interface process to draw pixel data of the application layer in the data storage space according to the cache handle, and generating drawing position information corresponding to a drawing area; The interface client is used to send the drawing position information and the storage identifier corresponding to the drawing position information to the server side, wherein the server side is used to extract the data to be rendered from the corresponding data storage space according to the storage identifier corresponding to the drawing position information, so as to perform layer rendering according to the corresponding drawing position information based on the extracted data to be rendered to obtain an application layer, wherein the data to be rendered includes initialization data and / or pixel data.
5. The method according to claim 3, characterized in that The method further comprises: Acquire a layer to be released, wherein the layer to be released includes any application layer; The interface client sends the storage identifier corresponding to the layer to be released to the server side, wherein the server side is used to delete the data storage space corresponding to the layer to be released from each data storage space according to the storage identifier corresponding to the layer to be released.
6. The method according to any one of claims 2 to 5, characterized in that The interface client is also used to: Obtaining the connection waiting time and sending a connection request to the server to establish a data link between the interface client and the server; If the connection waiting time falls within the preset target value, after the interface client receives the connection result fed back by the server based on the connection request, it applies to the server for data storage space corresponding to each application layer; If the connection waiting time does not fall within the preset target value, after the interface client receives the connection result based on the connection request feedback from the server, it waits according to the connection waiting time, and then applies to the server for the data storage space corresponding to each application layer.
7. A method for managing application layers in a Yocto project, characterized in that: Applied to a server side, the server side being connected to an application in the Yocto Project, the method includes: Get the data storage space corresponding to one or more application layers; storing the layer sequences corresponding to the respective application layers in the corresponding data storage spaces; The application layers are sorted according to the layer sequence to obtain a layer display interface with a layer hierarchical relationship.
8. The method according to claim 7, characterized in that The application layers are sorted according to the layer sequence to obtain a layer display interface with a layer hierarchy, including: The data storage space also stores data to be rendered; Obtaining a queue to be rendered, and querying the queue to be rendered according to a preset query cycle; If the drawing position information corresponding to any application layer and the storage identifier corresponding to the drawing position information are obtained, the drawing position information and the storage identifier corresponding to the drawing position information are stored in the queue to be rendered; If it is found that there is a queue to be rendered and a storage identifier in the queue to be rendered, a copy queue corresponding to the queue to be rendered is generated, and the queue to be rendered is cleared; According to the storage identifier in the amplitude queue, the layer order and the data to be rendered are extracted from the corresponding data storage space, and the layer rendering is performed according to the corresponding drawing position information of the data to be rendered to obtain the application layer, and the application layer is combined with the current layer display interface according to the layer order to obtain a new layer display interface.
9. An application layer management system for the Yocto Project, characterized in that: include: An application in the Yocto project is connected to a server, and is used to obtain a layer sequence corresponding to one or more application layers; The server is used to obtain data storage space corresponding to one or more application layers; storing the layer sequences corresponding to the respective application layers in the corresponding data storage spaces; The application layers are sorted according to the layer sequence to obtain a layer display interface with a layer hierarchical relationship.
10. An electronic device, characterized in that: include: processor and memory; The memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the electronic device performs the method according to any one of claims 1 to 6.