2012-12-10 34 views
0

我正在關注此主題:Why retrieving Google Directions for Android using KML data is not working anymore?Android:我可以在我的包中找到課程

但是我被困在一個難以理解的錯誤上。當我嘗試引用我的班級RouteOverlay時出現問題:我可以參考我之前創建的班級(RouteOverlay.java)。在這裏,sitution:

enter image description here

如果我嘗試插入代碼行:

import maps.RouteOverlay 

我得到以下錯誤:

The type maps.RouteOverlay is not visible 

我想也是,重新啓動Eclipse或清潔該項目。我不知道我能做什麼!

+0

你是不是想從同一項目或不同項目導入'RouteOverlay'? – Kai

+0

同一個項目。我正確導入上面的類:(Parser,Route,GoogleParser) – GVillani82

回答

2

您正在複製的示例有一個錯字。 RouteOverlay班不公開。

class RouteOverlay extends Overlay {} 

將其更改爲:

public class RouteOverlay extends Overlay {} 
+0

你說得對!對不起,這個小問題。 – GVillani82

相關問題