android The public type classname must be defined in its own file 报错
2015-03-18 11:35
549 查看
The public type classname must be defined in its own file
classname 为类名
错误提示,公用的类必髯有自己拥有独立.java文件
解决方法:
在工程中新建一份.java文件,然后把类重新定义为公用类public
解决方法2:
如果你的类只需用在当前,则可更改为私有类,即将public改为private
classname 为类名
错误提示,公用的类必髯有自己拥有独立.java文件
解决方法:
在工程中新建一份.java文件,然后把类重新定义为公用类public
解决方法2:
如果你的类只需用在当前,则可更改为私有类,即将public改为private
相关文章推荐
- 调试记录:The public type <<classname>> must be defined in its own file
- 调试记录:The public type <<classname>> must be defined in its own file
- JAVA中 错误代码是 the public type must be defined in its own file 解决方法 android开发 java编程
- [置顶] JAVA中 错误代码是 the public type must be defined in its own file 解决方法 android开发 java编程
- JAVA中 错误代码是 the public type must be defined in its own file 解决方法 android开发 java编程
- JAVA错误:The public type *** must be defined in its own file***
- the public type xxx must be defined in its own file
- JAVA错误:The public type *** must be defined in its own file***
- the public type xxx must be defined in its own file
- The public type WebSocketTest must be defined in its own file
- the public type xxx must be defined in its own file
- java错误提示------ The public type must be defined in its own file
- 错误:the public type XXX must be defined in its own file.
- “The public type XYZ must be defined in its own file”解决方法
- The type org.eclipse.core.commands.common.EventManager cannot be resolved. It is indirectly referenced from required .class file
- A class file was not written. The project may be inconsistent, if so try refreshing this project and building it. eclipse提示错误
- The final local variable xxx cannot be assigned, since it is defined in an enclosing type
- 【转】The final local variable xxx cannot be assigned, since it is defined in an enclosing type
- android 引入别的项目The type java.lang.Class cannot be resolved. It is indirectly referenced from required
- The final local variable xxx cannot be assigned, since it is defined in an enclosing type“,