fun <P : Any> Iterable<ContractState>.sumObligationsOrNull(): Amount<Issued<Terms<P>>>?
Sums the obligation states in the list, returning null if there are none.