// 新能源信息// 设置新能源默认车牌BaiduNaviManagerFactory.getCommonSettingManager().setEnergyDefaultPlate("粤B66666");// 设置充电偏好BaiduNaviManagerFactory.getCommonSettingManager().setChargingPreferInfo(new BNChargingPreferInfo());
Bundle bundle = new Bundle();bundle.putInt(BNaviCommonParams.RoutePlanKey.SUB_VEHICLE, IBNRoutePlanManager.SubVehicle.NEW_ENERGY);routePlanToNavi(bundle);private void routePlanToNavi(final Bundle bundle) {List<BNRoutePlanNode> list = new ArrayList<>();list.add(BNDemoFactory.getInstance().getStartNode(this));list.add(BNDemoFactory.getInstance().getEndNode(this));BaiduNaviManagerFactory.getRoutePlanManager().routePlan(list,IBNRoutePlanManager.RoutePlanPreference.ROUTE_PLAN_PREFERENCE_DEFAULT,bundle, handler);}
Bundle params = new Bundle();// 创建新能源导航页面view,与普通导航相比需要新增该行,标识进入新能源页params.putInt(BNaviCommonParams.RoutePlanKey.SUB_VEHICLE, IBNRoutePlanManager.SubVehicle.NEW_ENERGY);params.putBoolean(BNaviCommonParams.ProGuideKey.IS_SUPPORT_FULL_SCREEN, fullScreen);mRouteGuideManager = BaiduNaviManagerFactory.getRouteGuideManager();BNGuideConfig config = new BNGuideConfig.Builder().params(params).build();view = mRouteGuideManager.onCreate(this, config);
上一篇
下一篇
本篇文章对您是否有帮助?