由网友(好未来需努力)分享简介:如何获得当前时间的Android?当我使用INT小时= java.sql.Time.this.getHours();我得到的错误:的类型时没有封闭实例处于范围访问解决方案 INT小时=新的时间(System.currentTimeMillis的())getHours()。How to get the curre...
如何获得当前时间的Android?
当我使用
INT小时= java.sql.Time.this.getHours();
我得到的错误:
的类型时没有封闭实例处于范围访问
解决方案
INT小时=新的时间(System.currentTimeMillis的())getHours()。
How to get the current time in Android?
When i use
int hours = java.sql.Time.this.getHours();
i get the error:
No enclosing instance of the type Time is accessible in scope
解决方案
int hours = new Time(System.currentTimeMillis()).getHours();
相关推荐
最新文章