2012-11-22 113 views

回答

4
here-place://lat,lon e.g. here-place://48.866833,2.355411 

打開這裏在給定的地方。

here-route://lat1,lon1,name1/lat2,lon2,name2 

開始從lat1,lon1到lat2,lon2的轉彎導航。

here-route:///lat2,lon2,name2 

開始從用戶位置到lat2,lon2的轉彎導航。

編輯:似乎名稱字段現在支持URL百分比轉義編碼空間和其他字符(測試在這裏WeGo v2.0.11。謝謝你擡頭)。

+0

在這裏做多路點,即多於兩個位置? –

1

URL應用程序的方案可以在應用程序的Info.plist中找到。在Info.plist -> URL Types -> URL Schemes -> xxxxx

從ipa中提取包內容很容易。將.ipa文件重命名爲.zip並解壓縮以提取內容。右鍵單擊DownloadedApp.app並顯示包內容。你會在那裏找到Info.plist,圖標,壓縮筆尖,可執行文件等。

對於諾基亞HERE地圖應用是nok

0

@FKDev

基本上可以用%20符號替換空格。發現NSData & NSURL - url with space having problemSpaces in a NSURL with variables doesn't load

我優選太使用實施例中所示的內部轉換器

Xcode的樣品

NSString *sUrl = @"here-route:///52.379189,4.899431,Amsterdam Central 
sUrl = [sUrl stringByAddingPercentEscapesUsingEncoding:NSASCIIStringEncoding]; 
NSURL *url = [NSURL URLWithString:sUrl]; 

C#樣品

var sUrl= Uri.EscapeUriString(@"here-route:///52.379189,4.899431,Amsterdam Central"); 
var url = new NSUrl(sUrl); 

兩個示例將在這裏路由:/ //52.379189,4.899431,Amsterdam%20Central

4

更新爲here-location://lat,lon,name最新版本(可能爲1.2左右)。 name是可選的。

here-placehere-route給出Couldn't open link錯誤,所以可能在那裏修改了語法。也許你可以在那裏指定地址,但它超出了我的研究範圍。

+0

此處路線適用於v2.0.11。我沒有在這裏休息。 – FKDev

1

放在這裏WEGO 2.0.20 (537)

  • 打開帶有自定義here-route URL方案的URL:
    • //mylocation/latitude,longitude
    • ,URLencoded string作爲目標
    • ?ref=<Referrer>引用的名稱(可像你的應用程序或公司名稱)
    • &m=w到指示路由模式(M = w表示的步行中,m = d爲驅動器)

例如,here-route://mylocation/37.870090,-122.268150,Downtown%20Berkeley? ref=<Referrer>&m=w請求路由通過腳在Berkeley市中心的目的地由一家名爲引薦。

來源:HERE Developer Mobility On-Demand Technical Solution Paper(第36頁)


我剛剛測試了這一點,它工作正常。最重要的位(至少對我來說)是/mylocation/必須位於URL中,這裏WeGo從用戶當前位置開始導航(字面上字mylocation必須在那裏)。

如果您不想從用戶的當前位置導航,也可以使用here-route://sourceLat,sourceLon,sourceOptionalName/destLat,destLon,destOptionalName

我也測試了here-location://lat,lon,optionalName,它在當前(最新的,請參閱本答案的頂部)版本的HERE WeGo(它曾經是here-place,但它不再工作)正常工作。