public static class FoldingWindowBuffer.Factory<T,ACC> extends Object implements WindowBufferFactory<T,ACC,FoldingWindowBuffer<T,ACC>>
Constructor and Description |
---|
Factory(FoldFunction<T,ACC> foldFunction,
ACC initialValue,
TypeSerializer<ACC> accSerializer) |
Modifier and Type | Method and Description |
---|---|
FoldingWindowBuffer<T,ACC> |
create()
Creates a new
WindowBuffer . |
FoldingWindowBuffer<T,ACC> |
restoreFromSnapshot(DataInputView in)
Restores a
WindowBuffer from a previous snapshot written using
WindowBuffer.snapshot(DataOutputView) . |
public Factory(FoldFunction<T,ACC> foldFunction, ACC initialValue, TypeSerializer<ACC> accSerializer)
public FoldingWindowBuffer<T,ACC> create()
WindowBufferFactory
WindowBuffer
.create
in interface WindowBufferFactory<T,ACC,FoldingWindowBuffer<T,ACC>>
public FoldingWindowBuffer<T,ACC> restoreFromSnapshot(DataInputView in) throws IOException
WindowBufferFactory
WindowBuffer
from a previous snapshot written using
WindowBuffer.snapshot(DataOutputView)
.restoreFromSnapshot
in interface WindowBufferFactory<T,ACC,FoldingWindowBuffer<T,ACC>>
IOException
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.