T - The type of value the pane statistics.public class Pane<T> extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
long |
getEndInMs()
Get end timestamp of the pane in milliseconds.
|
long |
getIntervalInMs()
Get the interval of the pane in milliseconds.
|
long |
getStartInMs()
Get start timestamp of the pane in milliseconds.
|
T |
getValue()
Get the pane statistics value.
|
boolean |
isTimeInWindow(long timeMillis)
Check whether given timestamp is in current pane.
|
void |
setStartInMs(long newStartInMs)
Set the new start timestamp to the pane, for reset the instance.
|
void |
setValue(T newData)
Set new value to the pane, for reset the instance.
|
public Pane(long intervalInMs,
long startInMs,
T value)
intervalInMs - interval of the pane in milliseconds.startInMs - start timestamp of the pane in milliseconds.value - the pane value.public long getIntervalInMs()
public long getStartInMs()
public long getEndInMs()
public T getValue()
public void setStartInMs(long newStartInMs)
newStartInMs - the new start timestamp.public void setValue(T newData)
newData - the new value.public boolean isTimeInWindow(long timeMillis)
timeMillis - timestamp in milliseconds.Copyright © 2011–2020 The Apache Software Foundation. All rights reserved.