Interface IItemCollection

    • Method Detail

      • apply

        IItemCollection apply​(IItemFilter filter)
        Creates a new item collection with all items in this collection that pass through the filter. The collection may be eagerly or lazily evaluated.
        filter - the filter to use when selecting items for the new collection
        a new collection of items
      • getAggregate

        <V,​C extends IItemConsumer<C>> V getAggregate​(IAggregator<V,​C> aggregator)
        Calculates an aggregated value for the items in this collection.
        Type Parameters:
        V - aggregate result value type
        C - Item consumer type. See IAggregator.
        the aggregated value
      • hasItems

        boolean hasItems()
        true if the collections contains items, false otherwise
      • getUnfilteredTimeRanges

        Set<IRange<IQuantity>> getUnfilteredTimeRanges()
        Returns a set of IRange representations of the time ranges represented by this item collection. This set is not affected by any filtering operations on the item collection since its use is to show the time ranges in which events could possibly have been occurred.
        a set of IRange objects representing the time ranges available in this IItemCollection
      • values

        default <T> Supplier<Stream<T>> values​(IAttribute<T> attribute)
        Returns the values for the supplied attribute from this IItemCollection.
        Type Parameters:
        T - the type of the attribute, e.g. IQuantity.
        attribute - the attribute to retrieve values for.
        a stream of values.