@Test public void testupdateChild() { Map<String, Object> values = new HashMap<String, Object>(); values.put("a", 1); values.put("b", 1); values.put("c", "c1"); IEvent event1 = new TupleEvent("stream", eventType, values); values.put("a", SupportConst.I_TWO); values.put("b", SupportConst.I_TWO); values.put("c", "c2"); IEvent event2 = new TupleEvent("stream", eventType, values); values.put("a", SupportConst.I_THREE); values.put("b", SupportConst.I_THREE); values.put("c", "c3"); IEvent event3 = new TupleEvent("stream", eventType, values); values.put("a", SupportConst.I_FOUR); values.put("b", SupportConst.I_FOUR); values.put("c", "c4"); IEvent event4 = new TupleEvent("stream", eventType, values); values.put("a", SupportConst.I_FIVE); values.put("b", SupportConst.I_FIVE); values.put("c", "c5"); IEvent event5 = new TupleEvent("stream", eventType, values); top.addView(child1); top.addView(child2); top.update(new IEvent[] {event3, event4, event5}, new IEvent[] {event1, event2}); SupportViewDataCheck.checkOldData(child1, new IEvent[] {event1, event2}); SupportViewDataCheck.checkNewData(child1, new IEvent[] {event3, event4, event5}); SupportViewDataCheck.checkOldData(child2, new IEvent[] {event1, event2}); SupportViewDataCheck.checkNewData(child2, new IEvent[] {event3, event4, event5}); }
public void updateChild(IEvent[] newData, IEvent[] oldData) { for (IView child : subViews) { child.update(newData, oldData); } }
ViewImpl implements IView { public void updateChild(IEvent[] newData, IEvent[] oldData) { for (IView child : subViews) { child.update(newData, oldData); } } }
ViewImpl implements IView { public void updateChild(IEvent[] newData, IEvent[] oldData) { for (IView child : subViews) { child.update(newData, oldData); } } ViewImpl(); }
ViewImpl implements IView { public void updateChild(IEvent[] newData, IEvent[] oldData) { for (IView child : subViews) { child.update(newData, oldData); } } ViewImpl(); void removeAllViews(); List<IView> getViews(); boolean hasViews(); IViewable getParent(); void setParent(IViewable parent); IView addView(IView view); boolean removeView(IView view); void updateChild(IEvent[] newData, IEvent[] oldData); @Override void start(); @Override void stop(); }
ViewImpl implements IView { public void updateChild(IEvent[] newData, IEvent[] oldData) { for (IView child : subViews) { child.update(newData, oldData); } } ViewImpl(); void removeAllViews(); List<IView> getViews(); boolean hasViews(); IViewable getParent(); void setParent(IViewable parent); IView addView(IView view); boolean removeView(IView view); void updateChild(IEvent[] newData, IEvent[] oldData); @Override void start(); @Override void stop();  }