类 WindowBuilder<T>

  • 所有已实现的接口:
    Window<T>

    public class WindowBuilder<T>
    extends Object
    implements Window<T>
    作者:
    caizhiao
    • 字段详细资料

      • sorter

        protected Sorter<T> sorter
    • 构造器详细资料

      • WindowBuilder

        public WindowBuilder()
      • WindowBuilder

        public WindowBuilder​(Sorter<T> comparator)
      • WindowBuilder

        public WindowBuilder​(List<java.util.function.Function<T,​?>> groupBy)
    • 方法详细资料

      • initDefault

        public void initDefault()
      • partitions

        public List<java.util.function.Function<T,​?>> partitions()
        从接口复制的说明: Window
        get partitions info
        指定者:
        partitions 在接口中 Window<T>
      • sortAsc

        public <U extends Comparable<? super U>> Window<T> sortAsc​(java.util.function.Function<T,​U> sortField)
        从接口复制的说明: Window
        Sort windows in ascending order according to specified fields
        指定者:
        sortAsc 在接口中 Window<T>
        参数:
        sortField - sort field
      • sortDesc

        public <U extends Comparable<? super U>> Window<T> sortDesc​(java.util.function.Function<T,​U> sortField)
        从接口复制的说明: Window
        Sort windows in descending order according to specified fields
        指定者:
        sortDesc 在接口中 Window<T>
        参数:
        sortField - sort field
      • sort

        public Window<T> sort​(Comparator<T> comparator)
        从接口复制的说明: Window
        sort window by Comparator
        指定者:
        sort 在接口中 Window<T>
        参数:
        comparator - sort comparator
      • roundBefore2CurrentRow

        public Window<T> roundBefore2CurrentRow​(int n)
        从接口复制的说明: Window
        Specify window range this range is form the first n lines of the current row to the current row
        指定者:
        roundBefore2CurrentRow 在接口中 Window<T>
        参数:
        n - The first n lines of the current row
      • roundCurrentRow2After

        public Window<T> roundCurrentRow2After​(int n)
        从接口复制的说明: Window
        Specify window range this range is form the current row to the last n row of the current row
        指定者:
        roundCurrentRow2After 在接口中 Window<T>
        参数:
        n - the last n row of the current row
      • roundCurrentRow2EndRow

        public Window<T> roundCurrentRow2EndRow()
        从接口复制的说明: Window
        Specify window range this range is form the current row to the end row
        指定者:
        roundCurrentRow2EndRow 在接口中 Window<T>
      • roundStartRow2CurrentRow

        public Window<T> roundStartRow2CurrentRow()
        从接口复制的说明: Window
        Specify window range this range is form the start row to the current row
        指定者:
        roundStartRow2CurrentRow 在接口中 Window<T>
      • roundAllRow

        public Window<T> roundAllRow()
        从接口复制的说明: Window
        Specify window range this range is window all row
        指定者:
        roundAllRow 在接口中 Window<T>
      • roundBeforeAfter

        public Window<T> roundBeforeAfter​(int before,
                                          int after)
        从接口复制的说明: Window
        Specify window range this range is from before n row of current row to after n row of current row
        指定者:
        roundBeforeAfter 在接口中 Window<T>
        参数:
        before - before n row of current row
        after - after n row of current row