title: Jaxb: Unmarshaller cannot find element with namespace and prefix
body: <p>I receive xml that look like:</p>
  
  <pre><code>&lt;result xmlns="firstUri"&gt;
      &lt;blackList xmlns:ns1="secondUri"&gt;
          &lt;ns2:BlackList xmlns:ns2="thirdUri"&gt;
              &lt;name xmlns="thirdUri"&gt;some value&lt;/name&gt;
              &lt;nameFlag xmlns="thirdUri"&gt;some value&lt;/nameFlag&gt;
          &lt;/ns2:BlackList&gt;
          &lt;ns2:BlackList xmlns:ns2="thirdUri"&gt;
              &lt;name xmlns="thirdUri"&gt;some value&lt;/name&gt;
              &lt;nameFlag xmlns="thirdUri"&gt;some value&lt;/nameFlag&gt;
          &lt;/ns2:BlackList&gt;
               ..........................................................
      &lt;/blackList&gt;
      &lt;retCode xmlns:ns1="secondUri"&gt;0&lt;/retCode&gt;
      &lt;retDesc xmlns:ns1="secondUri"&gt;Succeeded&lt;/retDesc&gt;
  &lt;/result&gt;
  </code></pre>
  
  <p>And I want to unmarshal it to object.</p>
  
  <p>I created following bean:</p>
  
  <pre><code>@XmlRootElement(name = "result", namespace ="firstUri")
  public class GetBlackListResp {
      protected String retCode;
      protected String retDesc;
      protected List&lt;BlackListItem&gt; blackListArray;
  
      @XmlRootElement(name = "BlackList", namespace = "thirdUri") 
      public static class BlackListItem{
          protected String name;
          protected String nameFlag;
  
          @XmlElement(name = "name", namespace = "thirdUri")
          public String getName() {
              return name;
          }
          public void setName(String name) {
              this.name = name;
          }
  
          @XmlElement(name = "nameFlag", namespace = "thirdUri")
          public String getNameFlag() {
              return nameFlag;
          }
          public void setNameFlag(String nameFlag) {
              this.nameFlag = nameFlag;
          }
  }    
  
  
      @XmlElement(name = "retCode", namespace = "firstUri")
      public String getRetCode() {
          return retCode;
      }
  
      public void setRetCode(String retCode) {
          this.retCode = retCode;
      }
  
      @XmlElement(name = "retDesc", namespace = "firstUri")
      public String getRetDesc() {
          return retDesc;
      }
  
      public void setRetDesc(String retDesc) {
          this.retDesc = retDesc;
      }
  
      @XmlElement(name = "blackList", namespace = "firstUri")
      public List&lt;BlackListItem&gt; getBlackList() {
          return blackListArray;
      }
  
      public void setBlackList(List&lt;BlackListItem&gt; blackListArray) {
          this.blackListArray = blackListArray;
      }
  }
  </code></pre>
  
  <p>After unmarshalling I got object, which is successful filled, except blackListArray field. That field contain list, which have only one item. And all fields in that item are nulls.</p>
  
  <p>It seems like JAXB can find  element, but miss all inner  elements inside it.</p>
  
  <p>I use MOXy as JAXB implementation.</p>
  
  <p>P.S.</p>
  
  <p>I tried put package-info.java in folder with my bean as say in <a href="https://stackoverflow.com/questions/19395400/jaxb-unmarshall-with-namespaces-and-prefix">that question</a></p>
  
  <pre><code>@XmlSchema(
      elementFormDefault=XmlNsForm.QUALIFIED,
      namespace="thirdUri",
      xmlns={@XmlNs(prefix="ns2", 
                    namespaceURI="thirdUri")}
  )
  package package.with.my.bean;
  
  import javax.xml.bind.annotation.XmlNs;
  import javax.xml.bind.annotation.XmlNsForm;
  import javax.xml.bind.annotation.XmlSchema;
  </code></pre>
  
  <p>But it did not help for me.</p>