无法理解API输出 [英] Can't understand API Output

查看:85
本文介绍了无法理解API输出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用API​​,当我拨打某些电话时,会返回一些难以理解的内容:







{id:100,name:Manhattan,level:1,city:New York,state:NY,path:manhattan PARENT_ID:1, boundary_encoded_points_string:kfqwFzkwbM} uAwM_iAmIgi @ yQyfDm {BqmGc`Eon @き@ IR @ {OGT @ cCcSia @ {吨@ e` @}沃顿} LWI @ K [QBE [〜的Fc]李} KzEcO ^ aUxFgN〜I {的Gd] pEff @ XE @ RA @ H [PZ @ TJ @ HJA一b @ loAoFfhAdAdf @ EA @ JK @ {@ VC @ HH @ DK @〜[PB @ lEfX_HtQ | CjWzWv | @vp @ NH @ VJ @ bYde @ BF @ DORI @ HVN @ wBvtAtf @ rS的| Y @ zEzfA |奥法@ TE @〜| @ {B | O @ _Wd\\} n的@小号@ small_image_uri: /images/no_photo_small.png\",\"title\":\"Manhattan\",\"subtitle\":\"in NYC,details:}







具体到底是什么:





kfqwFzkwbM} uAwM_iAmIgi @ yQyfDm {BqmGc `宙@き@ IR @ {OGT @ cCcSia @ {吨@ e` @}沃顿} LWI @ K [QBE [〜的Fc]李} KzEcO ^ aUxFgN〜I {的Gd] pEff @ XE @ RA @ H [PZ @ TJ @ HJA一b @ loAoFfhAdAdf @ EA @ JK @ {@ VC @ HH @ DK @〜[PB @ lEfX_HtQ | CjWzWv | @ VP @ NH @ VJ @ bYde @ BF @ DORI @ HVN @ wBvtAtf @ rS的| Y @ zEzfA |奥法@ TE @〜| @ {B | O @ _Wd \\} n @ s @

I am working with an API and when i make certain calls it returns some incomprehensible stuff like this:



{"id":100,"name":"Manhattan","level":1,"city":"New York","state":"NY","path":"manhattan","parent_id":1,"boundary_encoded_points_string":"kfqwFzkwbM}uAwM_iAmIgi@yQyfDm{BqmGc`Eon@ki@ir@{Ogt@cCcSia@{t@e`@}k@}Lwi@k[qBe[~Fc]lI}KzEcO^aUxFgN~I{Gd]pEff@xe@ra@h[pz@tj@hjA~b@loAoFfhAdAdf@ea@jk@{@vc@hh@dk@~[pb@lEfX_HtQ|CjWzWv|@vp@nh@vj@bYde@bf@dOri@Hvn@wBvtAtf@rS|y@zEzfA|Ofa@te@~|@{B|o@_Wd\\}n@s@","small_image_uri":"/images/no_photo_small.png","title":"Manhattan","subtitle":"in NYC","details":""}



what exactly is this:


kfqwFzkwbM}uAwM_iAmIgi@yQyfDm{BqmGc`Eon@ki@ir@{Ogt@cCcSia@{t@e`@}k@}Lwi@k[qBe[~Fc]lI}KzEcO^aUxFgN~I{Gd]pEff@xe@ra@h[pz@tj@hjA~b@loAoFfhAdAdf@ea@jk@{@vc@hh@dk@~[pb@lEfX_HtQ|CjWzWv|@vp@nh@vj@bYde@bf@dOri@Hvn@wBvtAtf@rS|y@zEzfA|Ofa@te@~|@{B|o@_Wd\\}n@s@

推荐答案

这是在地图中具有一组点的编码多项式位置。请参阅以下参考

https://developers.google.com/maps/documentation/utilities /折线算法 [ ^ ]

如果您需要解码此字符串并检查谷歌地图中的真实位置,请转到

https://developers.google.com/maps/documentation/utilities/polylineutility [ ^ ]

并将上面编码的字符串放在编码折线:输入中,然后点击解码多边形线按钮。

C#解码代码可以在这里找到: https://gist.github.com/shinyzhu/4617989 [ ^ ]
this is encode polynomial location with set of points in a map. read below reference
https://developers.google.com/maps/documentation/utilities/polylinealgorithm[^]
if you need to decode this string and check the real location in the google map go to
https://developers.google.com/maps/documentation/utilities/polylineutility[^]
and place the above encoded string in the Encoded Polyline: input and click decode poly line button.
C# decode code can be found here : https://gist.github.com/shinyzhu/4617989[^]


这篇关于无法理解API输出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆