logger.debug("Added new Event: \n"+event.toString() );
if (logger.isDebugEnabled()) logger.debug("Added new Event: \n"+event.toString() );
    protected Vector processElement(Element element) {                String eventName = element.getAttribute("name");        String assetType = element.getAttribute("affectsAssetType");        String stateDim = element.getAttribute("affectsStateDimension");                AssetType affectsAssetType = AssetType.findAssetType(assetType);        //Report error if asset type wasn't found        if (affectsAssetType == null) {            logger.error("Event XML Error - affectsAssetType unknown: "+assetType);            return null;        }                AssetStateDimension asd = affectsAssetType.findStateDimension(stateDim);        //what to do when assetType is null? - create it, process it later?        if (asd == null) {            logger.error("Event XML Error - asset state dimension not found! unknown dimension: "+stateDim+ " for asset type = " + assetType);            return null;        }                if (us == null) {            logger.warn("Event XML Error - UIDService is null!");            return null;        }                UID uid = us.nextUID();        //Create default threat        EventDescription event = new EventDescription( eventName, affectsAssetType, asd );        Element e;        for (Node child = element.getFirstChild(); child != null; child = child.getNextSibling()) {            if (child.getNodeType() == Node.ELEMENT_NODE && child.getNodeName().equalsIgnoreCase("DirectEffect") ) {                e = (Element)child;                parseDirectEffect(e, event);            } else if (child.getNodeType() == Node.ELEMENT_NODE && child.getNodeName().equalsIgnoreCase("TransitiveEffect") ) {                e = (Element)child;                parseTransitiveEffect(e, event);            } //else, likely a text element - ignore        }                //Now verify that all states are covered by this action - we have closure -- if not, do not add action.        boolean error = false;        Iterator states = asd.getPossibleStates().iterator();        while ( states.hasNext() ) {            AssetState as = (AssetState) states.next();            if ( event.getDirectEffectTransitionForState(as) == null) {                logger.error(" ERROR: cannot find transition from "+assetType+":"+asd.getStateName()+":"+as.getName()+ " --> IGNORING EVENT ["+event.getName()+"]!!");                error = true;            }        }        if (!error) {            events.add(event);            logger.debug("Added new Event: \n"+event.toString() );        }                return events;    }