Witam,

przy odwołaniu do klasy wygenerowanej przez JAXB dostaję błąd jak poniżej:

TREŚĆ BŁĘDU:

Connection IO Exception. Check nested exception for details. (Connection IO Exception. Check nested exception for details. (Field {http://test/kmd/wspolne/v1}Naglowek could not be found in the outbound bean pl.test.kmd.dostawca.v1.testowy.WeryfikujDostawcaMsgTyp).

Nie bardzo rozumiem czym to jest spowodawne i gdzie jest błąd. Jeśli ktoś byłby w stanie pomóc byłbym bardzo wdzięczny.

Wywołanie:

        	
...
NaglowekTyp _weryfikujDostawca_naglowek = new NaglowekTyp();
        	DostawcaTyp _weryfikujDostawca_dane = new DostawcaTyp();
		port.weryfikujDostawca(_weryfikujDostawca_naglowek, _weryfikujDostawca_dane);
...
 

Fragment pliku XSD:

...
  <xsd:complexType name="WeryfikujDostawcaMsgTyp">
    <xsd:complexContent>
      <!-- kazdy typ komunikatu rozszerza KomunikatTyp i dodaje element Dane -->
      <xsd:extension base="kmdwsp:KomunikatTyp">
        <xsd:sequence>
          <!-- type decyduje jaki jest payload komunikatu. Tutaj: Identyfikacja. -->
          <xsd:element name="Dane" type="DostawcaTyp"/>
        </xsd:sequence>
      </xsd:extension>
    </xsd:complexContent>
...
 

KomunikatTyp:

...
  <xsd:complexType name="KomunikatTyp">
    <xsd:sequence>
      <xsd:element name="Naglowek" type="NaglowekTyp"/>
    </xsd:sequence>
  </xsd:complexType>
....
 

WYGENEROWANY JAXB WeryfikujDostawceMsg:

package pl.test.kmd.dostawca.v1.custom;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
import pl.test.kmd.wspolne.v1.KomunikatTyp;


/**
 * <p>Java class for WeryfikujDostawcaMsgTyp complex type.
 * 
 * <p>The following schema fragment specifies the expected content contained within this class.
 * 
 * <pre>
 * &lt;complexType name="WeryfikujDostawcaMsgTyp">
 *   &lt;complexContent>
 *     &lt;extension base="{http://test/kmd/wspolne/v1}KomunikatTyp">
 *       &lt;sequence>
 *         &lt;element name="Dane" type="{http://test/kmd/Dostawca/v1}DostawcaTyp"/>
 *       &lt;/sequence>
 *     &lt;/extension>
 *   &lt;/complexContent>
 * &lt;/complexType>
 * </pre>
 * 
 * 
 */
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "WeryfikujDostawcaMsgTyp", propOrder = {
    "dane"
})
public class WeryfikujDostawcaMsgTyp
    extends KomunikatTyp
{

    @XmlElement(name = "Dane", required = true)
    protected DostawcaTyp dane;

    /**
     * Gets the value of the dane property.
     * 
     * @return
     *     possible object is
     *     {@link DostawcaTyp }
     *     
     */
    public DostawcaTyp getDane() {
        return dane;
    }

    /**
     * Sets the value of the dane property.
     * 
     * @param value
     *     allowed object is
     *     {@link DostawcaTyp }
     *     
     */
    public void setDane(DostawcaTyp value) {
        this.dane = value;
    }

}

package-info.java

@javax.xml.bind.annotation.XmlSchema(namespace = "http://test/kmd/Dostawca/v1", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
package pl.test.kmd.dostawca.v1.custom;

Dodam, że klasy generowane były z wykorzystanie wsdl2java z ApacheCXF 2.7.1.