Class FnDistinctValues

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

public final class FnDistinctValues extends Object
Implements fn:distinct-values functions. This implementation does not implement the two-arg variant with collation at this time.
  • Method Details

    • fnDistinctValues

      @NonNull public static Stream<IAnyAtomicItem> fnDistinctValues(@NonNull List<IAnyAtomicItem> values, @NonNull DynamicContext dynamicContext)
      Get the first occurrence of each distinct value in the provided list.

      Based on the XPath 3.1 fn:distinct-values function.

      Parameters:
      values - the items to get distinct values for
      dynamicContext - used to provide evaluation information, including the implicit timezone
      Returns:
      a the list of distinct values