protected Boolean nodeToBoolean(BeanProp prop) { // If there is a node, that means the empty node exists (true) // If there is no node set, we might just not be attached to // a parent node right now, check our prop //System.out.println("node="+node+" getBean(prop)="+this.getBean(prop)); if (node == null) { Object result = getBean(prop); if (result == null) return Boolean.FALSE; //System.out.println("!!! node was null, but prop has something. prop="+prop); return (Boolean) result; } else { String ret = getDomValue(node); //System.out.println("ret="+ret); if (ret == null) return Boolean.TRUE; ret = ret.toLowerCase().intern(); if (ret == "false" || ret == "0") return Boolean.FALSE; // Just the node being there and not saying false is enough to // be true. return Boolean.TRUE; } }
bean = (BaseBean)newBinding.getBean(matchingProp); else bean = null;