corda / net.corda.client.fxutils / javafx.collections.ObservableList / associateByAggregation

# associateByAggregation

`fun <K : Any, A : Any, B> ObservableList<out A>.associateByAggregation(toKey: (A) -> K, assemble: (K, A) -> B): ObservableMap<K, ObservableList<B>>`

val people: ObservableList = (..) val heightToNames: ObservableMap<Long, ObservableList> = people.associateByAggregation(Person::height) { name, person -> person.name }

`fun <K : Any, A : Any> ObservableList<out A>.associateByAggregation(toKey: (A) -> K): ObservableMap<K, ObservableList<A>>`

val people: ObservableList = (..) val heightToPeople: ObservableMap<Long, ObservableList> = people.associateByAggregation(Person::height)