Ciao, ho un problema analogo al tuo e sono giorni che sto impazzendo ma con scarsi risultati. Ho trovato ora la tua soluzione ma continua a non funzionarmi.
Ho provato sia la prima soluzione aggiungendo
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "richiestaPrecheckMessaggioSIIType", namespace = "http://www.acquirenteunico.it/schemas/2010/SII_AU/MessaggioSII")
public class RichiestaPrecheckMessaggioSIIType
extends MessaggioSIIType
{
@XmlAttribute(name = "type", namespace = XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI)
private String xsiType = "richiestaPrecheckMessaggioSIIType";
}
Che la seconda soluzione aggiungendo lo @SchemaValidation ma anche qui senza risultati
@WebService(targetNamespace = "http://www.sii.acquirenteunico.it/PK1", name = "PK1")
@XmlSeeAlso({ObjectFactory.class})
@SOAPBinding(style = SOAPBinding.Style.RPC)
@SchemaValidation(type = SchemaValidationType.OUT)
public interface PK1 {
@WebMethod(operationName = "PK1.0050", action = "PK1.0050")
@WebResult(name = "MessaggioSII", targetNamespace = "http://www.sii.acquirenteunico.it/PK1", partName = "MessaggioSII")
public AmmissibilitaVerificaMessaggioSIIType pk10050(
@WebParam(partName = "MessaggioSII", name = "MessaggioSII")
RichiestaPrecheckMessaggioSIIType messaggioSII
);
@WebMethod(operationName = "PK1.0051", action = "PK1.0051")
@WebResult(name = "MessaggioSII", targetNamespace = "http://www.sii.acquirenteunico.it/PK1", partName = "MessaggioSII")
public EsitoIntegrazioneRichiestaMessaggioSIIType pk10051(
@WebParam(partName = "MessaggioSII", name = "MessaggioSII")
IntegrazioneRichiestaPrecheckMessaggioSIIType messaggioSII
);
}
Cosa sto sbagliando? l'errore che continuo a ricevere MessaggioSII without attributes (xsi:type is requred)
Spero tu possa essermi di aiuto, grazie in anticipo Manuel.