code: private String getElementValue(Element parent, String elementName) {
          String value = null;
          NodeList nodes = parent.getElementsByTagName(elementName);
          if (nodes.getLength() > 0) {
              value = nodes.item(0).getChildNodes().item(0).getNodeValue();
          }
          return value;
      }
docs: Gets the element value.
  
  @param parent the parent
  @param elementName the element name
  @return the element value