The embodiment of the invention discloses a position information processing method and server, the method includes: if received from the terminal application request contains positioning requirements, obtain the position information of the terminal current; obtain the application request corresponding to the positioning accuracy; judging whether the positioning accuracy and the difference information is matched by the difference of information for income according to the position information of the terminal location information and stored; if the difference between the information and the positioning precision of phase matching, the terminal location information to maintain the preset constant. An embodiment of the invention also discloses a server. The embodiment of the invention increases the server internal logic, namely when the terminal location information stored information and maintain the difference positioning accuracy to match the same, thus avoiding the location information to update the stored through real-time access to the current position information of the terminal operation, and can reduce the server workload, save server resources.
【技术实现步骤摘要】
一种位置信息处理方法及服务器
本专利技术涉及计算机
,尤其涉及一种位置信息处理方法及服务器。
技术介绍
随着移动网络技术的普及,应用程序被越来越广泛地应用在移动终端上,如微信、美团、滴滴打车及支付类应用程序已经成为人们日常生活中常备工具。在使用应用程序时,服务器需要根据移动终端的位置信息来提供相应的服务。现有技术中服务器的逻辑性不强,即无论在任何应用场景下都需要实时获取终端当前的位置信息并依此更新预存的位置信息,从而实现为移动终端提供相应的服务。然而,目前这种实时更新位置信息的方法工作量大、额外占用服务器资源,从而造成服务器资源浪费。
技术实现思路
本专利技术实施例提供一种位置信息处理方法及服务器,其能够减少服务器的工作量,节约服务器资源。第一方面,本专利技术实施例提供了一种位置信息处理方法,该方法包括:若接收到来自终端的包含有定位需求的应用请求,获取终端当前的位置信息;获取所述应用请求所对应的定位精度;判断所述定位精度与差异信息是否相匹配,所述差异信息为根据所述终端当前的位置信息和预存的位置信息进行比较所得;若差异信息与定位精度相匹配,维持所述预存的位置信息不变。另一方面,本专利技术实施例提供了一种服务器,该服务器包括获取单元,用于若接收到来自终端的包含有定位需求的应用请求,获取终端当前的位置信息,以及获取所述应用请求所对应的定位精度;判断单元,用于判断所述定位精度与差异信息是否相匹配,所述差异信息为根据所述终端当前的位置信息和预存的位置信息进行比较所得;执行单元,用于若差异信息与定位精度相匹配,维持所述预存的位置信息不变。本专利技术实施例根据接收到的 ...
【技术保护点】
一种位置信息处理方法,其特征在于,包括:若接收到来自终端的包含有定位需求的应用请求,获取终端当前的位置信息;获取所述应用请求所对应的定位精度;判断所述定位精度与差异信息是否相匹配,所述差异信息为根据所述终端当前的位置信息和预存的位置信息进行比较所得;若差异信息与定位精度相匹配,维持所述预存的位置信息不变。
【技术特征摘要】
1.一种位置信息处理方法,其特征在于,包括:若接收到来自终端的包含有定位需求的应用请求,获取终端当前的位置信息;获取所述应用请求所对应的定位精度;判断所述定位精度与差异信息是否相匹配,所述差异信息为根据所述终端当前的位置信息和预存的位置信息进行比较所得;若差异信息与定位精度相匹配,维持所述预存的位置信息不变。2.如权利要求1所述的方法,其特征在于,所述方法还包括:若差异信息与定位精度不匹配,根据所述终端当前的位置信息更新所述预存的位置信息。3.如权利要求1所述的方法,其特征在于,所述获取所述应用请求所对应的定位精度具体包括:设置终端中不同应用相对应的定位精度;根据所述应用请求查找出对应的定位精度。4.如权利要求3所述的方法,其特征在于,所述设置终端中不同应用相对应的定位精度具体包括:将终端中的应用划分为不同的类型;为不同类型的应用配置不同的定位精度。5.如权利要求1所述的方法,其特征在于,所述判断所述定位精度与差异信息是否相匹配具体包括:采集获取终端当前的位置信息的时间信息;根据采集的时间信息分析所述预存的位置信息是否有效;若无效,裁定所述定位精度与差异信息不匹配;若有效,根据所述预存的位置信息分析终端当前的位置是否在距离范围内;若不在距离范围内,裁定所述所述定位精度与差异信息不匹配;若在距离范围内,裁定所述定位精度与差异信息相匹配。6.一种服务器,其特征在于,包括:获取单元,...
【专利技术属性】
技术研发人员:陈鸽,张良,董学帅,
申请(专利权)人:平安科技深圳有限公司,
类型:发明
国别省市:广东,44
还没有人留言评论。发表了对其他浏览者有用的留言会获得科技券。