中易网

内部类不能有静态声明

答案:1  悬赏:40  
解决时间 2021-01-19 23:59
  • 提问者网友:佞臣
  • 2021-01-19 01:00
内部类不能有静态声明
最佳答案
  • 二级知识专家网友:千夜
  • 2021-01-19 01:25
static fields can only be declared in static or top level types
static types can only be declared in static or top level types
static methods can only be declared in a static or top level type

以上是eclipse的错误提示信息
即只有在静态成员类或者是顶层类中才能生命静态成员变量,静态成员类和静态方法...
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息!
大家都在看
推荐信息