{"version":"0.1.0","code":"0000","result":true,"message":"处理成功","errdetail":"","timestamp":1671516349758,"data":{"id":71711998,"title":"5.4.4.3 巡航拥堵路况","slug":"exgg66","format":"lake","bookId":26046811,"body":null,"body_draft":null,"body_html":"
TR路况配置:com.autonavi.gbl.guide.model.guidecontrol.TRParam
透出路况信息需要确保打开了TR开关:TRParam.enable=true。
传出巡航状态下的拥堵区域信息\nvoid com.autonavi.gbl.guide.observer.ICruiseObserver.onUpdateCruiseCongestionInfo(CruiseCongestionInfo info)
说明:函数详情,请复制函数名称到在线API搜索
//初始化\nprivate void initGuideService() {\n GuideService mGuideService = (GuideService) ServiceMgr.getServiceMgrInstance().getBLService(SingleServiceID.GuideSingleServiceID);\n mGuideService.init();\n // 添加巡航信息观察者\n mGuideService.addCruiseObserver(cruiseObserver);\n // 开关配置\n Param trParam = new Param();\n trParam.type = Type.GuideParamTR;\n trParam.tr.enable = true; //打开TR开关\n mGuideService.setParam(trParam);\n \t...\n}\n\n// 巡航信息观察者\nICruiseObserver cruiseObserver = new ICruiseObserver(){\n\n\t@Override\n\tpublic void onUpdateCruiseCongestionInfo(CruiseCongestionInfo cruiseCongestionInfo) {\n\t\t//显示由图层内聚,具体见图层设置章节\n ...\n\t}\n \n ...\n}