Top Description Fields Constructors Methods
org.reactfx

pack-priv Class LatestNStream<T>

extends EventStreamBase<List<T>>
Class Inheritance
Imports
java.util.ArrayList, .Collections, .List, org.reactfx.util.Lists

See EventStream#latestN(int)

Field Summary

Modifier and TypeField and Description
private List<T>
private List<T>
private final int
n

private List<T>
private final EventStream<T>

Constructor Summary

AccessConstructor and Description
public
LatestNStream(EventStream<T> source, int n)

Method Summary

Modifier and TypeMethod and Description
protected Subscription
observeInputs()

Implements abstract org.reactfx.ObservableBase.observeInputs.

Starts observing this observable's input(s), if any.

private void
onEvent(T event)

Field Detail

concatViewback to summary
private List<T> concatView
firstback to summary
private List<T> first
nback to summary
private final int n
secondback to summary
private List<T> second
sourceback to summary
private final EventStream<T> source

Constructor Detail

LatestNStreamback to summary
public LatestNStream(EventStream<T> source, int n)

Method Detail

observeInputsback to summary
protected Subscription observeInputs()

Implements abstract org.reactfx.ObservableBase.observeInputs.

Doc from org.reactfx.ObservableBase.observeInputs.

Starts observing this observable's input(s), if any. This method is called when the number of observers goes from 0 to 1. This method is called before newObserver(Object) is called for the first observer.

Annotations
@Override
onEventback to summary
private void onEvent(T event)