i have this:
val vertexIdListPartitions: TrieMap[Long, List[Long]] = TrieMap()
i need to add List(3) at vertexIdListPartitio
List(3)
vertexIdListPartitio
Mutable collections have the update() method for this.
update()
vertexIdListPartitions.update(3L, List(3)) //res0: Unit = () vertexIdListPartitions //res1: TrieMap[Long,List[Long]] = TrieMap(3 -> List(3))