gw.lang.enhancements.CoreIterableOfFloatsEnhancement.gsx Maven / Gradle / Ivy
package gw.lang.enhancements
uses java.lang.Float
/*
* Copyright 2014 Guidewire Software, Inc.
*/
enhancement CoreIterableOfFloatsEnhancement : java.lang.Iterable {
function sum() : Float {
var sum = 0.0 as float
for (elt in this) {
sum += elt
}
return sum
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy