java.lang.Object
dev.metaschema.core.metapath.function.library.FnSum

public final class FnSum extends Object
Implements the XPath 3.1 fn:sum functions.
  • Method Details

    • sum

      @Nullable public static IAnyAtomicItem sum(@NonNull List<? extends IAnyAtomicItem> items, @Nullable IAnyAtomicItem zero)
      An implementation of XPath 3.1 fn:sum.
      Parameters:
      items - the items to sum
      zero - the value to use if no items are provided, which can be null
      Returns:
      the average