使用MutableList代替List,添加使用add方法,如下: var tbList: MutableList<TestBean> = ArrayList() var tb = TestBean() tb.age = 12 tb.name = "Lord"
確定! 回上一頁