what is difference between mutable and immutable property of collection in kotlin

If you need an empty read-only collection, you can call the emptyList function: var valueContractTransactionsVO: Collection<ValueContractTransactionVO> = emptyList() And if the type of valueContractTransactionsVO being a Collection is not significant for your case, you can specify the type argument of the emptyList function and let the compiler to infer its type to List<ValueContractTransactionVO>: var valueContractTransactionsVO … Read more