var firstTimeView = true
run {
if (firstTimeView) text_view_01 else text_view_02
}.visibility = View.GONE
相当于Java里面的
firstTimeView? A:B
var firstTimeView = true
run {
if (firstTimeView) text_view_01 else text_view_02
}.visibility = View.GONE
相当于Java里面的
firstTimeView? A:B
本文标题:Kotlin run的用法
本文链接:https://www.haomeiwen.com/subject/pnbemftx.html
网友评论