title: How to get value of XML tag with different attributes?
body: <p>I need to get value from XML tag with different attributes.</p>
  
  <p>For example:
  XML</p>
  
  <pre><code>&lt;metaData&gt;
      &lt;parameter name="HTTP-Method"&gt;POST&lt;/parameter&gt;
      &lt;parameter name="HTTP-URI"&gt;/loan/test?testArg=1234&amp;amp;id=5555555&lt;/parameter&gt;
      &lt;parameter name="HTTP-Version"&gt;HTTP/1.1&lt;/parameter&gt;
      &lt;parameter name="Host"&gt;localhost:7002&lt;/parameter&gt;
      &lt;parameter name="Content-Length"&gt;0&lt;/parameter&gt;
      &lt;parameter name="Origin"&gt;chrome-extension://fhbjgbiflinjbdggehcddcbncdddomop&lt;/parameter&gt;
  &lt;/netaData&gt;
  </code></pre>
  
  <p>here I need to get a value of tag "parameter" with an attribute "HTTP-Method"
  and another one with attribute "HTTP-URI"</p>
  
  <p>This what I do:</p>
  
  <pre><code>NodeList nodeList = document.getElementsByTagName("parameter");
  for (int i = 0, size = nodeList.getLength(); i &lt; size; i++) {
          Element elem = (Element) nodeList.item(i);
  </code></pre>
  
  <p>Here I got all the parameter tags. How can I get the specific one?</p>