2013-12-19 161 views
1

我在Java中遇到了默認的「Objekt」類型問題。我認爲有可能命名一個「客體」類的屬性,因此它將任何一種客體作爲分配。錯誤是「找不到符號」,繼承人代碼:java找不到符號Objekt

class List{ 

    private class Cell{ 
     Objekt value; 
     Cell next; 

     Cell (Objekt value, Cell next){ 

      this.value = value; 
      this.next = next; 

     } 
    } 

/* Following Methods that use other Classes, so the code becomes very hard to follow, 
    so I'll leave them away because they dont seem to be the problem, as the error already 
    shows up at the first usage of the Type "Objekt"*/ 

} 

謝謝你提前。

+1

這是'Object',而不是'Objekt'。如果你創建了一個'Objekt'類,你肯定錯過了導入它。但我真的建議你改名。 – user2336315

回答

4

Objekt應該是Object(或者可能你已經錯過了你的自定義Objekt進口)

0

Object不是Objekt。我知道有幾個地方可以寫成'Objekt',但是談論java編程..它被拼寫爲'Object'