Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
用当前时间进行停止观看
Instant.now().toString()
或:
ZonedDateTime.now().format( DateTimeFormatter.ofLocalizedDateTime( FormatStyle.LONG ) )
从当前设备时间开始计算时间
Instant start = Instant.now() ;
当我单击停止时应停止
Instant end = Instant.now() ;
计算开始和停止时间之间的差异。
Duration elapsed = Duration.between( start , end ) ;
显示时间是15分钟的工作
long minutesElapsed = elapsed.toMinutes() ;
当前开始和停止时间。
DateTimeFormatter f = DateTimeFormatter.ofLocalizedDateTime( FormatStyle.FULL ) ; String output = start.atZone( ZoneId.systemDefault() ).format( f ) + " to " + end.atZone( ZoneId.systemDefault() ).format( f ) + " is " + minutesElapsed + " minutes." ;
make stop watch with current time
Or:
start calculation time from current device time
when i click on stop ut should stop
calculating difference between start and stop time.
show the time is 15 minute of work
with current start and stop time.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
暂无简介
文章 0 评论 0
接受
发布评论
评论(1)
或:
Or: