Element nestedBean = DomUtils.getChildElementByTagName(listener, "bean");
if (nestedBean == null) {
//no 'ref' and no nested beans, add the default debug listeners part of the core libs.
Object obj = null;
if (TYPE_AGENDA_EVENT_LISTENER.equalsIgnoreCase(listenerType)) {
obj = new DebugAgendaEventListener();
} else if (TYPE_PROCESS_EVENT_LISTENER.equalsIgnoreCase(listenerType)) {
obj = new DebugProcessEventListener();
} else if (TYPE_WORKING_MEMORY_EVENT_LISTENER.equalsIgnoreCase(listenerType)) {
obj = new DebugWorkingMemoryEventListener();
}