亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定

No enclosing instance of type Actor is accessible. Must qualify the allocation with an enclosing instance of type Actor (e.g. x.new A() where x is an instance of Actor).

我在main()函數寫調用Actress的代碼,Thread actressThread = new Thread(new Actress(),"Ms.Runnable");總是出問題,問題是No enclosing instance of type Actor is accessible. Must qualify the allocation with an enclosing instance of type Actor (e.g. x.new A() where x is an instance of Actor).

求教各位!

正在回答

2 回答

把Actress類寫在Actor類外面就可以了

2 回復 有任何疑惑可以回復我~
#1

慕無忌3281512

我寫到外面了,還是出錯
2017-05-24 回復 有任何疑惑可以回復我~
#2

慕無忌3281512

我試了寫到里面,然后把Actress()改為Actor.Actress()還是那句出現錯誤,這到底是怎么回事?求教大神
2017-05-24 回復 有任何疑惑可以回復我~

建議你把你寫的代碼復制出來,在這個輸入框有一個代碼語言可以選

0 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消

No enclosing instance of type Actor is accessible. Must qualify the allocation with an enclosing instance of type Actor (e.g. x.new A() where x is an instance of Actor).

我要回答 關注問題
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號