protected String getNodeContent(Element e, String key) {
       NodeList nodes = e.getElementsByTagName(key);
       String result = null;
       if (nodes != null && nodes.getLength() > 0) {
           result = getNodeTextValue(nodes.item(0));
       }
       return (result == null || result.length() == 0)? null: result;
   }
protected String getNodeContent ( Element e , String key ) { NodeList nodes = e . getElementsByTagName ( key ) ; String result = null ; if ( nodes != null && nodes . getLength ( ) > 0 ) { result = getNodeTextValue ( nodes . item ( 0 ) ) ; } return ( result == null || result . length ( ) == 0 ) ? null : result ; }
extract the text content of a single tag under a node