public void addMonitoringEventsToAllServices ( Events events ) { List < JAXBElement < ? extends EventType > > events_ = events . getEvent ( ) ; if ( events_ != null && ! events_ . isEmpty ( ) ) { for ( Bw service : this . getBWServices ( ) ) { Monitor monitor = service . getMonitor ( ) ; if ( monitor != null ) { monitor . setEvents ( events ) ; } } } }
Add &lt ; events > in &lt ; monitor > element of all &lt ; bw > elements .