当前位置:网站首页>百度地图——鹰眼轨迹服务
百度地图——鹰眼轨迹服务
2022-08-09 14:50:00 【代码搬运工!!!】


新建一个测试类 TestBaiduYingyan
package cn.itcast.baidumap;
import cn.hutool.http.HttpRequest;
import org.junit.Test;
public class TestBaiduYingyan {
private String ak = "i0stCezN9kXNkfp5dEmPsMg7eIkFWquh";
/**
* 新增实体
*/
@Test
public void testEntityAdd(){
String url="https://yingyan.baidu.com/api/v3/entity/add";
String body = HttpRequest.post(url)
.form("ak", ak)
.form("service_id", 233936)
.form("entity_name", "route_1_1001")
.form("entity_desc", "用户1创建的1001路线")
.execute().body();
System.out.println(body);
}
}


/** * 新增实体(自定义字段) */ @Test public void testEntityAdd(){ String url="https://yingyan.baidu.com/api/v3/entity/add"; String body = HttpRequest.post(url) .form("ak", ak) .form("service_id", 233936) .form("entity_name", "route_1_1002") .form("entity_desc", "用户1创建的1002路线") .form("routeName", "用户1的1002路线") .execute().body(); System.out.println(body); }

/** * 更新实体(自定义字段) */ @Test public void testEntityUpdate(){ String url="https://yingyan.baidu.com/api/v3/entity/update"; String body = HttpRequest.post(url) .form("ak", ak) .form("service_id", 233936) .form("entity_name", "route_1_1001") .form("entity_desc", "用户1创建的1001路线更新") .form("routeName", "用户1的1001路线") .execute().body(); System.out.println(body); }
删除Entity
/**
* 删除实体(自定义字段)
*/
@Test
public void testEntityDelete(){
String url="https://yingyan.baidu.com/api/v3/entity/delete";
String body = HttpRequest.post(url)
.form("ak", ak)
.form("service_id", 233936)
.form("entity_name", "route_1_1001")
.execute().body();
System.out.println(body);
}查询
/**
* 查询体(自定义字段)
*/
@Test
public void testEntityList(){
String url="https://yingyan.baidu.com/api/v3/entity/list";
String body = HttpRequest.get(url)
.form("ak", ak)
.form("service_id", 233936)
.form("filter","entity_names:route_1_1002")
.form("coord_type_output","gcj02")//返回坐标体系
.execute().body();
System.out.println(body);

边栏推荐
- C语言程序设计笔记(浙大翁恺版) 第四周:循环
- [Basic version] Integer addition, subtraction, multiplication and division calculator
- MySQL数据库被攻击,被删库勒索,逼迫我使出洪荒之力进行恢复数据
- VSTO踩坑记录(2)- 运用outlook对象模型发送邮件
- leetcode 剑指 Offer 07. 重建二叉树
- 【Serilog】具有完全结构化事件的简单.NET日志记录
- C语言程序设计笔记(浙大翁恺版) 第十一周:结构类型
- 22岁测试工程师上来就内卷,起薪居然就18k,这谁顶得住?
- BVT测试(版本验证测试、冒烟测试)和Daily build
- Redis 面试题
猜你喜欢
随机推荐
机器学习--数学库--概率统计
How does the JVM judge that an object is useless
代码随想录笔记_动态规划_377组合总和IV
【最新】【获取ip】获取本地ip 获取本机ip地址
结合实际聊聊电平转换电路(常用电平转换电路总结)
The rising star DPU is revolutionizing the data center!
外贸软件如何提升进出口公司业绩 实现降本增效
DSPE-PEG-Hydrazide,DSPE-PEG-HZ,磷脂-聚乙二醇-酰肼MW:1000
优化软件测试成本的 7 个步骤
Regular expression combat: the latest Douban top250 crawler super detailed tutorial
Mongodb增加权限管理
优化代码 —— 减少 if - else
leetcode_jz
启动报错:Caused by: org.apache.ibatis.binding.BindingException汇总解决
Play in the cloud | The ever-changing gameplay of Tianyi cloud computer
C语言程序设计笔记(浙大翁恺版) 第十一周:结构类型
Item 37: Make std::threads unjoinable on all paths.
论文笔记CIRS
道路形态(道路要素)
【Qt】 No such slot...,No such signal









