|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.esper.view.ViewSupport
net.esper.view.std.AddPropertyValueView
public final class AddPropertyValueView
This view simply adds a property to the events posted to it. This is useful for the group-merge views.
Field Summary |
---|
Fields inherited from class net.esper.view.ViewSupport |
---|
parent |
Constructor Summary | |
---|---|
AddPropertyValueView(ViewServiceContext viewServiceContext,
String[] fieldNames,
Object[] mergeValues,
EventType mergedResultEventType)
Constructor. |
Method Summary | |
---|---|
protected static EventBean |
addProperty(EventBean originalEvent,
String[] propertyNames,
Object[] propertyValues,
EventType targetEventType,
EventAdapterService eventAdapterService)
Add a property to the event passed in. |
View |
cloneView(ViewServiceContext viewServiceContext)
|
EventType |
getEventType()
Provides metadata information about the type of object the event collection contains. |
String[] |
getPropertyNames()
Returns field name for which to set the merge value for. |
Object[] |
getPropertyValues()
Returns the value to set for the field. |
Iterator<EventBean> |
iterator()
Allows iteration through all elements in this event collection. |
void |
setParent(Viewable parent)
Called when the View is added to a Viewable object. |
String |
toString()
|
void |
update(EventBean[] newData,
EventBean[] oldData)
Notify that data has been added or removed from the Viewable parent. |
Methods inherited from class net.esper.view.ViewSupport |
---|
addView, dumpChildViews, dumpUpdateParams, findDescendent, getParent, getViews, hasViews, removeView, updateChildren, updateChildren |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AddPropertyValueView(ViewServiceContext viewServiceContext, String[] fieldNames, Object[] mergeValues, EventType mergedResultEventType)
fieldNames
- is the name of the field that is added to any events received by this view.mergeValues
- is the values of the field that is added to any events received by this view.mergedResultEventType
- is the event type that the merge view reports to it's child viewsviewServiceContext
- contains required view servicesMethod Detail |
---|
public View cloneView(ViewServiceContext viewServiceContext)
cloneView
in interface CloneableView
public void setParent(Viewable parent)
View
setParent
in interface View
setParent
in class ViewSupport
parent
- is the parent that this view is a child ofpublic final String[] getPropertyNames()
public final Object[] getPropertyValues()
public final 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 Iterator<EventBean> iterator()
EventCollection
iterator
in interface Iterable<EventBean>
iterator
in interface EventCollection
protected static EventBean addProperty(EventBean originalEvent, String[] propertyNames, Object[] propertyValues, EventType targetEventType, EventAdapterService eventAdapterService)
originalEvent
- - event to add property topropertyNames
- - names of properties to addpropertyValues
- - value of properties to addtargetEventType
- - new event typeeventAdapterService
- - service for generating events and handling event types
public final String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |