会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
test
Lechance's Homepage
The code to change the world
博客园
首页
联系
订阅
管理
2015年1月30日
Cannot make a static reference to the non-static method的解决方案
摘要: 报错原因:在一个类中写了一个public String getContent()方法和一个main()方法,getContent()方法中包含了getClass()方法,在main()方法中直接调用了getContent()就出现如题的错误。这样一样解决方法:先实例化类,然后再调用getConten...
阅读全文
posted @ 2015-01-30 14:47 Lechance
阅读(345)
评论(0)
推荐(0)
公告