Disclosure of Invention
The application provides a map data query method, a map data query system, a terminal and a server, which can realize accurate map search and display and reduce data transmission quantity.
The technical scheme is as follows:
in a first aspect, the present invention provides a map data query method, including:
the terminal acquires an interest surface identifier to be inquired;
and inquiring and acquiring the interest surface data corresponding to the interest surface identification from a vector map tile locally pre-stored by the terminal.
Preferably, before the terminal obtains the identifier of the interest plane to be queried, the method further includes:
a terminal sends a search request to a search server, wherein the search request comprises search keywords;
and the terminal acquires the interest surface identification to be inquired returned by the search server, and the interest surface identification to be inquired is obtained by the search server according to the search keyword.
Preferably, before the terminal obtains the identifier of the interest plane to be queried, which is returned by the search server, the method further includes:
the method comprises the steps that a search server obtains a search request sent by a terminal, and searches corresponding interest point identifications according to search keywords in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
Preferably, before the terminal obtains the identifier of the interest plane to be queried, the method further includes:
a terminal acquires a search request sent by a user, wherein the search request comprises search keywords;
the terminal executes local search to obtain an interest point identifier corresponding to the search keyword;
and the terminal queries and acquires the interest surface identification corresponding to the interest point identification according to the mapping relation between the locally pre-stored interest point identification and the interest surface identification, and the interest surface identification is used as the interest surface identification to be queried.
Preferably, the method further comprises:
and pre-storing the interest surface data in the vector map tile, and establishing a corresponding relation between the vector map tile and the interest surface identifier.
Preferably, the querying and acquiring the interest plane data corresponding to the interest plane identifier by the terminal includes:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
Preferably, the obtaining of the data of the interest plane from the vector map tile corresponding to the display hierarchy further includes:
when the interest plane data are separately stored in at least two vector map tiles with the same display level, the vector map tiles with the same display level are obtained, the separately stored interest plane data are obtained from the vector map tiles, and the complete interest plane data are obtained through combination.
Preferably, the method further comprises:
displaying the vector map tiles and displaying the complete interest plane data.
Preferably, the vector map tiles stored in advance locally at the terminal are offline data downloaded in advance, or are cache data, the offline data are data downloaded to the local part of the terminal through an offline data packet, and the cache data are data cached to the local part of the terminal in the process of browsing the map online.
Preferably, the method further comprises:
and if the interest area data corresponding to the interest area identification is not inquired in the vector map tiles locally pre-stored in the terminal, inquiring and acquiring the interest area data from the server according to the interest area identification.
In a second aspect, the present invention provides a map data query system, including: a terminal and a search server;
the search server is configured to send the interest surface identifier to be queried to the terminal;
and the terminal is configured to query and acquire the interest surface data corresponding to the interest surface identifier from a vector map tile locally pre-stored in the terminal.
Preferably, the terminal is further configured to send a search request to the search server, where the search request includes a search keyword;
and the search server is configured to search according to the search keyword to obtain the interest surface identification to be queried.
Preferably, the searching server obtaining the interest plane identifier to be queried according to the search keyword includes:
acquiring a search request sent by a terminal, and searching for a corresponding interest point identifier according to a search keyword in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
Preferably, the terminal is further configured to obtain a search request sent by a user, where the search request includes a search keyword;
the terminal executes local search to acquire the interest point identification corresponding to the search keyword;
the terminal queries and acquires the interest surface identification corresponding to the interest point identification according to the mapping relation between the locally pre-stored interest point identification and the interest surface identification, and the interest surface identification is used as the interest surface identification to be queried.
Preferably, the terminal is further configured to pre-store the interest plane data in the vector map tile, and establish a correspondence between the vector map tile and the interest plane identifier.
Preferably, the querying and acquiring the interest plane data corresponding to the interest plane identifier by the terminal includes:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
Preferably, when the plane of interest data is separately stored in at least two vector map tiles of the same display level, the terminal is further configured to:
and acquiring the at least two vector map tiles with the same display level, acquiring separately stored interest plane data from the at least two vector map tiles, and combining the interest plane data to obtain complete interest plane data.
Preferably, the terminal is further configured to:
displaying the vector map tiles and displaying the complete interest plane data.
Preferably, if the data of the interest plane corresponding to the interest plane identifier is not queried in a vector map tile pre-stored locally in the terminal, the terminal is further configured to: and inquiring and acquiring the interest plane data from the server side according to the interest plane identification.
In a third aspect, the present invention provides a map data query terminal, including:
the communication module is used for acquiring the identification of the interest surface to be inquired;
and the query module is used for querying and acquiring the interest surface data corresponding to the interest surface identification from the vector map tiles locally pre-stored in the terminal.
Preferably, the terminal further includes:
the request module is configured to send a search request to a search server, wherein the search request includes a search keyword.
Preferably, the terminal further includes:
the search module is arranged for acquiring a search request sent by a user, wherein the search request comprises search keywords;
the search module is also configured to execute local search and acquire an interest point identifier corresponding to the search keyword;
the search module is further configured to query and acquire an interest plane identifier corresponding to the interest point identifier according to a mapping relationship between locally pre-stored interest point identifiers and interest plane identifiers, and the obtained interest plane identifier is used as the interest plane identifier to be queried.
Preferably, the terminal further includes:
and the storage module is used for pre-storing the interest surface data in the vector map tile and establishing the corresponding relation between the vector map tile and the interest surface identification.
Preferably, the querying module querying and acquiring the interest plane data corresponding to the interest plane identifier includes:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
Preferably, the obtaining, by the query module, the data of the interest plane from the vector map tile corresponding to the display hierarchy includes:
when the interest plane data are separately stored in at least two vector map tiles with the same display level, the vector map tiles with the same display level are obtained, the separately stored interest plane data are obtained from the vector map tiles, and the complete interest plane data are obtained through combination.
Preferably, the terminal further includes:
and the display module is used for displaying the vector map tiles and displaying the complete interest surface data.
Preferably, the terminal further comprises: a network module for performing a network-based operation,
and if the interest plane data corresponding to the interest plane identifier is not inquired in a vector map tile locally pre-stored in the terminal by the inquiry module, the network module is set to inquire and acquire the interest plane data from the server according to the interest plane identifier.
In a fourth aspect, the present invention provides a map data search server, comprising:
the acquisition module is arranged for acquiring a search request sent by a terminal, wherein the search request comprises search keywords;
and the identification module is used for searching according to the search keywords to obtain the identification of the interest surface to be inquired.
Preferably, the obtaining, by the identification module, the interest plane identification to be queried according to the search keyword includes:
searching corresponding interest point identifications according to the search keywords in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
Compared with the prior art, the application has the following beneficial effects:
the method comprises the steps of obtaining interest plane data corresponding to an interest plane identifier by using a mapping relation between the interest point identifier and the interest plane identifier; when the map searches for the AOI (Area Of Interest), the corresponding AOI geometric data does not need to be issued any more, and data transmission is reduced, so that the user traffic is reduced, the terminal does not need to cache the AOI geometric data brought by the search, and the storage space Of the user terminal is reduced.
Detailed Description
The technical solution of the present application will be described in more detail with reference to the accompanying drawings and embodiments.
It should be noted that, if not conflicted, the embodiments and the features of the embodiments can be combined with each other and are within the scope of protection of the present application. Additionally, while a logical order is shown in the flow diagrams, in some cases, the steps shown or described may be performed in an order different than here.
In one configuration, an apparatus for a search server to perform a map search may include one or more processors (CPUs), input/output interfaces, network interfaces, and memories (memories).
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium. The memory may include one or more modules.
Computer-readable media include both non-transitory and non-transitory, removable and non-removable storage media that can implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device.
Example one
As shown in fig. 1, an embodiment of the present invention provides a map data query method, including:
s101, a terminal acquires an identification of an interest plane to be inquired;
and S102, inquiring and acquiring the interest surface data corresponding to the interest surface identification from a vector map tile locally pre-stored in the terminal. Wherein the interest plane data comprises: name, type, grade of the interest surface, geometric data such as longitude and latitude coordinates of the shape points, connection order of the shape points, and the like.
In an implementation manner of this embodiment, before the terminal obtains the identifier of the interest plane to be queried, the method may further include:
a terminal sends a search request to a search server, wherein the search request comprises search keywords; the search keyword may be the name, location, type, etc. of the interest plane.
And the terminal acquires the interest surface identification to be inquired returned by the search server, and the interest surface identification to be inquired is obtained by the search server according to the search keyword.
Before the terminal obtains the interest plane identifier to be queried returned by the search server, the method may further include:
the method comprises the steps that a search server obtains a search request sent by a terminal, and searches corresponding interest point identifications according to search keywords in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
For example, the unique mapping relationship between the interest points of the "Qinghua university" and the interest surfaces of the "Qinghua university" can be stored in the search server in advance. After a user sends a search request for searching for 'Qinghua university' to the search server through the terminal, the identifier of the interest plane of the 'Qinghua university' is found according to the mapping relation stored in advance and is returned to the terminal. The scheme can avoid the wrong inquiry of the interest plane identification of 'Qinghua university subsidiary middle school'.
In another implementation manner of this embodiment, before the terminal acquires the identifier of the interest plane to be queried, the method may further include:
a terminal acquires a search request sent by a user, wherein the search request comprises search keywords;
the terminal executes local search to obtain an interest point identifier corresponding to the search keyword;
and the terminal queries and acquires the interest surface identification corresponding to the interest point identification according to the mapping relation between the locally pre-stored interest point identification and the interest surface identification, and the interest surface identification is used as the interest surface identification to be queried.
In response to the search request, local offline search may be performed at the terminal or online search may be performed at the search server.
In the embodiment, the terminal or the server acquires the search request, and generally, if the terminal is not connected with the network, the terminal performs off-line search, and when the terminal is connected with the network, the search server performs on-line search. When the terminal carries out off-line search, off-line data downloaded in advance by the terminal can be used, or the data can be cached; the offline data may be data downloaded through an offline map data packet, and the cached data may be data cached locally in the process of browsing a map online.
In this embodiment, the mapping relationship may be stored locally in the terminal or in the search server. When the storage space of the terminal is sufficient and the processing capacity meets the requirement, the mapping relation can be locally stored in the terminal, so that offline search can be smoothly carried out. Typically the mapping is stored in the search server. Wherein the mapping relation supports operations such as updating, adding, deleting and modifying.
In this embodiment, the geometric data of the interest plane is stored in the vector map tile locally pre-stored in the terminal, and the interest plane data pre-stored in the vector map tile can be obtained by using the interest plane identifier; when the map searches the interest plane, the corresponding interest plane geometric data is not required to be issued any more, and data transmission is reduced, so that the user flow is reduced, the terminal does not need to separately cache the interest plane geometric data brought by searching, and the occupied storage space of the user terminal can be reduced.
In this embodiment, the terminal needs to store the data of the interest plane in the vector map tile in advance, and establish a corresponding relationship between the vector map tile and the identifier of the interest plane.
And after online searching is carried out, the search server feeds back the interest surface identification to the terminal.
The step S102 of querying and obtaining the interest plane data corresponding to the interest plane identifier includes:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
The display hierarchy is the scale level of the map display. Vector map tiles for corresponding display levels are pre-compiled for different display levels. In the embodiment, the relationship between the interest point data and the interest plane data is pre-established; and storing the interest surface data and the interest surface identification into the vector map tile data of the corresponding display level. For example, in a geographic map with a scale of 50KM, the geometric data of the interest plane a may be aggregated into one point or one line, and in a geographic map with a scale of 10 m, the geometric data of the interest plane a includes a plurality of sequentially connected shape points.
When the interest plane data are acquired according to the interest plane identification, the corresponding interest plane data may exist in one or more vector map tiles, and when the interest plane data are separately stored in at least two vector map tiles with the same display level, the vector map tiles with the at least two same display levels are acquired, the separately stored interest plane data are acquired therefrom, and the complete interest plane data are obtained by combination.
In this embodiment, the terminal further displays the vector map tiles, and displays the complete interest plane data and the complete interest point data.
And if the interest surface data corresponding to the interest surface identification is not inquired in a vector map tile locally pre-stored in the terminal, inquiring and acquiring the interest surface data from a search server or a map rendering server according to the interest surface identification.
After the map interface is dragged or zoomed by the user, the embodiment confirms the display level after dragging or zooming, and searches and displays the corresponding interest surface data from the vector map tile corresponding to the display level after dragging or zooming according to the interest surface identifier.
Example two
This embodiment describes a process of performing online search to a search server by using a terminal:
the search server acquires a search request and searches for corresponding interest point identification according to keywords in the search request;
the search server inquires the interest face identification corresponding to the interest point identification according to the mapping relation between the interest point identification and the interest face identification;
the terminal inquires and acquires the interest surface data corresponding to the interest surface identification from a local vector map tile of the terminal;
and the terminal displays the interest surface data, such as the name, the type and the geometric shape of the interest surface.
When the user inputs a query address, for example, the destination point is "Qinghua university", the user may input a search word in the search field, and the embodiment may match a destination keyword in the historical search results or determine the destination keyword according to the user selection from the historical search results.
And sending a search request by an APP (application), such as a map, wherein the search request carries destination keywords. The corresponding point of interest identification may be determined from the keywords in the search request.
In this embodiment, the process of obtaining the interest plane identifier through online search by the search server may obtain an accurate interest plane identifier with real-time data update.
EXAMPLE III
As shown in fig. 2, the present embodiment explains a case where an online search is performed by a search server, implemented by a map data query system including a terminal and a search server:
the search server is set to send the interest surface identification to be inquired to the terminal;
and the terminal is configured to query and acquire the interest surface data corresponding to the interest surface identifier from a vector map tile locally pre-stored in the terminal.
In this embodiment, the terminal is further configured to send a search request to the search server, where the search request includes a search keyword;
and the search server is configured to search according to the search keyword to obtain the interest surface identification to be queried.
The searching server obtains the interest area identifier to be inquired according to the searching keyword comprises the following steps:
acquiring a search request sent by a terminal, and searching a corresponding interest point identifier according to a search keyword in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
In this embodiment, the terminal is further configured to pre-store the interest plane data in the vector map tile, and establish a correspondence between the vector map tile and the interest plane identifier.
The step of the terminal inquiring and acquiring the interest plane data corresponding to the interest plane identifier comprises the following steps:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
In this embodiment, when the interest plane data is separately stored in at least two vector map tiles of the same display hierarchy, the terminal is further configured to:
and acquiring the at least two vector map tiles with the same display level, acquiring separately stored interest plane data from the at least two vector map tiles, and combining the interest plane data to obtain complete interest plane data.
In this embodiment, the terminal is further configured to:
displaying the vector map tiles and displaying the complete interest plane data.
In this embodiment, if the data of the interest plane corresponding to the interest plane identifier is not queried in a vector map tile locally pre-stored in the terminal, the terminal is further configured to: and inquiring and acquiring the interest plane data from the server side according to the interest plane identification.
In the embodiment, a terminal sends a search request to a search server, wherein the search request carries a destination keyword; for example, the search server determines the interest point identifier corresponding to the university of Qinghua according to the corresponding relationship between the pre-stored keywords and the interest point identifier; the search server acquires an interest plane identifier corresponding to the Qinghua university according to a mapping relation between a prestored interest point identifier and an interest plane identifier; the search server feeds back the interest surface identification of the Qinghua university to the terminal; and the terminal acquires the interest plane data corresponding to the interest plane identification according to the local vector map tile and displays the interest plane data of the Qinghua university.
In this embodiment, as shown in fig. 3, the search server performs the following improvements:
establishing a mapping relation between AOI and POI: AOI is interest surface data, POI is interest point data, and the relation between the two data is established in an ID mapping mode.
Rendering, compiling and storing AOI and ID data thereof: and writing the AOI data into the vector map tiles of all display levels, and setting the ID of the AOI data as the original AOIID so as to extract the data later.
Searching and compiling POI and mapping relation: and searching the mapping relation to be stored so as to issue the corresponding AOIID when the user searches the POI.
In this embodiment, as shown in fig. 4, the terminal is modified as follows:
1) searching POI by the user: and searching the POI keywords by the user, and triggering the AOI and POI searching mode.
2) The search service issues POI and corresponding AOIID: and the search service finds corresponding POI and AOIID according to the keywords input by the user and sends the POI and AOIID to the terminal.
3) The client extracts AOI surface data in the map tile according to the AOIID: and the terminal searches the corresponding AOIID from the offline packet or the cached vector map tile according to the AOIID.
4) The client displays AOI and POI data: if the AOIID is in multiple vector map tiles of the same display level, the faces are merged and then presented with the POI. If in only one vector map tile, it is presented directly to the user along with the POI.
Take the user searching for Qinghua university as an example:
1) and establishing a mapping relation between the Qinghua university interest Area (AOI) ID and the Qinghua university interest Point (POI) ID. The rendering and compiling service stores Qinghua university interest Area (AOI) data in vector map tiles of different display levels, and the search server stores mapping relations between points of interest (POI) of Qinghua university and the AOI of Qinghua university.
2) The user searches for Qinghua university. The terminal uploads the search keywords of the user to a search service, the search service analyzes the keywords, triggers AOI search, acquires an interest Area (AOI) ID of Qinghua university, and issues the POIID and the AOIID to the terminal.
3) And displaying by a terminal. And the terminal searches AOI data in the vector map tiles of the current display level according to the AOIID, and if one AOI data is stored in a plurality of vector map tiles, the terminal respectively acquires the AOI data in each vector map tile data and displays the AOI data after merging the AOI data.
In this embodiment, the manner in which the terminal stores and updates the corresponding interest plane data and displays the interest plane data is consistent with the embodiment, and details are not repeated here.
Example four
In this embodiment, another implementation manner, this embodiment describes a case where a terminal performs offline search, and the terminal is queried by using map data:
the terminal is configured to acquire a search request sent by a user, wherein the search request comprises a search keyword;
the terminal executes local search to acquire the interest point identification corresponding to the search keyword;
the terminal queries and acquires the interest surface identification corresponding to the interest point identification according to the mapping relation between the locally pre-stored interest point identification and the interest surface identification, and the interest surface identification is used as the interest surface identification to be queried.
And the terminal inquires and acquires the interest surface data corresponding to the interest surface identification from a vector map tile locally pre-stored in the terminal.
In this embodiment, the manner of storing and displaying the corresponding interest plane data and the manner of displaying the interest plane data by the terminal are the same as those in the third embodiment, and are not described herein again.
EXAMPLE five
As shown in fig. 5, the present embodiment provides a map data query terminal, including:
the communication module is used for acquiring an interest surface identifier to be inquired;
and the query module is used for querying and acquiring the interest surface data corresponding to the interest surface identification from the vector map tiles locally pre-stored in the terminal.
In this embodiment, the terminal further includes:
the request module is configured to send a search request to a search server, wherein the search request includes a search keyword.
In this embodiment, the terminal further includes:
the search module is arranged for acquiring a search request sent by a user, wherein the search request comprises search keywords;
the search module is also configured to execute local search and acquire an interest point identifier corresponding to the search keyword;
the search module is further configured to query and acquire an interest plane identifier corresponding to the interest point identifier according to a mapping relationship between locally pre-stored interest point identifiers and interest plane identifiers, and the obtained interest plane identifier is used as the interest plane identifier to be queried.
In this embodiment, the terminal further includes:
and the storage module is used for pre-storing the interest surface data in the vector map tile and establishing the corresponding relation between the vector map tile and the interest surface identification.
In this embodiment, the querying, by the querying module, acquiring the interest plane data corresponding to the interest plane identifier includes:
acquiring a display level of a map interface;
and inquiring and acquiring the data of the interest surface from the vector map tiles corresponding to the display levels.
In this embodiment, the obtaining, by the query module, the data of the interest plane from the vector map tile corresponding to the display hierarchy includes:
when the interest plane data are separately stored in at least two vector map tiles with the same display level, the vector map tiles with the same display level are obtained, the separately stored interest plane data are obtained from the vector map tiles, and the complete interest plane data are obtained through combination.
In this embodiment, the terminal further includes:
and the display module is used for displaying the vector map tiles and displaying the complete interest surface data.
In this embodiment, the terminal further includes: a network module;
and if the interest plane data corresponding to the interest plane identifier is not inquired in a vector map tile locally pre-stored in the terminal by the inquiry module, the network module is set to inquire and acquire the interest plane data from the server according to the interest plane identifier.
EXAMPLE six
As shown in fig. 6, the present embodiment provides a map data search server, including:
the acquisition module is arranged for acquiring a search request sent by a terminal, wherein the search request comprises search keywords;
and the identification module is used for searching according to the search keywords to obtain the identification of the interest surface to be inquired.
The identification module searches for the interest area identification to be inquired according to the search keyword and comprises the following steps:
searching corresponding interest point identifications according to the search keywords in the search request;
and inquiring and acquiring the interest plane identifier corresponding to the interest point identifier according to the mapping relation between the prestored interest point identifier and the interest plane identifier, wherein the interest plane identifier is used as the interest plane identifier to be inquired.
Although the embodiments of the present invention have been described above, the contents thereof are merely embodiments adopted to facilitate understanding of the technical aspects of the present invention, and are not intended to limit the present invention. It will be apparent to persons skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined in the appended claims.