|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.espertech.esper.view.ViewSupport
com.espertech.esper.view.stat.UnivariateStatisticsView
public class UnivariateStatisticsView
View for computing statistics, which the view exposes via fields representing the sum, count, standard deviation for sample and for population and variance.
Field Summary | |
---|---|
protected AgentInstanceViewFactoryChainContext |
agentInstanceContext
|
protected BaseStatisticsBean |
baseStatisticsBean
|
protected java.lang.Object[] |
lastValuesEventNew
|
Fields inherited from class com.espertech.esper.view.ViewSupport |
---|
EMPTY_VIEW_ARRAY, parent |
Constructor Summary | |
---|---|
UnivariateStatisticsView(UnivariateStatisticsViewFactory viewFactory,
AgentInstanceViewFactoryChainContext agentInstanceContext)
Constructor requires the name of the field to use in the parent view to compute the statistics. |
Method Summary | |
---|---|
View |
cloneView()
Duplicates the view. |
static EventType |
createEventType(StatementContext statementContext,
StatViewAdditionalProps additionalProps,
int streamNum)
Creates the event type for this view. |
BaseStatisticsBean |
getBaseStatisticsBean()
|
EventType |
getEventType()
Provides metadata information about the type of object the event collection contains. |
ExprNode |
getFieldExpression()
Returns field name of the field to report statistics on. |
java.lang.Object[] |
getLastValuesEventNew()
|
ViewFactory |
getViewFactory()
|
java.util.Iterator<EventBean> |
iterator()
Allows iteration through all elements in this event collection. |
static EventBean |
populateMap(BaseStatisticsBean baseStatisticsBean,
EventAdapterService eventAdapterService,
EventType eventType,
StatViewAdditionalProps additionalProps,
java.lang.Object[] lastNewValues)
|
void |
setLastValuesEventNew(java.lang.Object[] lastValuesEventNew)
|
java.lang.String |
toString()
|
void |
update(EventBean[] newData,
EventBean[] oldData)
Notify that data has been added or removed from the Viewable parent. |
Methods inherited from class com.espertech.esper.view.ViewSupport |
---|
addView, addView, dumpChildViews, dumpUpdateParams, dumpUpdateParams, findDescendent, findViewIndex, getParent, getViews, hasViews, removeAllViews, removeView, removeView, setParent, updateChildren, updateChildren |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.espertech.esper.view.View |
---|
getParent, setParent |
Methods inherited from interface com.espertech.esper.view.Viewable |
---|
addView, getViews, hasViews, removeAllViews, removeView |
Field Detail |
---|
protected final AgentInstanceViewFactoryChainContext agentInstanceContext
protected final BaseStatisticsBean baseStatisticsBean
protected java.lang.Object[] lastValuesEventNew
Constructor Detail |
---|
public UnivariateStatisticsView(UnivariateStatisticsViewFactory viewFactory, AgentInstanceViewFactoryChainContext agentInstanceContext)
Method Detail |
---|
public View cloneView()
CloneableView
Expected to return a same view in initialized state for grouping.
cloneView
in interface CloneableView
public final ExprNode getFieldExpression()
public void update(EventBean[] newData, EventBean[] oldData)
View
update
in interface View
newData
- is the new data that has been added to the parent viewoldData
- is the old data that has been removed from the parent viewpublic final EventType getEventType()
EventCollection
getEventType
in interface EventCollection
public final java.util.Iterator<EventBean> iterator()
EventCollection
iterator
in interface EventCollection
iterator
in interface java.lang.Iterable<EventBean>
public final java.lang.String toString()
toString
in class java.lang.Object
public static EventBean populateMap(BaseStatisticsBean baseStatisticsBean, EventAdapterService eventAdapterService, EventType eventType, StatViewAdditionalProps additionalProps, java.lang.Object[] lastNewValues)
public static EventType createEventType(StatementContext statementContext, StatViewAdditionalProps additionalProps, int streamNum)
statementContext
- is the event adapter service
public BaseStatisticsBean getBaseStatisticsBean()
public java.lang.Object[] getLastValuesEventNew()
public void setLastValuesEventNew(java.lang.Object[] lastValuesEventNew)
public ViewFactory getViewFactory()
getViewFactory
in interface GroupableView
|
© 2006-2015 EsperTech Inc. All rights reserved. Visit us at espertech.com |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |