fun <P : Any> Iterable<ContractState>.sumObligations(): Amount<Issued<Terms<P>>>
Sums the obligation states in the list, throwing an exception if there are none. All state objects in the list are presumed to be nettable.