An information display method, device, storage medium, and electronic device
By employing adaptive scaling technology and database collaborative processing, the problem of poor flexibility in map display was solved, enabling automated map interaction and efficient querying.
Patent Information
- Application Number
- CN202510213381.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-25
- Publication Date
- 2026-08-25
AI Technical Summary
The existing map display process lacks flexibility, requiring users to manually adjust the map page to display the query results.
By using adaptive scaling technology, the map page scale is automatically adjusted based on the query results, and visible objects are marked on the scaled map page. This, combined with Elasticsearch database and cached database, improves query efficiency.
It enables automated interaction between users and the map page, improves the flexibility of information retrieval, reduces manual user operations, and enhances query efficiency.
Smart Images

Figure CN122633765A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of information processing technology, and in particular to an information display method, apparatus, storage medium, and electronic device. Background Technology
[0002] With the continuous development of electronic map technology, information retrieval through electronic maps has become a common operation for a large number of users. Displaying the query results on electronic maps provides users with information convenience.
[0003] In the process of realizing this invention, it was found that at least the following technical problems exist in the prior art: the current map display process has the problem of poor flexibility. Summary of the Invention
[0004] This invention provides an information display method, apparatus, storage medium, and electronic device to improve the flexibility of map display.
[0005] According to one aspect of the present invention, an information display method is provided, comprising:
[0006] Display a map page, which is a map page with the location information as the center point and a first scale;
[0007] In response to a query operation, the query results are obtained, a second scale of the map page is determined based on the display range corresponding to the query results, the map page is scaled based on the second scale, and the visible objects corresponding to the query results are marked on the scaled map page.
[0008] The query request corresponding to the query operation includes query conditions; the query result corresponding to the object query operation is the sub-query information of visible objects that meet the query conditions; the display range corresponding to the query result is the range centered on the location information and including the visible objects.
[0009] Optionally, determining the second scale of the map page based on the display range corresponding to the query result includes: obtaining first size information of the device screen, and determining second size information of the display range based on the edge information of the display range corresponding to the query result; and determining the second scale based on the first size information and the second size information.
[0010] Optionally, the method further includes: during the display of the map page, in response to a transformation operation on the map page, updating the display range, updating the map page based on the updated display range, obtaining newly visible objects within the updated display range, and marking the newly visible objects in the updated map page.
[0011] Optionally, obtaining the query results includes: querying the ES database based on the query request corresponding to the query operation to obtain the identifier of the visible object and the first information of the visible object; querying the cache database based on the identifier of the visible object to obtain the second information of the visible object; generating a sub-query result of the visible object based on the first information and the second information of the visible object, wherein at least one sub-query result of the visible object forms the query result.
[0012] Optionally, the data content of the ES database and the cache database are obtained from a relational database, which includes data content of multiple objects.
[0013] When the data content of any object is updated, the relational database synchronizes the first part of the object's data content to the ES database via Kafka messages; deletes the stored data corresponding to the object in the cache database, reads the second part of the object's data content from the relational database, and caches it in the cache database.
[0014] Optionally, the method further includes: generating abnormal log information in the event of Kafka message synchronization failure; periodically scanning the abnormal log information and synchronizing the data content in the abnormal log information to the ES database.
[0015] According to another aspect of the present invention, an information display device is provided, comprising:
[0016] The first display module is used to display a map page, which is a map page with the location information as the center point and a first scale.
[0017] The second display module is used to respond to a query operation, obtain query results, determine a second scale of the map page based on the display range corresponding to the query results, scale the map page based on the second scale, and mark the visible objects corresponding to the query results in the scaled map page.
[0018] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:
[0019] At least one processor; and
[0020] A memory communicatively connected to the at least one processor; wherein,
[0021] 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 information display method according to any embodiment of the present invention.
[0022] 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 information display method described in any embodiment of the present invention.
[0023] The technical solution of this invention, when a user performs a query, adaptively scales the map page according to the query results and marks the visible objects corresponding to the query results on the scaled map page. This achieves automated interaction between the user and the map page, avoids the need for the user to manually adjust the map page to display the query results, and improves the flexibility of information querying on the map page.
[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 of an information display method provided in an embodiment of the present invention;
[0027] Figure 2 A schematic diagram of a device screen provided in an embodiment of the present invention;
[0028] Figure 3 This is a flowchart illustrating the calculation process of the scale provided in an embodiment of the present invention;
[0029] Figure 4 This is a schematic diagram of the structure of an information display device provided in an embodiment of the present invention;
[0030] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0031] 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.
[0032] 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.
[0033] Figure 1 This is a flowchart of an information display method provided by an embodiment of the present invention. This embodiment is applicable to the process of map display, where the scale is adaptively adjusted and the map page is automatically scaled to display visible objects on the map page, reducing the need for manual operation by the user. This method can be executed by an information display device, which can be implemented in hardware and / or software, and can be configured in a mobile terminal such as a mobile phone or tablet computer. Figure 1 As shown, the method includes:
[0034] S110. Display a map page, wherein the map page is a map page with the location information as the center point and a first scale.
[0035] S120. In response to the query operation, obtain the query result, determine the second scale of the map page based on the display range corresponding to the query result, scale the map page based on the second scale, and mark the visible objects corresponding to the query result in the scaled map page.
[0036] Optionally, in response to the application launch operation of the electronic map, a map page is displayed. Optionally, in the information display page, in response to the map switching operation, a map page is displayed. The information display page can be the display page of an information query application, used to query and display information about objects, such as tradable objects or merchants conducting transactions. The map page can be the initial page for entering the electronic map application, and this initial page can be a map page with a preset first scale centered on the location information. Specifically, the user's location information is obtained, for example, through a location application configured within the electronic device (for example, a GPS system). It is understood that if the electronic device's location system is not enabled, i.e., the user's location information cannot be obtained, the default location information sent by the electronic map server is received, and this default location information is used as the center point of the initial page. This default location information can be set based on the user's country or city, which can be pre-configured. The first scale here can be a pre-stored setting in the electronic map application.
[0037] Optionally, the map page can also be a map page displayed after a query, such as a map page obtained from a previous query request. This map page can be a map page automatically scaled from the initial page, or a map page formed after manually scaling or rotating the screen from the initial page. There are no limitations here. Correspondingly, the first scale of the map page can be a transformed scale. Here, the scale is the ratio between the distance on the map page and the actual distance in the map data. For example, it could be 1cm:500m, meaning that 1cm on the map page represents 500m in the actual distance of the map data.
[0038] The map page can include a query control, allowing users to input queries. This query control can be an input control that retrieves query criteria and generates a query request based on those criteria. Alternatively, the query control can include multiple tag selection controls. Clicking these controls selects a tag, which is then used as the query criteria to generate the query request. The query request is then sent to a server, which responds and provides the corresponding query results. Alternatively, the query can be used to search a pre-defined database to obtain the query results.
[0039] Optionally, the query request corresponding to the query operation includes query conditions. These query conditions may include one or more of the following: object attribute conditions and query scope conditions. Object attribute conditions may include object attribute information such as the name or type of the queried object. For example, query conditions may be "xx building," "xx shopping mall," "bank," or "grocery store," etc. Query scope conditions may include attribute information used to limit the query scope, such as query scope data or query scope description information. For example, query scope data may be five kilometers or ten kilometers, and the query scope description information may be descriptive information such as streets, administrative districts, or descriptive information such as business district names. Query conditions may include object attribute conditions and query scope conditions. For example, query conditions may be "5 kilometers" and "xx bank," etc.
[0040] Based on the above query conditions, query processing is performed to determine visible objects that meet these conditions. Visible objects can be understood as objects marked on a map page and displayed to the user. The query results corresponding to the object query operation are the sub-query information of the visible objects. The sub-query information of visible objects may include, but is not limited to, the name, identifier (e.g., object ID), location information (e.g., latitude and longitude), description information, and hotspot information of the visible objects. Taking a shopping mall as an example, hotspot information may be mall activity information or promotional information. Taking a merchant as an example, hotspot information may be one or more of the merchant's package information, new product information, and promotional information.
[0041] Optionally, visible objects that meet the query conditions can be identified as the visible objects corresponding to the query results.
[0042] The display area corresponding to the query results is the area displayed on the map page. The query results can be in the form of a set of visible objects, and multiple visible objects in the set are located within the aforementioned display area. Optionally, the display area corresponding to the query results can be a range centered on the location information and including the visible objects; wherein, there can be multiple visible objects, and correspondingly, the display area corresponding to the query results can include at least one visible object.
[0043] Understandably, different display areas correspond to different visibility levels; the larger the display area, the higher the visibility level. The visibility level of each object is preset. If an object's visibility level is equal to or higher than the visibility level corresponding to the display area, then the object is visible within that display area and is identified as a visible object within the display area. If an object's visibility level is lower than the visibility level corresponding to the display area, then the object is not visible within that display area and is identified as an invisible object within the display area. Based on the visible objects matched through query conditions, the matched visible objects are filtered according to the visibility level of the display area, retaining only those that meet the visibility level of the display area.
[0044] The display area corresponding to the query results can be a rectangular area that matches the shape of the device screen. Specifically, the aspect ratio of the display area corresponding to the query results can be the same as the aspect ratio of the device screen. To better display the query results, the display area corresponding to the query results should at least include the query results mentioned above. For example, the display area can be determined based on the location information of visible objects in the query results, the edge information of the display area can be determined based on the location information of visible objects in the query results, and the display area can be determined based on the edge information. In this case, the distance between the location information of the visible objects and the center point is less than the distance between the edge of the display area and the center point. Optionally, the distance between the edge of the display area and the center point can be determined based on the distance between the location information of the visible objects and the center point and a preset range expansion distance. Further, the edge information of the display area can be determined.
[0045] For example, the display range can be determined based on the edge information of the query range. Specifically, the edge information of the display range can be determined based on the edge information of the query range and the preset range extension distance to ensure that the display range includes the query range and fully displays the query range on the map page.
[0046] Since the display range of the query results may differ from the display range of the map page before the query, the display range of the map page is automatically adjusted to better display the query results. This enables adaptive scaling of the map page, improves the flexibility of map page adjustment, and eliminates the need for manual operation, thus simplifying the interaction process of the map page.
[0047] Specifically, the map page is zoomed in and out using the map's scale bar. A second scale bar is determined based on the display area corresponding to the query results. If the second scale bar differs from the first scale bar, the map page is zoomed in and out based on the second scale bar to ensure that the display area of the zoomed map page matches the display area corresponding to the query results. The second scale bar can be determined based on the ratio of the actual area of the device screen to the display area corresponding to the query results. Both the actual area of the device screen and the display area corresponding to the query results can be represented by feature edges, which can be any side or a diagonal.
[0048] Optionally, determining the second scale of the map page based on the display area corresponding to the query result includes: obtaining first size information of the device screen, and determining second size information of the display area based on the edge information of the display area corresponding to the query result; and determining the second scale based on the first size information and the second size information.
[0049] The first size information of the device screen is its physical size, which can be the size information of the characteristic edges of the device screen. The second size information of the display area is the actual distance information of the display area in real space, which can also be the size information of the characteristic edges of the display area. For example, the characteristic edges here can be the long side or the wide side. The size information of the long side or the wide side of the device screen can be obtained from the factory configuration file. The size information of the long side or the wide side of the display area can be calculated based on the edge information of the display area. For example, reading the vertex coordinate information of the corresponding edge information of the long side or the wide side, and calculating the distance based on the vertex coordinate information, yields the size information of the long side or the wide side of the display area. For example, the characteristic edges here can be diagonals. For example, the size information of the diagonals of the device screen can be calculated based on the long side and the wide side of the device screen. The size information of the diagonals of the display area can be calculated based on the edge information of the display area. The edge information of the display area can be the edge coordinate information of the display area. For example, the edge information of the display area can be the vertex coordinate information of the edge of a rectangular display area, such as the coordinates of the top-left corner and the bottom-right corner of the display area, or the coordinates of the top-right corner and the bottom-left corner of the display area. The diagonal dimensions of the display area can be determined by the distance between the top-left and bottom-right corner coordinates, or by the distance between the top-right and bottom-left corner coordinates.
[0050] For example, see Figure 2 and Figure 3 , Figure 2This is a schematic diagram of a device screen provided in an embodiment of the present invention. The long side of the device screen is a, the wide side is b, and correspondingly, the square of the diagonal C of the device screen is equal to the sum of the squares of a and b. Figure 3 This is a flowchart illustrating the calculation process of the scale provided in this embodiment of the invention. The diagonal distance of the display area is obtained by calculating the distance between the coordinates of the upper left and lower right corners of the display area. The second scale is determined by the ratio of the diagonal C of the device screen to the diagonal distance of the display area.
[0051] Understandably, the feature edges used to calculate the second scale are not limited to diagonals. For example, they can also be determined based on the ratio between the distance r1 between the center point and any side and the distance r2 between the coordinates of the center point of the display area and the edge of the display area.
[0052] If the second scale is larger than the first scale, the map page is zoomed in until the map page's scale reaches the second scale; if the second scale is smaller than the first scale, the map page is zoomed out until the map page's scale reaches the second scale. During the zooming process, the center point of the map page serves as the location information.
[0053] Mark the visible objects corresponding to the query results on the zoomed map page. Specifically, determine the coordinate position of the visible objects in the map data based on the location information of the visible objects and the second scale. Set the marker of the visible objects based on the coordinate position of the visible objects in the map data. The marker can be a graphic marker and / or a text marker. The graphic marker can be a circular marker, and the text marker can be the identifier or name of the visible object, etc.
[0054] Building upon the above embodiments, the query results also include the distance between visible objects and the user's location information. Visible objects can be marked on the map page based on this distance, for example, by adding the distance value between the visible object and the user's location information to the graphic marker of the visible object. Alternatively, multiple visible objects can be sorted based on their distance to the user's location information, and then displayed to the user based on this sorting.
[0055] In this embodiment, when a user performs a query, the map page is adaptively scaled based on the query results, and the visible objects corresponding to the query results are marked on the scaled map page. This achieves automated interaction between the user and the map page, avoids the need for the user to manually adjust the map page to display the query results, and improves the flexibility of information retrieval on the map page.
[0056] Based on the above embodiments, during the display of the map page (e.g., the map page before zooming or the map page after zooming), in response to the transformation operation of the map page, the display range is updated, the map page is updated based on the updated display range, newly visible objects within the updated display range are obtained, and the newly visible objects are marked in the updated map page.
[0057] The transformation operations on the map page may include, but are not limited to, rotating the device screen, dragging on the map page, and zooming. In response to the aforementioned transformation operations on the map page, if the display area of the map page changes, the updated display area is redefined. If the scale of the updated display area changes (e.g., due to a zooming operation), a third scale for the updated display area is determined, and the map page is zoomed based on this third scale to update the map page. If the scale of the updated display area does not change, the map data and visible objects corresponding to the map page are updated.
[0058] Specifically, based on the updated display area, visible objects are re-queried. These newly retrieved visible objects are compared with locally cached visible objects (visible objects queried before the change operation, cached locally) to determine newly added and deleted visible objects within the display area. Deleted visible objects are locally cached objects that are not visible within the updated display area. Newly added visible objects are those queried based on the updated display area that are not cached locally. Deleted visible objects are removed from the map data, and newly added visible objects are marked.
[0059] Based on the above embodiments, in response to a query operation, the query request corresponding to the query operation is matched in the database to determine the query result corresponding to the query operation. Currently, object information is generally stored in relational databases, such as MySQL databases. However, relational databases suffer from poor query performance when processing large-scale geographic location data, easily leading to query delays and low query efficiency.
[0060] To address the aforementioned technical issues, this application utilizes a relational database to store the original data of objects, specifically the data content of multiple objects within the relational database. This original data can be underlying, structured data comprising multiple tables representing the objects. Based on this, a first portion of the original data from the relational database is synchronized to an Elasticsearch (ES) database, and a second portion is synchronized to a cache database. This leverages the in-memory computation capabilities of the ES database and the inverted index's in-memory operations to efficiently and quickly handle complex search requirements. Furthermore, the collaborative processing between the cache database (e.g., Redis) and the ES database enhances query performance.
[0061] The data content in the Elasticsearch (ES) database and the cache database are respectively synchronized from the relational database. When the data content of any object is updated, the relational database synchronizes the first part of the object's data content to the ES database via Kafka messages.
[0062] Relational databases store data content for multiple objects. When the data content of any object changes, a Kafka message is generated based on the changed object's data content. Specifically, a Kafka message is generated and sent based on the first part of the changed object's data content. This first part of the data content can contain pre-defined fields, which may include fields from common query conditions and frequently used fields to be displayed to the user. For example, the fields in the first part of the data content may include, but are not limited to, object identifier, object city, object name, object address, object visibility level, and object type.
[0063] A distributed scheduling platform (such as an XXL-JOB platform or an Elasticjob platform) listens for Kafka messages. Upon receiving a Kafka message, it converts the Kafka message into the data format required by the Elasticsearch database and uploads it to the Elasticsearch database. During the data synchronization process from Kafka messages to the Elasticsearch database, if Kafka message sending fails, an exception log message is generated; if uploading to the Elasticsearch database fails after receiving a Kafka message, an exception log message is generated.
[0064] In the event of a Kafka message synchronization failure, the distributed scheduling platform generates an exception log. It periodically scans this log and synchronizes the data from it to the Elasticsearch (ES) database. This re-scanning and synchronization of the exception log improves the comprehensiveness and accuracy of data synchronization, preventing inconsistencies and update delays caused by the synchronization mechanism. This is especially crucial when object data is frequently updated, ensuring timely updates to the ES database.
[0065] The scanning interval for abnormal log information can be 1 minute, 10 minutes, 1 hour, or 1 day, depending on the requirement for synchronous updates. The Kafka messages in the abnormal log information are parsed, and Kafka messages that failed to synchronize are reprocessed. If data synchronization still cannot be achieved after scanning the abnormal log information, the abnormal log information is processed based on compensation configuration rules. These rules can include the number of retries for scanning the abnormal log information. When the number of retries is reached, a prompt message is generated and sent to a manual processing device, for example, via an alert email, to ensure successful data synchronization.
[0066] Optionally, the Elasticsearch database includes a city information index and an object information index. The city information index stores a list of city information, including basic city information and geographical boundaries. Users can query the city they belong to based on their location coordinates. Specifically, the city information index includes, but is not limited to, city identifier, city name, parent city code, city geographical boundary information, city latitude and longitude information, and city level.
[0067] The object information index stores a collection of object information, including detailed object information and geographic coordinates. For query conditions corresponding to a query operation, paginated queries are performed in the object information index to retrieve visible objects that match the query criteria. Furthermore, distance calculations and sorting can be performed based on the geographic location of visible objects. The object information index includes, but is not limited to, object identifier, object name, city, object address, object visibility level, object coordinates, and object type.
[0068] Correspondingly, the query request for the query operation is a query-bool-filter statement, where query represents the query request, bool allows multiple query conditions, and filter is a filter clause used to filter documents.
[0069] Optionally, the synchronization method for the cache database is as follows: when the data content of any object in the relational database changes, delete the stored data corresponding to that object in the cache database, read the second part of the object's data content from the relational database, and cache it in the cache database. To prevent cache deletion from failing after a successful update to the relational database, the operations of updating the relational database and deleting the stored data in the cache database can be placed in the same database transaction and rolled back. Alternatively, failures to delete data from Redis can be recorded for retries.
[0070] During the data query process from the cache database, it is determined whether the cache database contains the cached data to be read. If it exists, the data is read from the cache database; otherwise, the second part of the object's data content is read from the relational database and cached in the cache database. The second part of the data content in the cache database and the first part of the data content in the Elasticsearch database may partially overlap, such as in the object name or object identifier. The fields of the second part of the data content in the cache database can be set according to requirements, such as the object's activity data or popular data, and can be configured as needed to supplement the first part of the data content in the Elasticsearch database, alleviating the access pressure on the Elasticsearch database.
[0071] Based on the above embodiments, a query is performed in the ES database based on the query request corresponding to the query operation to obtain the identifier of the visible object and the first information of the visible object; a query is performed in the cache database based on the identifier of the visible object to obtain the second information of the visible object; and a sub-query result of the visible object is generated based on the first information and the second information of the visible object, with at least one sub-query result of the visible object forming the query result.
[0072] Since both the ES database and the cache database store partial data from the relational database, meaning that the data in the ES database and the cache database may be incomplete, depending on business needs, it is also possible to query the relational database based on the identifier of the visible object to obtain the third information of the visible object. Accordingly, the first, second and third information of the visible object are assembled to form the subquery result of the visible object.
[0073] In this embodiment, a query request is made to search the city index information and object index information in the ES database to quickly match the identifier of the visible object and the first information of the visible object. Based on the identifier of the visible object, a query is made in the cache database to match the second information of the visible object. The first and second information of the visible object are then assembled to form a sub-query result of the visible object, thus achieving a fast response to the query request.
[0074] The technical solution of this embodiment can improve the efficiency of information retrieval by coordinating the Elasticsearch database and the cache database. Furthermore, during the data synchronization process, the data synchronization is processed through the Kafka message middleware, and the abnormal data is scanned periodically during the synchronization process, which ensures the success rate of data synchronization and improves the accuracy of data updates in the database.
[0075] Figure 4 This is a schematic diagram of the structure of an information display device provided in an embodiment of the present invention. Figure 4 As shown, the device includes:
[0076] The first display module 210 is used to display a map page, which is a map page with the location information as the center point and a first scale.
[0077] The second display module 220 is used to respond to a query operation, obtain query results, determine a second scale of the map page based on the display range corresponding to the query results, scale the map page based on the second scale, and mark the visible objects corresponding to the query results in the scaled map page.
[0078] The technical solution of this embodiment adaptively scales the map page according to the query results when the user performs a query operation, and marks the visible objects corresponding to the query results on the scaled map page. This realizes automated interaction between the user and the map page, avoids the situation where the user manually adjusts the map page to display the query results, and improves the flexibility of information query on the map page.
[0079] Based on the above embodiments, optionally, the query request corresponding to the query operation includes query conditions; and the query result corresponding to the object query operation is sub-query information of visible objects that satisfy the query conditions.
[0080] The display area corresponding to the query results is the range centered on the location information, including the visible objects.
[0081] Optionally, the second display module 220 is used to: obtain first size information of the device screen, and determine second size information of the display range based on the edge information of the display range corresponding to the query result; and determine the second scale based on the first size information and the second size information.
[0082] Optionally, the second display module 220 is further configured to: during the display of the map page, in response to a transformation operation on the map page, update the display range, update the map page based on the updated display range, obtain newly added visible objects within the updated display range, and mark the newly added visible objects in the updated map page.
[0083] Optionally, the second display module 220 is further configured to: query the ES database based on the query request corresponding to the query operation to obtain the identifier of the visible object and the first information of the visible object; query the cache database based on the identifier of the visible object to obtain the second information of the visible object; and generate a sub-query result of the visible object based on the first information and the second information of the visible object, wherein at least one sub-query result of the visible object forms the query result.
[0084] Optionally, the data content of the ES database and the cache database are obtained from a relational database, which includes data content of multiple objects.
[0085] When the data content of any object is updated, the relational database synchronizes the first part of the object's data content to the ES database via Kafka messages; deletes the stored data corresponding to the object in the cache database, reads the second part of the object's data content from the relational database, and caches it in the cache database.
[0086] Optionally, the ES database update module is also used to generate abnormal log information in the event of Kafka message synchronization failure; periodically scan the abnormal log information and synchronize the data content in the abnormal log information to the ES database.
[0087] The information display device provided in the embodiments of the present invention can execute the information display method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of executing the method.
[0088] Figure 5This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. The electronic device 10 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 may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as 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.
[0089] like Figure 5 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may 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.
[0090] 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.
[0091] 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, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as information display methods.
[0092] In some embodiments, the information display method 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 mounted 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 information display method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the information display method by any other suitable means (e.g., by means of firmware).
[0093] 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 products (ASSPs), systems-on-a-chip (SoCs), payload-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.
[0094] Computer programs used to implement the information display method of the present invention can be written in any combination of one or more programming languages. These computer programs can 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 implemented. The computer programs can 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.
[0095] This invention also provides a computer-readable storage medium storing computer instructions for causing a processor to execute an information display method, the method comprising:
[0096] Display a map page, which is a map page with the location information as the center point and a first scale; respond to a query operation, obtain the query result, determine the second scale of the map page based on the display range corresponding to the query result, zoom the map page based on the second scale, and mark the visible objects corresponding to the query result in the zoomed map page.
[0097] In the context of this invention, a computer-readable storage medium can 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. A 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, a 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.
[0098] 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).
[0099] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include 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.
[0100] 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.
[0101] It should be understood that the various forms of processes shown above can be used to reorder, add, or delete steps. 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.
[0102] 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. An information display method, characterized in that, include: Display a map page, which is a map page with the location information as the center point and a first scale; In response to a query operation, the query results are obtained, a second scale of the map page is determined based on the display range corresponding to the query results, the map page is scaled based on the second scale, and the visible objects corresponding to the query results are marked on the scaled map page.
2. The method according to claim 1, characterized in that, The query request corresponding to the query operation includes query conditions; the query result corresponding to the object query operation is sub-query information of visible objects that satisfy the query conditions; The display range corresponding to the query results is the range centered on the location information and including the visible objects.
3. The method according to claim 1, characterized in that, Determining the second scale of the map page based on the display area corresponding to the query results includes: Obtain first size information of the device screen, and determine second size information of the display range based on the edge information of the display range corresponding to the query result; The second scale is determined based on the first size information and the second size information.
4. The method according to claim 1, characterized in that, The method further includes: During the display of the map page, in response to the transformation operation of the map page, the display range is updated, the map page is updated based on the updated display range, newly visible objects within the updated display range are obtained, and the newly visible objects are marked on the updated map page.
5. The method according to claim 2, characterized in that, The process of obtaining query results includes: Based on the query request corresponding to the query operation, a query is performed in the ES database to obtain the identifier of the visible object and the first information of the visible object; Based on the identifier of the visible object, a query is performed in the cache database to obtain the second information of the visible object; Based on the first information and the second information of the visible object, a subquery result of the visible object is generated, and at least one subquery result of the visible object forms the query result.
6. The method according to claim 5, characterized in that, The data content in the ES database and the cache database are respectively synchronized from a relational database, and the relational database includes data content of multiple objects; When the data content of any object is updated, the relational database will synchronize the first part of the object's data content to the ES database via Kafka messages; And delete the stored data corresponding to the object in the cache database, read the second part of the data content of the object from the relational database and cache it in the cache database.
7. The method according to claim 6, characterized in that, The synchronization process of the ES database also includes: In the event of a Kafka message synchronization failure, an exception log message is generated. The abnormal log information is scanned periodically, and the data content in the abnormal log information is synchronized to the ES database.
8. An information display device, characterized in that, include: The first display module is used to display a map page, which is a map page with the location information as the center point and a first scale. The second display module is used to respond to a query operation, obtain query results, determine a second scale of the map page based on the display range corresponding to the query results, scale the map page based on the second scale, and mark the visible objects corresponding to the query results in the scaled map page.
9. 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, the computer program being executed by the at least one processor to enable the at least one processor to perform the information display method according to any one of claims 1-7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that are used to cause a processor to execute the information display method according to any one of claims 1-7.