1、创建基础参数类

 1   public static class BaiduConstParams
 2     {
 3         public const string PlaceApIv2Search = "http://api.map.baidu.com/place/v2/search";
 4         public const string PlaceApIv2Detail = "http://api.map.baidu.com/place/v2/detail";
 5         public const string PlaceApIv2Eventsearch = "http://api.map.baidu.com/place/v2/eventsearch";
 6         public const string PlaceApIv2Eventdetail = "http://api.map.baidu.com/place/v2/eventdetail";
 7         public const string GeocodingApIv2 = "http://api.map.baidu.com/geocoder/v2/";
 8         public const string GeocodingApIv2Reverse = "http://api.map.baidu.com/geocoder/v2/";
 9         public const string TranslateApi = "http://openapi.baidu.com/public/2.0/bmt/translate";
10         public const string GeoconvApi = "http://api.map.baidu.com/geoconv/v1/";
11     }
12 
13     public static class BaiduErrorMessages
14     {
15         public const string NotKey = "密钥不存在";
16         public const string LackParam = "缺少必要请求参数";
17     }
View Code

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-06-02
  • 2022-02-01
  • 2021-12-31
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-03-01
  • 2021-12-09
  • 2021-08-27
  • 2021-05-29
相关资源
相似解决方案