Map rendering engine library operation method and device, equipment, medium and product
By decoupling the map rendering engine library and the state management library, and adopting a unified data format and componentization, the high coupling problem between the Web map rendering engine and the application is solved, thereby improving the maintainability and scalability of the system and making it suitable for low-code development platforms.
Patent Information
- Application Number
- CN202511520551.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-23
- Publication Date
- 2026-01-23
AI Technical Summary
Existing web map rendering engines are highly coupled with applications, resulting in high maintenance costs and poor scalability. Developers need to master multi-platform GIS basics, leading to a steep learning curve.
By employing a map rendering engine library and using a state management library to parse user operations and broadcast states, the operation of the map library is decoupled from the application. A unified data format and component-based design are adopted to reduce coupling and improve maintainability.
It reduces the coupling between the map rendering engine and the application, improves the maintainability and scalability of the system, simplifies the development process, is suitable for low-code development platforms, and supports cross-platform compatibility and functional expansion.
Smart Images

Figure CN121387591A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and in particular to methods, apparatus, devices, media, and products for operating map rendering engine libraries. Background Technology
[0002] A map rendering engine is a core technological component that transforms geospatial data into visualized map images. Taking a World Wide Web (Web) map rendering engine as an example, a Web map rendering engine is a software tool specifically designed to create and display interactive maps on web pages.
[0003] Existing web map rendering engines control and render maps by directly calling the interface functions of instance objects. While this approach meets basic needs, as applications become more complex, the map rendering engine, as the core of the application, needs to be referenced in many functional modules. This coupling of each module with the map rendering engine increases maintenance costs. Summary of the Invention
[0004] This invention provides methods, apparatus, devices, media, and products for operating a map rendering engine library, thereby reducing the coupling between applications and the map rendering engine.
[0005] According to one aspect of the present invention, an operation method for a map rendering engine library is provided, applied to the map rendering engine library, the map rendering engine library including a state management library, the method comprising:
[0006] After the internal component detects a change in the first state of the receiving type in the state management library, it parses the first data content corresponding to the first state and operates the map library based on the parsing result. The change in the first state is associated with whether the application function component is operated by the user. The application function component is a component associated with the map function in the application. The data format of the first state is a set first data format.
[0007] In response to operations on the map rendering engine library, a second state is submitted to the state management library according to a set second data format. The type of the second state includes broadcast type. The second state is used for the application to parse and execute the corresponding function.
[0008] According to another aspect of the present invention, a method for operating a map rendering engine library is provided, applied to an application, the method comprising:
[0009] In response to user operations on the application, a first state is submitted to the state management library according to a first data format, and the content displayed by the application is updated. The state management library is integrated into the map rendering engine library, and the content is associated with the operations of the map library in the map rendering engine library.
[0010] After detecting the second state of the broadcast type, the second data content corresponding to the second state is parsed, and the function corresponding to the second data content is executed.
[0011] According to another aspect of the present invention, an operating device for a map rendering engine library is provided, comprising:
[0012] The parsing module is used to parse the first data content corresponding to the first state after the internal component listens for the change of the first state of the receiving type in the state management library, and operate the map library based on the parsing result. The change of the first state is associated with whether the application function component is operated by the user. The application function component is a component associated with the map function in the application. The data format of the first state is a set first data format.
[0013] The response module is used to respond to operations on the map rendering engine library by submitting a second state to the state management library according to a set second data format. The type of the second state includes broadcast type. The second state is used for the application to parse and execute the corresponding function.
[0014] According to another aspect of the present invention, an operating device for a map rendering engine library is provided, comprising:
[0015] The response module is used to respond to user operations on the application, submit a first state to the state management library according to a first data format, and update the content displayed by the application. The state management library is integrated into the map rendering engine library, and the content is associated with the operations of the map library in the map rendering engine library.
[0016] The parsing module is used to parse the second data content corresponding to the second state after listening to the second state of the broadcast type, and execute the function corresponding to the second data content.
[0017] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:
[0018] At least one processor; and
[0019] A memory communicatively connected to the at least one processor; wherein,
[0020] The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the method described in any embodiment of the present invention.
[0021] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the method described in any embodiment of the present invention.
[0022] According to another aspect of the present invention, a computer program product is provided, the computer program product comprising a computer program that, when executed by a processor, implements the method described in any embodiment of the present invention.
[0023] The technical solution of this invention, through the internal components of the map rendering engine library, detects a change in the first state, parses the first data content, and operates the map library to achieve data-driven operation. The map library is operated after the first state change. Upon detecting an operation on the map rendering engine library, a second state can be submitted to the state management library according to a second data format to trigger the application to parse and execute the response function. In this invention, the map rendering engine library and the application are driven based on states managed by the state management library, reducing the coupling between the map rendering engine library and the application and improving maintainability.
[0024] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description
[0025] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0026] Figure 1 This is a flowchart illustrating an operation method for a map rendering engine library provided in an embodiment of the present invention;
[0027] Figure 2 This is a flowchart illustrating another method for operating a map rendering engine library provided in an embodiment of the present invention;
[0028] Figure 3 This is an interactive diagram of a map rendering engine library and application function components provided in an embodiment of the present invention;
[0029] Figure 4 This is a schematic diagram of the structure of an operation device for a map rendering engine library provided in an embodiment of the present invention;
[0030] Figure 5 This is a schematic diagram of the structure of an operation device for a map rendering engine library provided in an embodiment of the present invention;
[0031] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0032] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0033] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0034] Existing web map rendering engines control and render maps by directly calling interface functions of instance objects. While this approach meets basic needs, as application systems become more complex, the map rendering engine becomes highly coupled with business logic, leading to increased maintenance costs and poor scalability. Furthermore, the interfaces of different Geographic Information System (GIS) platforms differ, requiring developers to master the fundamental GIS knowledge and operational principles of each platform, resulting in a steep learning curve and increased development complexity.
[0035] To address the aforementioned technical problems, this invention provides an operation method for a map rendering engine library. In one embodiment, Figure 1This is a flowchart illustrating the operation method of a map rendering engine library provided in this embodiment of the invention. This embodiment is applicable to situations involving the operation of a map rendering engine. The map rendering engine can render a map to an application, which can then display the map and perform the required functions. It can achieve digital environmental monitoring to assist decision-making, such as monitoring changes in the source and destination of land types. For example, the application can be used through a dashboard and a digital decision-making screen. The dashboard assists in decision-making by overlaying, comparing, correlating, and deeply mining various types of information; the application can provide flexible and convenient data querying, data analysis, and data statistics, and can customize query, statistical, and analysis templates, providing application service capabilities for natural resource spatial data.
[0036] The method provided in this embodiment can be executed by an operating device of a map rendering engine library. This operating device can be implemented in hardware and / or software and can be configured in an electronic device. The electronic device can be a computer, personal digital assistant, mobile phone, etc. The map rendering engine can be a software library containing a map rendering engine, which provides a series of APIs and tools for integrating and manipulating maps in applications. For example, the map rendering engine library may include a map rendering engine and additional functions such as map interaction, layer management, spatial analysis, and map service access. These additional functions can be implemented by calling services provided by different platforms. The rendering engine can be the part of the library responsible for the actual map drawing.
[0037] like Figure 1 As shown, the method includes the following operations:
[0038] S110. After the internal component detects a change in the first state of the receiving type in the state management library, it parses the first data content corresponding to the first state and operates the map library based on the parsing result.
[0039] Internal components can be components provided by the map rendering engine library, which can monitor state. These internal components can monitor state changes in the state management library; the method of monitoring is not limited and can be achieved through properties provided by the state management library.
[0040] A state management library can be considered a library for managing state. It centrally stores and manages the state of all components within an application. State defines the structure of the application's state and can be considered an application data model. In this invention, the state management library can be used to manage the state of a map. By defining a standard data format, a unified standard for state management and updates can be ensured. The states in the state management library can have a standard data format, which can be based on the state type or implemented functionality. The state management library can be integrated into the map rendering engine library to enable state management capabilities. In the state management library, a state can be a large object storing all relevant data. When components or other parts of the application need this data, they retrieve it from this state object.
[0041] The state of this invention can be responsive; when the state changes, all components that depend on this state will automatically update.
[0042] In this invention, the state includes a first state and a second state. The first state can be considered as the state monitored by the map rendering engine. The second state can be the state monitored by the application.
[0043] The first state is of type "receive," and the second state is of type "broadcast." The "receive" type can be the type of state being monitored by the map rendering engine library. The "broadcast" type can be the type of state being monitored by the application.
[0044] In this context, the state under the receive type can be an operation or action performed in response to a change in the broadcast type. The state under the receive type can be used to change the internal state or configuration of the application. The state of the broadcast type can be accessed and triggered by any component or module in the application. The state of the broadcast type can be related to direct user interaction.
[0045] The first state of the receiving type includes, but is not limited to, one or more of the following: adding layers to the map; setting the order of layers; adding overlays (such as pop-ups or information boxes) to the map; adding markers to the map; enabling the map's measurement function; enabling the map's drawing function.
[0046] The first data content corresponding to the first state can be the data content corresponding to the first state. The second data content corresponding to the second state can be considered as the data content corresponding to the second state. The data content can be a specific data item of the state, that is, the specific data corresponding to the state. For example, if the state is "add layer", the data item must at least include a specific name. In this embodiment, the data content can come from user interaction, external API calls, or other internal state updates.
[0047] The second state of a broadcast type includes, but is not limited to, one or more of the following: the position of the mouse on the map; mouse click events (which can be used to add markers or perform other operations on the map); changes in the map's zoom level; adjustments to the visible area on the map; measurement operations on the map (such as distance or area measurements); and drawing operations on the map, such as drawing polygons or paths.
[0048] The parsing result can be considered the result obtained after parsing the initial data content. The parsing result may include operable instructions derived from parsing the initial data content, enabling manipulation of the map library. The map library can be a library that implements map rendering. Map libraries can be used to display maps on web pages and can be embedded in applications. Map libraries allow users to easily implement map functions in a browser, such as zooming, dragging, marking, and interaction. Map libraries can support a variety of map resources.
[0049] In this operation, the map rendering engine library's internal components listen for the first state of the receiving type in the state management library. After the first state changes, the map rendering engine library parses the first data content of the first state to convert it into operation instructions. The parsing result contains the operation instructions, which can be used to manipulate the map library in this operation.
[0050] In this embodiment, the change of the first state is associated with whether the application functional component is operated by the user. The application functional component is a component associated with the map function in the application. The application functional component can be part of the user interface, through which the user interacts with the map. The user can be an application user. The application functional component can submit the first state to a state management library for management and listen for changes in the state.
[0051] The data format of the first state is the set first data format.
[0052] In one example, when a user interacts with an application component (e.g., clicks a button, enters data, etc.), triggering a state change, the application component commits its state—that is, it submits the state change to the state management library. The method of submission is not limited and can be implemented using the methods provided by the state management library. Internal components of the map rendering engine library listen for state changes in the state management library. This can be achieved through properties provided by the state management library. When an internal component detects a state change, it parses these changes into specific operation instructions, such as zooming, panning, adding or removing layers from the map view. Based on the parsed operation instructions, the internal component calls the map library's API to execute the corresponding map operations. After the map library completes the map operations, the map view updates accordingly. Due to the map library's responsive data binding features, the map components on the application interface also automatically update to reflect these changes. After the map display on the user interface is updated, the user can see the changes to the map, such as view movement, zooming, or layer changes.
[0053] S120. In response to the operation on the map rendering engine library, the second state is submitted to the state management library according to the set second data format.
[0054] The second state can be of the broadcast type, and the second state is used for the application to parse and execute the corresponding function.
[0055] In this operation, the developer can manipulate the map rendering engine library. Upon detecting this operation, the map rendering engine responds by submitting a second state to the state management library according to a second data format. The second data format can be the data format of the second state. The second state can be a state associated with the operation, such as a state changed by the operation.
[0056] The method provided in this invention, after detecting a first state change through internal components of the map rendering engine library, parses the first data content and operates the map library, thus achieving data-driven operation. The map library is operated after the first state change. Upon detecting an operation on the map rendering engine library, a second state can be submitted to the state management library according to a second data format to trigger the application to parse and execute the response function. In this invention, the map rendering engine library and the application are driven based on states managed by the state management library, reducing the coupling between the map rendering engine library and the application and improving maintainability.
[0057] Based on the above embodiments, modified embodiments of the above embodiments are proposed. It should be noted that, in order to keep the description brief, only the differences from the above embodiments are described in the modified embodiments.
[0058] In one embodiment, the data format corresponding to the state managed by the state management library is associated with the type of the state, and the states managed by the state management library include the first state and the second state.
[0059] State types can be categorized based on the functions they perform. Different state types correspond to different data formats. This embodiment can define a specific data format for each state type, which can also serve as a standard data structure, facilitating unified state management.
[0060] In this embodiment, the map rendering engine library provides a unified data format, which can be JSON or a string. This allows developers to implement map functionality simply by configuring the data structure, without needing to delve into the complex concepts and underlying APIs of WebGIS. This data format can be converted to the format required by a specific platform via an adapter.
[0061] In one embodiment, the step of submitting a second state to the state management library in response to an operation on the map rendering engine library according to a set second data format includes:
[0062] In response to operations on the map rendering engine library, the changed second state is obtained through the callback function corresponding to the operation;
[0063] The second state is converted into a second data format and then submitted to the state management library.
[0064] In the map rendering engine library, various operations (such as zooming, panning, and clicking) have corresponding callback functions. These callback functions are triggered when the corresponding operation occurs. Within the callback function, the new state of the map, the second state, is obtained and converted into the data format required by the state management library, i.e., the second data format.
[0065] This embodiment can use the submission method provided by the state management library to submit the second state to the state management library.
[0066] In one embodiment, the map rendering engine library includes components divided by function, the components including the internal components and the setting components as plug-ins, the setting components implementing the extended functions of the map rendering engine library.
[0067] The map rendering engine library uses modular components for its various functionalities. Each component is responsible for a specific part of the functionality and can interact with other components to achieve functional decoupling. Each component can be developed, tested, and maintained independently without affecting other components.
[0068] Components can be those that enable functionality to be extended through a plugin mechanism. For example, extended functionality can be integrated as a plugin into a map rendering engine library.
[0069] In one embodiment, the map library is encapsulated based on a setting framework, the setting framework including a framework for building a user interface, the setting framework having responsive data binding characteristics.
[0070] A framework can be used to build a user interface. Encapsulating a map library based on this framework can be done by creating components that define the map library's state framework, allowing developers to easily implement map functionality using the map library. The encapsulation method is limited here. This embodiment can encapsulate the core functionality or all functionality of the map library into components.
[0071] Responsive data binding enables responsive updates to the map state. When a component's state changes, these changes are automatically tracked, and all components that depend on that state are updated. When data changes, the view updates automatically. By encapsulating the map library as a component, changes in the map's state can automatically trigger view updates. The state management library can be associated with a defined framework.
[0072] Figure 2 This is a flowchart illustrating another method for operating a map rendering engine library according to an embodiment of the present invention. This embodiment is applicable to situations involving the operation of a map rendering engine. The method can be executed by an operating device for the map rendering engine library, which can be implemented in hardware and / or software and can be configured in an electronic device. The electronic device can be a computer, personal digital assistant, mobile phone, or similar device. The electronic device executing this embodiment is similar to the device executing... Figure 1 The electronic devices in the corresponding embodiments may be the same or different. For example... Figure 2 As shown, the method includes the following operations:
[0073] S210. In response to the user's operation on the application, the first state is submitted to the state management library according to the first data format, and the content displayed by the application is updated.
[0074] The state management library is integrated into the map rendering engine library. The content is associated with the operations of the map library in the map rendering engine library, such as the content affected by the operation. This content can be the content displayed on the map in the application. The first data format is the data format associated with the type of the first state.
[0075] When a user interacts with the application (e.g., clicking on a map, zooming, dragging, etc.), these actions need to be captured, and the initial state affected by the action needs to be determined. The initial state is then submitted to the state management library according to a first data format.
[0076] After manipulating the map library in the map rendering engine library, the content displayed by the application can be updated synchronously based on the responsive data binding features of the map rendering engine library.
[0077] S220. After detecting the second state of the broadcast type, parse the second data content corresponding to the second state and execute the function corresponding to the second data content.
[0078] The second state can be a state triggered by operations on the map rendering engine library. After this operation detects the second state, it parses the second data content corresponding to the second state and executes the corresponding function.
[0079] The method provided in this embodiment drives the map rendering engine library and the application based on the state managed by the state management library, which reduces the coupling between the map rendering engine library and the application and improves maintainability.
[0080] The following is an exemplary description of the present invention. The operation method of the map rendering engine library provided by the present invention can also be called the control and response method of the data-driven Web map rendering engine. The map rendering engine library in the present invention is to encapsulate the map library based on a set framework, such as the Vue framework, and use a state management library to centrally manage and share the state in the application. For different operations, standard data structures are defined. The tool components share the data with the map rendering engine according to the standard data structures. The map rendering engine listens for changes in the data and responds to the operation.
[0081] The map rendering engine library in this invention hides function calls that require WebGIS expertise from the outside world. It converts commonly used capabilities into a set of data structures, defined using JSON or strings. When developers call it, they only need to pass in the data according to the specified data structure, and they do not need to be familiar with WebGIS expertise to develop.
[0082] In practical applications, it is common to connect to GIS services from multiple different platforms. Different services require different processing under the original operation, and it is necessary to clearly understand the application differences between different platforms, which greatly increases the difficulty of implementation. The map rendering engine in this invention implements the processing of the differences of GIS services on these different platforms. It provides a set of data structures and operations for the same operations on different platform services, which greatly simplifies the development difficulty of map engine application for developers.
[0083] The following describes the data-driven control and response mechanism:
[0084] This invention defines a standard data format, uses a data-driven model, and implements operations on the map engine library (also known as the map library) based on a state management library. It implements commonly used capabilities such as map view control, layer loading, layer attribute control, overlay layers, map measurement, map drawing, and map recognition, and unifies the data structure and operations for different GIS platforms.
[0085] Figure 3 This is a schematic diagram illustrating the interaction between a map rendering engine library and application functional components provided in an embodiment of the present invention. See also... Figure 3 The interaction process between the map rendering engine library and application functional components is as follows:
[0086] Register the state management library (i.e., State) defined in the code to the Vue instance. After the map rendering engine is initialized, the internal components start listening to the State of the Receiver class. At this time, the map rendering engine displays its initial state in the browser.
[0087] When an application component in the user's operating system submits its state (i.e., the first state) to the state management library, the map rendering engine's internal components detect the change in state (i.e., after the internal components detect the change in the first state of the receiving type in the state management library). They then begin parsing the submitted data content (i.e., the first data content), transforming it into different capabilities for manipulating the map library based on the different states and state data. The map library is then manipulated based on the parsing results.
[0088] When a user interacts with the map rendering engine, internal components implement callback functions for the map library under different operations, obtain data from the map rendering engine under various states in the map library, and convert these states into a structure defined by State. The internal components of the map rendering engine submit the State to the state management library (i.e., submit the second state to the state management library according to the set second data format). External application components that listen for Broadcast-type State listen to the changes in State (i.e., the second state), start parsing the data, and execute specific functional capabilities.
[0089] The map rendering engine library and the application listen for or submit state data, respectively.
[0090] The following describes the data format for the status:
[0091] The fields included in adding a layer (i.e., ADD_SERVICE) are:
[0092] Layer name: The identifier name of the layer, used to distinguish different layers.
[0093] Layer title: The display title of a layer, typically used in the user interface to show to the user.
[0094] Service provider object: refers to the object that provides layer data or services.
[0095] Output address: The service address for obtaining map images, which can be a URL pointing to a web map service.
[0096] Feature address: Provides the service address for retrieving geographic features, which can be a URL pointing to Web Feature Service (WFS).
[0097] Legend address: Provides the address of the layer legend. Legends are usually used to explain the meaning of different symbols on the map.
[0098] Bounding box: Used to define the geographic extent of a map layer.
[0099] Projection: A coordinate reference system used to define the geospatial data used by a map layer.
[0100] Setting layer opacity (SET_LAYER_OPACITY) includes the following fields: layer name and opacity.
[0101] Enabled measurement status (i.e., ENABLE_MEASURE) includes:
[0102] Cancel measurement status: This means no measurement is performed.
[0103] Distance Measurement Status: Used to measure the straight-line distance between two or more points.
[0104] Area measurement status: Used to measure the area of a polygonal region.
[0105] Enabling drawing state (ENABLE_DRAW) includes:
[0106] Cancel drawing state: That is, no drawing is performed.
[0107] Drawing polyline state: Used to draw straight lines or polylines.
[0108] Polygon drawing state: Used to draw polygonal regions.
[0109] Rectangle drawing state: Used to draw a rectangle.
[0110] Circle drawing state: Used to draw a circle.
[0111] Map view status (MAP_VIEW_STATE) includes:
[0112] Center point of the map: Defines the coordinates of the center point of the map.
[0113] Map zoom level: Defines the zoom level of the map.
[0114] The map rendering engine library in this invention provides great convenience for low-code development platforms through standardized data structures and data-driven patterns, enabling even developers without GIS expertise to easily implement complex map operation functions.
[0115] This invention simplifies the development process: developers no longer need to manually write cumbersome map operation logic; they only need to configure a standard JSON data structure, and the system will automatically execute the map rendering engine's operations based on the data. This significantly reduces the learning curve and is particularly suitable for applications in low-code development platforms.
[0116] This invention is highly scalable: even in a low-code environment, developers can extend existing map engine operations through custom tools or functions. The data-driven model in this invention allows developers to easily add new data types or map functionalities without modifying the engine's underlying code.
[0117] This invention introduces a unified layer data format into map rendering engines, breaking down the differences between various GIS platforms. This allows developers to load and manipulate map layers from different services using the same data format. By standardizing the layer format, developers no longer need to concern themselves with the technical details of the underlying platform, simplifying the development process.
[0118] This invention offers cross-platform compatibility: the system handles the differences between various GIS service platforms in a unified manner, allowing developers to load data from different sources using the same layer format without having to write separate interface code for each platform.
[0119] This invention simplifies operations: loading and manipulating map layers (such as adding, removing, and setting transparency) are all done through a standardized layer format. Developers only need to provide a unified data format, and the system will automatically adapt to GIS services on different platforms.
[0120] This invention optimizes state synchronization: to avoid performance bottlenecks caused by frequent state updates, it employs batch state commits and asynchronous processing mechanisms to reduce engine performance overhead. Specifically, batch state commits merge multiple state updates into a single commit, reducing the number of updates. This invention achieves batch state commits by collecting state updates over a certain period and then committing them all at once after a set time or duration. The asynchronous processing mechanism allows state updates and related operations to be performed without blocking the main thread, improving application responsiveness and performance.
[0121] This invention adopts a component-based design: the various functional modules within the map engine library (also known as the map rendering engine library) are highly decoupled, which facilitates expansion and maintenance, and developers can freely customize functional modules according to their needs.
[0122] This invention adopts a plug-in mechanism: it supports the expansion of new functions through plug-in mechanisms, such as introducing 3D rendering capabilities or integrating AI analysis modules to achieve automated map recognition and analysis.
[0123] The method provided by this invention achieves complete decoupling between the map rendering engine and application functions through data-driven and state management mechanisms, thereby improving the system's scalability and maintainability. It uniformly handles differences between different GIS platforms, simplifies developer operations, and lowers the technical threshold. This invention is adaptable to various application scenarios, supports functional expansion through plug-in and component-based design, and possesses excellent flexibility and scalability.
[0124] In one embodiment, Figure 4 This is a schematic diagram of the structure of an operating device for a map rendering engine library provided in an embodiment of the present invention. This device can be integrated into electronic devices, such as... Figure 4 As shown, the device includes:
[0125] The parsing module 410 is used to parse the first data content corresponding to the first state after the internal component listens for the change of the first state of the receiving type in the state management library, and operate the map library based on the parsing result. The change of the first state is associated with whether the application function component is operated by the user. The application function component is a component associated with the map function in the application. The data format of the first state is a set first data format.
[0126] The response module 420 is used to respond to the operation of the map rendering engine library and submit the second state to the state management library according to the set second data format. The type of the second state includes broadcast type. The second state is used for the application to parse and execute the corresponding function.
[0127] In one embodiment, the data format corresponding to the state managed by the state management library is associated with the type of the state, and the states managed by the state management library include the first state and the second state.
[0128] In one embodiment, the response module 420 is specifically used for:
[0129] In response to operations on the map rendering engine library, the changed second state is obtained through the callback function corresponding to the operation;
[0130] The second state is converted into a second data format and then submitted to the state management library.
[0131] In one embodiment, the map rendering engine library includes components divided by function. The components include the internal components and the setting components as plug-ins. The setting components implement the functions of extending the map rendering engine library.
[0132] In one embodiment, the map library is encapsulated based on a defined framework, the defined framework including a framework for building a user interface, the defined framework having responsive data binding features.
[0133] The operating device for the map rendering engine library provided in this embodiment of the invention can execute the invention. Figure 1 The operation method of the map rendering engine library provided in the corresponding embodiment has the corresponding functional modules and beneficial effects of the execution method.
[0134] In one embodiment, Figure 5 This is a schematic diagram of the structure of an operating device for a map rendering engine library provided in an embodiment of the present invention. This device can be integrated into an electronic device, such as... Figure 5 As shown, the device includes:
[0135] The response module 510 is used to respond to the user's operation on the application, submit the first state to the state management library according to the first data format, and update the content displayed by the application. The state management library is integrated in the map rendering engine library, and the content is associated with the operation of the map library in the map rendering engine library.
[0136] The parsing module 520 is used to parse the second data content corresponding to the second state after listening to the second state of the broadcast type, and execute the function corresponding to the second data content.
[0137] In one embodiment, the first data format is the data format associated with the type of the first state.
[0138] In one embodiment, Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention, such as... Figure 6 The diagram illustrates a schematic representation of an electronic device 10 that can be used to implement embodiments of the present invention. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.
[0139] like Figure 6 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., which is communicatively connected to the at least one processor 11. The memory stores a computer program that can be executed by the at least one processor 11, and the computer program is executed by the at least one processor 11 to enable the at least one processor 11 to perform the method provided by the present invention.
[0140] The processor 11 can perform various appropriate actions and processes based on a computer program stored in the read-only memory (ROM) 12 or a computer program loaded from the storage unit 18 into the random access memory (RAM) 13. The RAM 13 can also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0141] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0142] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, digital signal processors (DSPs), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as the methods provided in this invention.
[0143] In some embodiments, the methods provided herein may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the methods described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to execute the methods by any other suitable means (e.g., by means of firmware).
[0144] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard parts (ASSPs), systems-on-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0145] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0146] In the context of this invention, a computer-readable storage medium stores computer instructions that are used to cause a processor to execute and implement the method provided by this invention.
[0147] The present invention also provides a computer program product comprising a computer program that, when executed by a processor, implements the method provided according to embodiments of the present invention. A computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. The computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, the computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.
[0148] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0149] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or middleware components (e.g., application servers), or frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
[0150] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.
[0151] This invention also provides a computer program product, including a computer program that, when executed by a processor, can implement the methods provided in any embodiment of this application.
[0152] In the implementation of the computer program product, computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof. Programming languages include object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as C or similar languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0153] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.
[0154] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A method for operating a map rendering engine library, characterized in that, Applied to a map rendering engine library, which includes a state management library, the method includes: After the internal component detects a change in the first state of the receiving type in the state management library, it parses the first data content corresponding to the first state and operates the map library based on the parsing result. The change in the first state is associated with whether the application function component is operated by the user. The application function component is a component associated with the map function in the application. The data format of the first state is a set first data format. In response to operations on the map rendering engine library, a second state is submitted to the state management library according to a set second data format. The type of the second state includes broadcast type. The second state is used for the application to parse and execute the corresponding function.
2. The method according to claim 1, characterized in that, The data format corresponding to the state managed by the state management library is associated with the type of the state, and the states managed by the state management library include the first state and the second state.
3. The method according to claim 1, characterized in that, The step of responding to an operation on the map rendering engine library by submitting a second state to the state management library according to a set second data format includes: In response to operations on the map rendering engine library, the changed second state is obtained through the callback function corresponding to the operation; The second state is converted into a second data format and then submitted to the state management library.
4. The method according to claim 1, characterized in that, The map rendering engine library includes components divided by function. The components include internal components and setting components as plugins. The setting components implement the functions of extending the map rendering engine library.
5. The method according to claim 1, characterized in that, The map library is encapsulated based on a defined framework, which includes a framework for building the user interface and has responsive data binding features.
6. A method for operating a map rendering engine library, characterized in that, Applied to an application, the method includes: In response to user operations on the application, a first state is submitted to the state management library according to a first data format, and the content displayed by the application is updated. The state management library is integrated into the map rendering engine library, and the content is associated with the operations of the map library in the map rendering engine library. After detecting the second state of the broadcast type, the second data content corresponding to the second state is parsed, and the function corresponding to the second data content is executed.
7. The method according to claim 6, characterized in that, The first data format is the data format associated with the type of the first state.
8. An operating device for a map rendering engine library, characterized in that, include: The parsing module is used to parse the first data content corresponding to the first state after the internal component listens for the change of the first state of the receiving type in the state management library, and operate the map library based on the parsing result. The change of the first state is associated with whether the application function component is operated by the user. The application function component is a component associated with the map function in the application. The data format of the first state is a set first data format. The response module is used to respond to operations on the map rendering engine library by submitting a second state to the state management library according to a set second data format. The type of the second state includes broadcast type. The second state is used for the application to parse and execute the corresponding function.
9. An operating device for a map rendering engine library, characterized in that, include: The response module is used to respond to user operations on the application, submit a first state to the state management library according to a first data format, and update the content displayed by the application. The state management library is integrated into the map rendering engine library, and the content is associated with the operations of the map library in the map rendering engine library. The parsing module is used to parse the second data content corresponding to the second state after listening to the second state of the broadcast type, and execute the function corresponding to the second data content.
10. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-7.
11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the method of any one of claims 1-7.
12. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, implements the method according to any one of claims 1-7.