JAXB issue

Hello everybody,
i'm working with a simple example of JAXB. It's an example from the Java Web Services Tutorial. I generated and compiled the classes from an xml schema file. But when i try to use them it gives me this error:
javax.xml.bind.JAXBException: Provider com.sun.xml.bind.v2.ContextFactory not found
- with linked exception:
[java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory]
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:151)
at javax.xml.bind.ContextFinder.find(ContextFinder.java:299)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:372)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:337)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:244)
at Main.main(Main.java:38)
Caused by: java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:116)
... 5 more
this is the line in Main.java:
JAXBContext jc = JAXBContext.newInstance( "po" );
where po is the package of the generated classes. I don't know where to look for the ContextFactory, it is not in javaee.jar...
please, any ideas???

hi i am getting DefaultValidationEventHandler: [FATAL_ERROR]: unexpected element (uri:"http://schemas.xmlsoap.org/soap/envelope/", local:"Envelope"). Expected elements are (none) error.
My xsd is:
<?xml version="1.0" encoding="UTF-8"?>
<!-- May 30, 2006 -->
<xsd:schema elementFormDefault="qualified" attributeFormDefault="unqualified"
targetNamespace="http://www.csapi.org/schema/parlayx/sms/v2_2"
xmlns:parlayx_sms_xsd="http://www.csapi.org/schema/parlayx/sms/v2_2"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:complexType name="DeliveryInformation">
<xsd:sequence>
<xsd:element name="address" type="xsd:anyURI"/>
<xsd:element name="deliveryStatus" type="parlayx_sms_xsd:DeliveryStatus"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="SmsMessage">
<xsd:sequence>
<xsd:element name="message" type="xsd:string"/>
<xsd:element name="senderAddress" type="xsd:anyURI"/>
<xsd:element name="smsServiceActivationNumber" type="xsd:anyURI"/>
<xsd:element name="dateTime" type="xsd:dateTime" minOccurs="0" maxOccurs="1"/>
</xsd:sequence>
</xsd:complexType>
<xsd:simpleType name="DeliveryStatus">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="DeliveredToNetwork"/>
<xsd:enumeration value="DeliveryUncertain"/>
<xsd:enumeration value="DeliveryImpossible"/>
<xsd:enumeration value="MessageWaiting"/>
<xsd:enumeration value="DeliveredToTerminal"/>
<xsd:enumeration value="DeliveryNotificationNotSupported"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="SmsFormat">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Ems"/>
<xsd:enumeration value="SmartMessaging"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:schema>
AND XML FILE COMING FOR SOAP IS:
<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns1="http://www.csapi.org/schema/parlayx/sms/send/v2_2/local"
xmlns:ns2="http://www.csapi.org/schema/parlayx/common/v2_1">
<soapenv:Body>
<ns1:sendSms>
<ns1:addresses>tel:123</ns1:addresses>
<ns1:senderName>tel:07123456789</ns1:senderName>
<ns1:message>Hello World!</ns1:message>
</ns1:sendSms></soapenv:Body>
</soapenv:Envelope>
please help me.

Similar Messages

  • Help in resolving JAXB issue.

    HI
    I have an element called currency which has a default value as "USD".
    The xml schema entry for this element is as shown below:
    <xsd:element name="currency" type="xsd:string" default ="USD" />
    when i generate JAXB objects, the default value for this element is not getting initialized to the variable defined for this element.
    can anyone help me in getting this information into the JAXB object that gets generated by xjc.
    do i need to provide any custom binging configuration for this.
    Thanks in advance.
    Bala

    I have the same problem.
    I tried to reset without resolving.
    I tried also to remove Whatsapp and viber, than changed the current date to a date in the past, I installed Whatsapp and Viber and accepted the push notification. Also in this the problem is not resolved.
    I confirm that the problem started after the update to ios 8.1
    Regards

  • JAXB : Issue with include XSDs

    Hi..
    I fail to generate JAXB Schema Driven Classes when I try to use a XSD which has xsd:include tag inside. Due to this include XSD, I am getting compilation error while I try to generate files using xjc command.
    Hope JAXB will have solution for handling include tags in XSD Schemas.
    Pl provide me the solution.
    Thanks in advance.
    Venkki.

    Thanx for ur quick response.
    Can u pl send me the xjc command to generate JAXB Schema Driven Classes?
    sothat I can verify whether any changes I need to do with that command for including schemas?
    Regards,
    Venkatesan R

  • JAXB unmarshalling elements with xs:type explicitly set

    I am working with XML content where the XSD defines an element as being of a complexType (say "ParentType") but the content explicitly sets the element's xs:type attribute to an extension of that complexType (say "ChildType").
    As far as I can tell the XML is valid, but JAXB issues the following when unmarshalling:
    DefaultValidationEventHandler: [ERROR]: Unexpected element {}:child1
    javax.xml.bind.UnmarshalException: Unexpected element {}:child1
    Where <child1> is added via the extension.
    Is this a problem with JAXB or my XSD?
    (XSD and XML enclosed below)
    XSD ------------------
    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
    <xs:complexType name="ParentType">
    <xs:sequence>
    <xs:element name="parent1" type="xs:string"/>
    <xs:element name="parent2" type="xs:string"/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name="ChildType">
    <xs:complexContent>
    <xs:extension base="ParentType">
    <xs:sequence>
    <xs:element name="child1" type="xs:string"/>
    </xs:sequence>
    </xs:extension>
    </xs:complexContent>
    </xs:complexType>
    <xs:element name="root">
    <xs:complexType>
    <xs:sequence>
    <xs:element name="child" type="ParentType"/>
    </xs:sequence>
    </xs:complexType>
    </xs:element>
    </xs:schema>
    XML -----------------------
    <?xml version="1.0" encoding="UTF-8"?>
    <root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="problem.xsd">
    <child xsi:type="ChildType">
    <parent1/>
    <parent2/>
    <child1/>
    </child>
    </root>

    JAXB doesn't handle OO schema design. I tried to do something similar where I defined a type called base and then defined that my document contained 1 or more base elements. Then I tried to unmarshall a document that contained elements that were of types extending from base. I ended up with the same issue.
    It seems that when the xjc compiler defines the classes it isn't smart enough to realize the element defined as parent could also contain a child element since child extends parent. Your XSD and XML are valid.
    I would think that JAXB should identify that because there is a type the extends the defined type, that an element of the sub-type might be subsituted i.e. check the actual type of the element in the XML before attempting to unmarshall it as the default type. It doesn't do that. I am not sure if this is as desinged, or a flaw in the implementation.

  • WSImport-Error generating server code from existing wsdl ends in ERROR

    Hi,
    we have an existing wsdl, and need to change the Server Env. I am evaluating JAX-WS and WSImport, and it seems to be cool, but i have a Problem similar to this thread here:
    http://forum.java.sun.com/thread.jspa?threadID=739918&messageID=4245176
    I solved all JAXB Issues, but this error drives me crazy. All Types from XSD and WSDL are generated if i switch to extension="true". In my Opinion the message parts refer to schema types, i cant figure out, whats wronh there.
    [wsimport] parsing WSDL...
    [wsimport] [WARNING] cos-applicable-facets: Facet 'totalDigits' is not allowed by type Kontonummer.
    [wsimport] line 140 of file:/C:/Projekte/irech/dd/WebContent/customization/xsd/de/bankverlag/b2b/common.xsd
    [wsimport] [ERROR] Invalid wsdl:operation "init": its a rpc-literal operation, message part must refer to a schema type declaration
    [wsimport] line 101 of file:/C:/Projekte/irech/dd/WebContent/customization/NachfrageErstellung.wsdl
    wsdl:
    <?xml version='1.0'?>
    <wsdl:definitions name='foo' targetNamespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/'
    xmlns:wsdl='http://schemas.xmlsoap.org/wsdl/'
    xmlns:tns='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/'
    xmlns:ns0='http://systinet.com/xsd/SchemaTypes/'
    xmlns:xns9="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/schecknachfrage/erstellen.xsd"
    xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
    xmlns:map='http://systinet.com/mapping/'>
    <wsdl:types>
    <xsd:schema elementFormDefault="qualified"
    targetNamespace="http://systinet.com/wsdl/org/idoox/webservice/server/"
    xmlns:map="http://systinet.com/mapping/"
    xmlns:tns="http://systinet.com/wsdl/org/idoox/webservice/server/"
    xmlns:xns5="http://systinet.com/containers/literal/ms.net"
    xmlns:xns6="http://systinet.com/wsdl/org/idoox/config/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <xsd:import namespace="http://systinet.com/wsdl/org/idoox/config/" schemaLocation="xsd/idoox.xsd"/>
    <xsd:import namespace="http://systinet.com/containers/literal/ms.net" schemaLocation="http://systinet.com/containers/literal/ms.net"/>
    <xsd:complexType name="WebServiceContext">
    <xsd:annotation>
    <xsd:appinfo>
    <map:java-type name="org.idoox.webservice.server.WebServiceContext"/>
    </xsd:appinfo>
    </xsd:annotation>
    <xsd:sequence>
    <xsd:element name="contextData" nillable="true" type="xns5:Map"/>
    <xsd:element name="contextId" nillable="true" type="xsd:string"/>
    <xsd:element name="lifeCycleService" nillable="true" type="tns:LifeCycleService"/>
    <xsd:element name="rootPath" nillable="true" type="xsd:string"/>
    <xsd:element name="serviceConfigurable" nillable="true" type="xns6:Configurable"/>
    <xsd:element name="serviceInstanceConfigurable" nillable="true" type="xns6:Configurable"/>
    <xsd:element name="serviceInstanceName" nillable="true" type="xsd:string"/>
    <xsd:element name="serviceName" nillable="true" type="xsd:string"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="LifeCycleService">
    <xsd:annotation>
    <xsd:appinfo>
    <map:java-type name="org.idoox.webservice.server.LifeCycleService"/>
    </xsd:appinfo>
    </xsd:annotation>
    <xsd:sequence/>
    </xsd:complexType>
    </xsd:schema>
    <xsd:schema elementFormDefault="qualified" targetNamespace="http://systinet.com/xsd/SchemaTypes/"
    xmlns:tns="http://systinet.com/xsd/SchemaTypes/"
    xmlns:xns4="http://systinet.com/wsdl/org/idoox/webservice/server/"
    xmlns:xns5="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/common.xsd"
    xmlns:xns6="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/ueberweisungsnachfrage/erstellen.xsd"
    xmlns:xns7="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/common.xsd"
    xmlns:xns8="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/lastschriftnachfrage/erstellen.xsd"
    xmlns:xns9="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/schecknachfrage/erstellen.xsd"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <xsd:import namespace="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/schecknachfrage/erstellen.xsd"/>
    <xsd:import namespace="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/lastschriftnachfrage/erstellen.xsd"/>
    <xsd:import namespace="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/common.xsd"/>
    <xsd:import namespace="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/nachfrage/ueberweisungsnachfrage/erstellen.xsd"/>
    <xsd:import namespace="https://test.irecherche.org/xsd/irecherche/de/bankverlag/b2b/common.xsd"/>
    <xsd:import namespace="http://systinet.com/wsdl/org/idoox/webservice/server/"/>
    <xsd:element name="p0" nillable="true" type="xns4:WebServiceContext"/>
    <xsd:element name="p0_1" nillable="true" type="xns5:UserContext"/>
    <xsd:element name="p1" nillable="true" type="xns6:UeberweisungsnachfrageErstellungsformular"/>
    <xsd:element name="NachfrageErstellungResult_Response" nillable="true" type="xns7:NachfrageErstellungResult"/>
    <xsd:element name="p0_2" nillable="true" type="xns5:UserContext"/>
    <xsd:element name="p1_3" nillable="true" type="xns8:LastschriftnachfrageErstellungsformular"/>
    <xsd:element name="p0_4" nillable="true" type="xns5:UserContext"/>
    <xsd:element name="p1_5" nillable="true" type="xns9:SchecknachfrageErstellungsformular"/>
    </xsd:schema>
    </wsdl:types>
    <wsdl:message name='NachfrageErstellung_erstelleSchecknachfrage_1_Request'>
    <wsdl:part name='p0' element='ns0:p0'/>
    <wsdl:part name='p1' element='ns0:p1_5'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_init_1_Request'>
    <wsdl:part name='p0' element='ns0:p0'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_destroy_1_Request'/>
    <wsdl:message name='NachfrageErstellung_erstelleLastschriftnachfrage_Response'>
    <wsdl:part name='response' element='ns0:NachfrageErstellungResult_Response'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_erstelleLastschriftnachfrage_1_Request'>
    <wsdl:part name='p0' element='ns0:p0_2'/>
    <wsdl:part name='p1' element='ns0:p1_3'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_erstelleUeberweisungsnachfrage_Response'>
    <wsdl:part name='response' element='ns0:NachfrageErstellungResult_Response'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_erstelleUeberweisungsnachfrage_1_Request'>
    <wsdl:part name='p0' element='ns0:p0_1'/>
    <wsdl:part name='p1' element='ns0:p1'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_destroy_Response'/>
    <wsdl:message name='NachfrageErstellung_erstelleSchecknachfrage_Response'>
    <wsdl:part name='response' element='ns0:NachfrageErstellungResult_Response'/>
    </wsdl:message>
    <wsdl:message name='NachfrageErstellung_init_Response'/>
    <wsdl:portType name='NachfrageErstellung'>
    <wsdl:operation name='init' parameterOrder='p0'>
    <wsdl:input message='tns:NachfrageErstellung_init_1_Request'/>
    <wsdl:output message='tns:NachfrageErstellung_init_Response'/>
    </wsdl:operation>
    <wsdl:operation name='destroy'>
    <wsdl:input message='tns:NachfrageErstellung_destroy_1_Request'/>
    <wsdl:output message='tns:NachfrageErstellung_destroy_Response'/>
    </wsdl:operation>
    <wsdl:operation name='erstelleUeberweisungsnachfrage' parameterOrder='p0 p1'>
    <wsdl:input message='tns:NachfrageErstellung_erstelleUeberweisungsnachfrage_1_Request'/>
    <wsdl:output message='tns:NachfrageErstellung_erstelleUeberweisungsnachfrage_Response'/>
    </wsdl:operation>
    <wsdl:operation name='erstelleLastschriftnachfrage' parameterOrder='p0 p1'>
    <wsdl:input message='tns:NachfrageErstellung_erstelleLastschriftnachfrage_1_Request'/>
    <wsdl:output message='tns:NachfrageErstellung_erstelleLastschriftnachfrage_Response'/>
    </wsdl:operation>
    <wsdl:operation name='erstelleSchecknachfrage' parameterOrder='p0 p1'>
    <wsdl:input message='tns:NachfrageErstellung_erstelleSchecknachfrage_1_Request'/>
    <wsdl:output message='tns:NachfrageErstellung_erstelleSchecknachfrage_Response'/>
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name='NachfrageErstellung' type='tns:NachfrageErstellung'>
    <soap:binding transport='http://schemas.xmlsoap.org/soap/http' style='rpc'/>
    <wsdl:operation name='init'>
    <map:java-operation name='init' signature='KExvcmcvaWRvb3gvd2Vic2VydmljZS9zZXJ2ZXIvV2ViU2VydmljZUNvbnRleHQ7KVY='/>
    <soap:operation soapAction='' style='rpc'/>
    <wsdl:input>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#init#KExvcmcvaWRvb3gvd2Vic2VydmljZS9zZXJ2ZXIvV2ViU2VydmljZUNvbnRleHQ7KVY='/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#init#KExvcmcvaWRvb3gvd2Vic2VydmljZS9zZXJ2ZXIvV2ViU2VydmljZUNvbnRleHQ7KVY='/>
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name='destroy'>
    <map:java-operation name='destroy' signature='KClW'/>
    <soap:operation soapAction='' style='rpc'/>
    <wsdl:input>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#destroy#KClW'/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#destroy#KClW'/>
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name='erstelleUeberweisungsnachfrage'>
    <map:java-operation name='erstelleUeberweisungsnachfrage' signature='KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2UvZXJzdGVsbGVuL1VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2VFcnN0ZWxsdW5nc2Zvcm11bGFyOylMZGUvYmFua3ZlcmxhZy9pcmVjaGVyY2hlL2J1c2luZXNzL3NoYXJlZC9iMmIvZ2VuZXJhdGVkL25hY2hmcmFnZS9jb21tb24vTmFjaGZyYWdlRXJzdGVsbHVuZ1Jlc3VsdDs='/>
    <soap:operation soapAction='' style='rpc'/>
    <wsdl:input>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleUeberweisungsnachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2UvZXJzdGVsbGVuL1VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2VFcnN0ZWxsdW5nc2Zvcm11bGFyOylMZGUvYmFua3ZlcmxhZy9pcmVjaGVyY2hlL2J1c2luZXNzL3NoYXJlZC9iMmIvZ2VuZXJhdGVkL25hY2hmcmFnZS9jb21tb24vTmFjaGZyYWdlRXJzdGVsbHVuZ1Jlc3VsdDs='/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleUeberweisungsnachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2UvZXJzdGVsbGVuL1VlYmVyd2Vpc3VuZ3NuYWNoZnJhZ2VFcnN0ZWxsdW5nc2Zvcm11bGFyOylMZGUvYmFua3ZlcmxhZy9pcmVjaGVyY2hlL2J1c2luZXNzL3NoYXJlZC9iMmIvZ2VuZXJhdGVkL25hY2hmcmFnZS9jb21tb24vTmFjaGZyYWdlRXJzdGVsbHVuZ1Jlc3VsdDs='/>
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name='erstelleLastschriftnachfrage'>
    <map:java-operation name='erstelleLastschriftnachfrage' signature='KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2xhc3RzY2hyaWZ0bmFjaGZyYWdlL2Vyc3RlbGxlbi9MYXN0c2NocmlmdG5hY2hmcmFnZUVyc3RlbGx1bmdzZm9ybXVsYXI7KUxkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2NvbW1vbi9OYWNoZnJhZ2VFcnN0ZWxsdW5nUmVzdWx0Ow=='/>
    <soap:operation soapAction='' style='rpc'/>
    <wsdl:input>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleLastschriftnachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2xhc3RzY2hyaWZ0bmFjaGZyYWdlL2Vyc3RlbGxlbi9MYXN0c2NocmlmdG5hY2hmcmFnZUVyc3RlbGx1bmdzZm9ybXVsYXI7KUxkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2NvbW1vbi9OYWNoZnJhZ2VFcnN0ZWxsdW5nUmVzdWx0Ow=='/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleLastschriftnachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2xhc3RzY2hyaWZ0bmFjaGZyYWdlL2Vyc3RlbGxlbi9MYXN0c2NocmlmdG5hY2hmcmFnZUVyc3RlbGx1bmdzZm9ybXVsYXI7KUxkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL2NvbW1vbi9OYWNoZnJhZ2VFcnN0ZWxsdW5nUmVzdWx0Ow=='/>
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name='erstelleSchecknachfrage'>
    <map:java-operation name='erstelleSchecknachfrage' signature='KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3NjaGVja25hY2hmcmFnZS9lcnN0ZWxsZW4vU2NoZWNrbmFjaGZyYWdlRXJzdGVsbHVuZ3Nmb3JtdWxhcjspTGRlL2Jhbmt2ZXJsYWcvaXJlY2hlcmNoZS9idXNpbmVzcy9zaGFyZWQvYjJiL2dlbmVyYXRlZC9uYWNoZnJhZ2UvY29tbW9uL05hY2hmcmFnZUVyc3RlbGx1bmdSZXN1bHQ7'/>
    <soap:operation soapAction='' style='rpc'/>
    <wsdl:input>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleSchecknachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3NjaGVja25hY2hmcmFnZS9lcnN0ZWxsZW4vU2NoZWNrbmFjaGZyYWdlRXJzdGVsbHVuZ3Nmb3JtdWxhcjspTGRlL2Jhbmt2ZXJsYWcvaXJlY2hlcmNoZS9idXNpbmVzcy9zaGFyZWQvYjJiL2dlbmVyYXRlZC9uYWNoZnJhZ2UvY29tbW9uL05hY2hmcmFnZUVyc3RlbGx1bmdSZXN1bHQ7'/>
    </wsdl:input>
    <wsdl:output>
    <soap:body use='literal' namespace='http://systinet.com/wsdl/de/bankverlag/irecherche/business/shared/b2b/services/waspinternal/NachfrageErstellung#erstelleSchecknachfrage#KExkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvY29tbW9uL1VzZXJDb250ZXh0O0xkZS9iYW5rdmVybGFnL2lyZWNoZXJjaGUvYnVzaW5lc3Mvc2hhcmVkL2IyYi9nZW5lcmF0ZWQvbmFjaGZyYWdlL3NjaGVja25hY2hmcmFnZS9lcnN0ZWxsZW4vU2NoZWNrbmFjaGZyYWdlRXJzdGVsbHVuZ3Nmb3JtdWxhcjspTGRlL2Jhbmt2ZXJsYWcvaXJlY2hlcmNoZS9idXNpbmVzcy9zaGFyZWQvYjJiL2dlbmVyYXRlZC9uYWNoZnJhZ2UvY29tbW9uL05hY2hmcmFnZUVyc3RlbGx1bmdSZXN1bHQ7'/>
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name='JavaService'>
    <wsdl:port name='NachfrageErstellung' binding='tns:NachfrageErstellung'>
    <soap:address location='urn:unknown-location-uri'/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>

    One can use Clientgen <binding> element to specify custom binding files.
    Here is a WLS workaround for the problem of unresolved xs:schema references in WSDL
    1. save XMLSchema.xsd and customization.xjb into a local directory called bindingDir,
    2. use the following script to gen clientside artifacts.
    <clientgen>
    <binding dir="bindingDir" includes="*">
    </clientgen>
    Thanks
    Bethune

  • JAXB/WLS 8.1 ISSUE

    Hi,
    We are trying to use JAXB 1.0.1 (JWSDP 1.2) as our binding framework, but we are
    unable to compile the java code that uses JAXB functionality when we try to use
    the ant build that comes with WLS 8.1. After comparing the distribution of WLS
    8.1 and JWSDP, we found that there are lots of differences in terms of the ANT
    distribution. JWSDP distribution has ANT 1.5.2 version.
    Which ant version does Weblogic Server 8.1 use ? Please suggest us a solution
    for this problem ?
    Thanks,
    Ganesh

    Refer Bug ID 4376065 on java.sun.com (http://developer.java.sun.com/developer/bugParade/bugs/4376065.html
    ) , which seems to be related to what you are explaining here. Please contact
    Sun Support for a follow up on this issue with regard to your specific case.
    Regards
    Shridhar
    "Ganesh" <[email protected]> wrote:
    >
    Thanks Sridhar for the response. I tracked the version as you suggested.
    It is
    matched what you just responded. But, the issue is when I try to compile
    some
    classes that uses JAXB it is not complaining anything about JAXB classes,
    but
    rather complains about JDK 1.4.1_01 (Which comes with WLS 8.1 on HP-UX
    11). I
    am pasting the stack trace I got while trying to compile. Any ideas ?
    [javac] An exception has occurred in the compiler (1.4.1.01). Please
    file
    a
    bug at the Java Developer Connection (http://java.sun.com/cgi-bin/bugreport.cgi)
    after checking the Bug Parade for duplicates. Include your program
    and the fol
    lowing diagnostic in your report. Thank you.
    [javac] java.lang.ArrayIndexOutOfBoundsException: 3584
    [javac] at com.sun.tools.javac.v8.code.ClassReader.readPool(ClassReader.
    java:450)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.readName(ClassReader.
    java:551)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.readClassAttrs(ClassR
    eader.java:765)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.readClass(ClassReader
    .java:859)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.readClassFile(ClassRe
    ader.java:933)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.fillIn(ClassReader.ja
    va:1088)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.complete(ClassReader.
    java:1046)
    [javac] at com.sun.tools.javac.v8.code.Symbol.complete(Symbol.java:332)
    [javac] at com.sun.tools.javac.v8.code.Symbol$ClassSymbol.complete(Symbo
    l.java:651)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.loadClass(ClassReader
    .java:1113)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.loadClass(Resolve.java:48
    5)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.findIdentInPackage(Resolv
    e.java:660)
    [javac] at com.sun.tools.javac.v8.comp.Attr.selectSym(Attr.java:1140)
    [javac] at com.sun.tools.javac.v8.comp.Attr.visitSelect(Attr.java:1089)
    [javac] at com.sun.tools.javac.v8.tree.Tree$Select.accept(Tree.java:1091
    [javac] at com.sun.tools.javac.v8.comp.Attr.attribTree(Attr.java:256)
    [javac] at com.sun.tools.javac.v8.comp.Attr.attribType(Attr.java:286)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.signature(Enter
    .java:682)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.visitMethodDef(
    Enter.java:770)
    [javac] at com.sun.tools.javac.v8.tree.Tree$MethodDef.accept(Tree.java:4
    82)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.memberEnter(Ent
    er.java:707)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.memberEnter(Ent
    er.java:719)
    [javac] at com.sun.tools.javac.v8.comp.Enter$CompleteEnter.finish(Enter.
    java:929)
    [javac] at com.sun.tools.javac.v8.comp.Enter$CompleteEnter.complete(Ente
    r.java:916)
    [javac] at com.sun.tools.javac.v8.code.Symbol.complete(Symbol.java:332)
    [javac] at com.sun.tools.javac.v8.code.Symbol$ClassSymbol.complete(Symbo
    l.java:651)
    [javac] at com.sun.tools.javac.v8.comp.Enter.complete(Enter.java:593)
    [javac] at com.sun.tools.javac.v8.JavaCompiler.complete(JavaCompiler.jav
    a:306)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.fillIn(ClassReader.ja
    va:1090)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.complete(ClassReader.
    java:1046)
    [javac] at com.sun.tools.javac.v8.code.Symbol.complete(Symbol.java:332)
    [javac] at com.sun.tools.javac.v8.code.Symbol$ClassSymbol.complete(Symbo
    l.java:651)
    [javac] at com.sun.tools.javac.v8.code.ClassReader.loadClass(ClassReader
    .java:1113)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.loadClass(Resolve.java:48
    5)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.findGlobalType(Resolve.ja
    va:548)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.findType(Resolve.java:604
    [javac] at com.sun.tools.javac.v8.comp.Resolve.findIdent(Resolve.java:63
    1)
    [javac] at com.sun.tools.javac.v8.comp.Resolve.resolveIdent(Resolve.java
    :798)
    [javac] at com.sun.tools.javac.v8.comp.Attr.visitIdent(Attr.java:1033)
    [javac] at com.sun.tools.javac.v8.tree.Tree$Ident.accept(Tree.java:1111)
    [javac] at com.sun.tools.javac.v8.comp.Attr.attribTree(Attr.java:256)
    [javac] at com.sun.tools.javac.v8.comp.Attr.attribType(Attr.java:286)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.visitVarDef(Ent
    er.java:780)
    [javac] at com.sun.tools.javac.v8.tree.Tree$VarDef.accept(Tree.java:511)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.memberEnter(Ent
    er.java:707)
    [javac] at com.sun.tools.javac.v8.comp.Enter$MemberEnter.memberEnter(Ent
    er.java:719)
    [javac] at com.sun.tools.javac.v8.comp.Enter$CompleteEnter.finish(Enter.
    java:929)
    [javac] at com.sun.tools.javac.v8.comp.Enter$CompleteEnter.complete(Ente
    r.java:916)
    [javac] at com.sun.tools.javac.v8.code.Symbol.complete(Symbol.java:332)
    [javac] at com.sun.tools.javac.v8.code.Symbol$ClassSymbol.complete(Symbo
    l.java:651)
    [javac] at com.sun.tools.javac.v8.comp.Enter.complete(Enter.java:593)
    [javac] at com.sun.tools.javac.v8.comp.Enter.main(Enter.java:574)
    [javac] at com.sun.tools.javac.v8.JavaCompiler.compile(JavaCompiler.java
    :334)
    [javac] at com.sun.tools.javac.v8.Main.compile(Main.java:520)
    [javac] at com.sun.tools.javac.Main.compile(Main.java:36)
    [javac] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
    Method)
    [javac] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcces
    sorImpl.java:39)
    [javac] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMet
    hodAccessorImpl.java:25)
    [javac] at java.lang.reflect.Method.invoke(Method.java:324)
    [javac] at org.apache.tools.ant.taskdefs.compilers.Javac13.execute(Javac
    13.java:100)
    [javac] at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:832)
    [javac] at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:674)
    [javac] at org.apache.tools.ant.Task.perform(Task.java:317)
    [javac] at org.apache.tools.ant.Target.execute(Target.java:309)
    [javac] at org.apache.tools.ant.Target.performTasks(Target.java:334)
    [javac] at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
    [javac] at org.apache.tools.ant.Project.executeTargets(Project.java:1250
    [javac] at org.apache.tools.ant.Main.runBuild(Main.java:610)
    [javac] at org.apache.tools.ant.Main.start(Main.java:196)
    [javac] at org.apache.tools.ant.Main.main(Main.java:235)
    BUILD FAILED
    Thanks,
    Ganesh
    "Shridhar Mysore" <[email protected]> wrote:
    At the outset, WLS 8.1 doesn't support JAXB.
    And the version of ant that comes with WLS 8.1 I think is :
    Apache Ant version 1.5 compiled on July 30 2002
    You can check this using "ant -version" against WLS 8.1 environment.
    Regards
    Shridhar
    "Ganesh" <[email protected]> wrote:
    Hi,
    We are trying to use JAXB 1.0.1 (JWSDP 1.2) as our binding framework,ant
    but we are
    unable to compile the java code that uses JAXB functionality when we
    try to use
    the ant build that comes with WLS 8.1. After comparing the distribution
    of WLS
    8.1 and JWSDP, we found that there are lots of differences in termsof
    the ANT
    distribution. JWSDP distribution has ANT 1.5.2 version.
    Which ant version does Weblogic Server 8.1 use ? Please suggest usa
    solution
    for this problem ?
    Thanks,
    Ganesh

  • XML JAXB Binding issue

    Hi All
    Im using Webservices in which i need to Bind my XML to Java objects and reverse. Im trying to use JAXB (1.0) Ref Imp from SUN as binding framework. The problem which im facing is that for elements like:
    <xs:element name="inputRequests">
    <xs:complexType>
    <xs:sequence>
    <xs:element maxOccurs="unbounded" name="inputData" type="data" />
    </xs:sequence>
    </xs:complexType>
    </xs:element>
    JAXB genetrates:
    1. InputRequest - Interface
    2. InputRequestImpl - Class
    3. InputRequestType - Interface
    4. InputRequestTypeImpl - Class
    in InputRequestType it has generated a getter method
    public java.util.List getInputData();
    but no setter method for 'inputData'.
    Can any one help on that how we can set a sequence element in JAXB classes. I even used JAXB 2.0, but faced same issue...
    No Setter for a LIST :-(((

    That method, getInputData() is returning a reference to a List Object that is already instantiated. Once you retrieve the reference, you can invoke all the methods in the List interface, but if there is a way to reassign the reference to refer to a different list, I'm not aware of one.
    I believe that limitation is necessary my the nature of JAXB. A JAXB Object, in your case a List, is guaranteed to be marshaled and unmarshaled to XML, if you redefine the reference to some arbitrary List, how could JAXB guarantee its functionality?
    I may be way off base here, I'm no JAXB expert by any means.
    Rather than redefining the reference to a different List, you have to manipulate the List
    ...getInputData().clear();
    ...getInputData().addAll(myRequestList);Right?

  • Issues in creating Java based web services with JAXB 1.0 in Jdeveloper 10 g

    Hi All,
    I am trying out a simple java based web service creation exercise using Jdeveloper 10.1.3.3.0.3 and JAXB 1.0. Here is what I am trying to do.
    1. I have a XSD file called Status.xsd, which has three complex types in it.
    2. Using Jdeveloper Tools --> JAXB Compilation, I have created Jaxb classes for the above XSD files. For each of the complex type the jaxb class generator generated on IMPL clas and one abstract class.
    3. Now I have created one simple java class called Class1.java and created one method that takes the StatusImpl as input and as output for that method. Here is the code for Class1.java
    public class Class1 {
    public Class1() {
    public StatusImpl getstatus (StatusImpl in) {
    StatusImpl out;
    out = in;
    return out;
    4. Now, I trying to create a web service for this java class from jedeveloper. I have right clicked this class and went thru the wizard Create J2EE web services.
    5. At the end, the web service project got created successfully and I am trying to run this project from jdeveloper. When I run this project, I am getting the following kind of error message in the browser
    It looks like when the runtime deployment classes are trying to instantiate the abstract classes instead of the impl class. and for all the complex types they trow that error and the web service could not be even invoked.
    What could be the issue? Is the jaxb based web services supported with jdeveloper 10g?
    Thanks,
    Renga

    Hi All,
    I am trying out a simple java based web service creation exercise using Jdeveloper 10.1.3.3.0.3 and JAXB 1.0. Here is what I am trying to do.
    1. I have a XSD file called Status.xsd, which has three complex types in it.
    2. Using Jdeveloper Tools --> JAXB Compilation, I have created Jaxb classes for the above XSD files. For each of the complex type the jaxb class generator generated on IMPL clas and one abstract class.
    3. Now I have created one simple java class called Class1.java and created one method that takes the StatusImpl as input and as output for that method. Here is the code for Class1.java
    public class Class1 {
    public Class1() {
    public StatusImpl getstatus (StatusImpl in) {
    StatusImpl out;
    out = in;
    return out;
    4. Now, I trying to create a web service for this java class from jedeveloper. I have right clicked this class and went thru the wizard Create J2EE web services.
    5. At the end, the web service project got created successfully and I am trying to run this project from jdeveloper. When I run this project, I am getting the following kind of error message in the browser
    It looks like when the runtime deployment classes are trying to instantiate the abstract classes instead of the impl class. and for all the complex types they trow that error and the web service could not be even invoked.
    What could be the issue? Is the jaxb based web services supported with jdeveloper 10g?
    Thanks,
    Renga

  • Issues in migrating from jaxb1.0 to jaxb 2.0

    Hi,
    I am facing following issue while trying to migrate from Jaxb 1.0 to 2.0.
    I am not able to generate a java class from the <xsd:element> in jaxb 2.0. This used to work perfectly in jaxb1.0.
    the schema as follows:
    A. top level schema
    <xs:schema
       xmlns:xs  ="http://www.w3.org/2001/XMLSchema"
       xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
       xmlns:xjc ="http://java.sun.com/xml/ns/jaxb/xjc"
       jaxb:extensionBindingPrefixes="xjc"
       jaxb:version="2.0">
      <!--
        This schema file is used just to apply global bindings,
        it doesn't define any schema definition at all.
      -->
      <xs:annotation><xs:appinfo>
        <jaxb:globalBindings generateElementProperty="false" generateValueClass="false">
          <!-- needed to correctly marshall and unmarshaller elements to the correct type -->
          <xjc:typeSubstitution type="complex"/>
        </jaxb:globalBindings>
      </xs:appinfo></xs:annotation>
    </xs:schema>B. main schema file
    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema targetNamespace      = "C"
               xmlns:xs             = "http://www.w3.org/2001/XMLSchema"
               xmlns                = "C"
               attributeFormDefault = "unqualified"
               elementFormDefault   = "unqualified">
      <xs:element name="AAAA" type="BBBB">
        <xs:annotation>
          <xs:documentation>q2w2iug78gt8h</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:complexType name="BBBB">
        <xs:sequence>
          <xs:element name="www" type="xs:normalizedString"/>
          <xs:element name="yyy" type="OCICommand" minOccurs="1" maxOccurs="15"/>
        </xs:sequence>
      </xs:complexType>
      </xs:schema>On compiling both these schema files I get only BBBB.java. previously we used to get AAAA.java as well.
    Any help will be appreciated.
    Thanks

    I have found the answer to my query. I missed out the '@generateElementClass' attibute of the <jaxb:globalBindings> in my global xsd file (vendor cusotmization). by making generateElementClass="true". will generate java classes for <xs:element> also.
    :)

  • JAXB 2.0 : Issue with custom bindings

    I have defined an inline JAXB 2.0 customization in my schema as follows:
    <xs:annotation>
    <xs:appinfo>
    <jxb:globalBindings>
    <jxb:javaType name="int" xmlType="xs:integer"
    parseMethod="javax.xml.bind.DatatypeConverter.parseInt" printMethod="javax.xml.bind.DatatypeConverter.printInt"/>
    <jxb:javaType name="double" xmlType="xs:decimal" parseMethod="javax.xml.bind.DatatypeConverter.parseDouble" printMethod="javax.xml.bind.DatatypeConverter.printDouble"/>
    </jxb:globalBindings>
    </xs:appinfo>
    </xs:annotation>
    But when I compile the schema, all the elements in it defined as xs:integer are converted to Integer objects instead of a primitive int.
    An Adapter1.java file is created as follows:
    public Integer unmarshal(String value) {
    return (javax.xml.bind.DatatypeConverter.parseInt(value));
    public String marshal(Integer value) {
    return (javax.xml.bind.DatatypeConverter.printInt(value));
    I even tried using a custom binding class and defining its print and parse methods but same result.
    Why is the Adapter class created and why is the custom binding not followed?
    Can somebody help me here.
    Thanks.

    JDeveloper 10.1.3.2 does not support JAXB 2.0.
    JAXB 2.0 support may be added.
    Using JAXB 2.0 with JDeveloper 10.1.3

  • Special Characters issue in JAXB Classes generated

    Hi,
    I have generated Java bean classes from an xml schema using JAXB 2.0 Content Model feature in Jdeveloper 11g. I have another class, which has a method testMethod which takes the Java Bean class object as input. I have exposed this method as java webservice. I am just printing the FirstName from the input I have got.
    public String testMethod(TestBean testbean) {
    testBean,getContact().getFirstName();
    When there are some special characters like �, my java bean accepts and displays as �. I printed the value directly in my getter method, but it prints differently.
    How can I set my Java Bean class to use ISO-8859-1 as encoding.

    Sorry but this has nothing to do with ADF. Please try in the right forum here https://forums.oracle.com/forums/category.jspa?categoryID=285

  • Jaxb 2 customization issue

    I am new to JAXB2 world.
    -I have a xml document whose xsd has imports of other xsds. I have the corresponding domain model and java objects in hand. The names of the classes/attibutes differ from that of those specified in the xsd; Thus did the jaxb 2.0 customization. JAXB is throwing a nullpointer exception when it encounters the import of other xsd in the calling xsd but works well, otherwise.
    -In the case of complicated java domain models and xml bining, would the usuage of Jibx be preferable over Jaxb...any suggestions?!
    -Also please suggest a good book/articles about java domain and xml binding.
    Any help is highly appreciated.
    Thanks in advance.

    Hello,
    For complicated models, or for situations in which you want to map an existing object model to an existing XML schema you need a tool that goes beyond JAXB.
    I am the team lead for Oracle TopLink Object-to-XML (JAXB) and was a member of the JAXB 2.0 (JSR-222) expert group so I'll share my thoughts.
    - TopLink OXM provides a visual tool, the TopLink Workbench to map an existing XML schema to an existing object model.
    - TopLink OXM can be exposed through the standard JAXB runtime APIs.
    - TopLink OXM can be run with any JAXP compliant parser. Many binding solutions are dependent on a specific parser.
    For more information on TopLink OXM/JAXB
    http://www.oracle.com/technology/products/ias/toplink/oxm/index.html
    My Oracle OpenWorld 2005 presentation
    http://download-west.oracle.com/oowsf2005/1535.pdf
    -Blaise

  • JAXB generation and XSD choice serious issue

    Helo,
    Im developing a webservice that uses XSD Choice structure. Unfortunately, this must to done with choice because doesnt make sense using sequences this case.
    Ill explain bug using this link:
    http://bdoughan.blogspot.com/2011/04/xml-schema-to-java-xsd-choice.html#comment-form
    this is exactly same problem as me, JAXB in jdeveloper are generating anotations wrong! I cant map the sequence choice to webservice, that is developed from WSDL...
    So, I need some help there, I really need develop this webservice using xsd:choice and cant be done in jdeveloper and dont know why.
    I tried put the anotations like this URL but when I call the service, choice element on request was null!
    thanks

    Hi, i dont know why but when I use JAXB to generate a sample XMl I got this output:
    <guiaRequest xmlns="http://www.myservices.gov.br/mensagem/integracaobancaria/guia">
    <parametrosConsultaGuia>
    <guiaNormalRequest>
    <codigoEntidade>B83C15C173633890E0330A67021B3890</codigoEntidade>
    <codigoPorte>6</codigoPorte>
    <codigoAssunto>148</codigoAssunto>
    <numeroTransacaoInternet>267472003</numeroTransacaoInternet>
    </guiaNormalRequest>
    </parametrosConsultaGuia>
    </guiaRequest>
    This is correct to my webservice, BUT, when I invoque webservice with xsd:choice I got this request (i see that on enterprise manager) :
    <message>
    <properties>
    <property name="tracking.compositeInstanceId" value="80367" />
    <property name="tracking.ecid" value="0000J1pyNtnBDC^5lVg8yZ1DtZWJ002D4z" />
    <property name="transport.http.remoteAddress" value="10.106.14.162" />
    </properties>
    <parts>
    <part name="request" >
    <ns2:guiaNormalRequest>
    <ns2:codigoEntidade>B83C15C173633890E0330A67021B3890</ns2:codigoEntidade>
    <ns2:codigoPorte>6</ns2:codigoPorte>
    <ns2:codigoAssunto>148</ns2:codigoAssunto>
    <ns2:numeroTransacaoInternet>267472003</ns2:numeroTransacaoInternet>
    </ns2:guiaNormalRequest>
    </part>
    </parts>
    </message>
    This is wrong! see the structure is not correct.

  • JAXB 2.1 w/JDK 6 Error. bootstrap classloader issue.

    When I run one of my JUnit tests, I get this error:
    JAXB 2.0 API is being loaded from the bootstrap classloader, but this RI (from jar:file:/usr/local/netbeans-6.0/java1/modules/ext/jaxws21/jaxb-impl.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class) needs 2.1 API. Use the endorsed directory mechanism to place jaxb-api.jar in the bootstrap classloader.
    So, I copy jaxb-api.jar into /usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/endorsed/jaxb-impl.jar
    Then I get this error:
    JAXB 2.0 API is being loaded from the bootstrap classloader, but this RI (from jar:file:/usr/lib/jvm/java-6-sun-1.6.0.03/jre/lib/endorsed/jaxb-impl.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class) needs 2.1 API
    OS: Ubuntu 7.10
    JVM: Sun 1.6.0.03
    IDE: NetBeans 6.0
    How do I resolve?

    This seems to be the answer: https://jaxb.dev.java.net/guide/Migrating_JAXB_2_0_applications_to_JavaSE_6.html#Using_JAXB_2_1_with_JavaSE_6
    Place the 2.1 jaxb-api.jar into $JRE_HOME/lib/endorsed. This essentially makes your JRE to "JRE 6 + JAXB 2.1". This won't affect any other applications that use this JRE, and it's easy. On the other hand, in various scenarios you may not be able to alter the JRE.

  • JAXB External Custom Bindings Issue

    I have a very large schema that I am trying to bind using JAXB. The naming in the schema is very good, nor is the structure, so I was hoping to do some custom binding. When I went to start the custom binding in an external file XJC returns an error saying that the target node is empty. It works fine if I give it the schema location and point it at the root of the schema, but trying to access the first complex type doesn't work. My external custom bindings file is below, an excerpt from the XSD Follows it, as well as my error. Please keep in mind that I cannot modify the schema in anyway.
    <?xml version="1.0" encoding="UTF-8"?>
    <jxb:bindings xmlns:jxb="http://java.sun.com/xml/ns/jaxb"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema" jxb:version="1.0"
    schemaLocation="fgdc.xsd">
    <jxb:bindings node="/xsd:schema">
    <jxb:schemaBindings>
    <jxb:package name="gov.noaa.clas.neaat.schema.fgdc"/>
    </jxb:schemaBindings>
    </jxb:bindings>
    <jxb:bindings node="//xsd:complexType'@name=metadataType'">
    <jxb:class name="FgdcMetadataInterface" implClass="FgdcMetadata">
    <jxb:javadoc>Data about the content, quality, condition, and other
    characteristics of data.</jxb:javadoc>
    </jxb:class>
    </jxb:bindings>
    </jxb:bindings>
    <xsd:complexType name="metadataType">
    <xsd:sequence>
    <xsd:element ref="idinfo"/>
    <xsd:element ref="dataqual" minOccurs="0"/>
    <xsd:element ref="spdoinfo" minOccurs="0"/>
    <xsd:element ref="spref" minOccurs="0"/>
    <xsd:element ref="eainfo" minOccurs="0"/>
    <xsd:element ref="distinfo" minOccurs="0" maxOccurs="unbounded"/>
    <xsd:element ref="metainfo"/>
    </xsd:sequence>
    </xsd:complexType>[xjc] Compiling file:/C:/Joshua/trunk/schema/schema/data.xsd and others
    [xjc] [ERROR] XPath evaluation of "//xsd:complexType'@name=metadataType'" results in empty target node
    [xjc] line 10 of file:/C:/Joshua/trunk/schema/schema/fgdc.xjb

    I have a very large schema that I am trying to bind using JAXB. The naming in the schema is very good, nor is the structure, so I was hoping to do some custom binding. When I went to start the custom binding in an external file XJC returns an error saying that the target node is empty. It works fine if I give it the schema location and point it at the root of the schema, but trying to access the first complex type doesn't work. My external custom bindings file is below, an excerpt from the XSD Follows it, as well as my error. Please keep in mind that I cannot modify the schema in anyway.
    <?xml version="1.0" encoding="UTF-8"?>
    <jxb:bindings xmlns:jxb="http://java.sun.com/xml/ns/jaxb"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema" jxb:version="1.0"
    schemaLocation="fgdc.xsd">
    <jxb:bindings node="/xsd:schema">
    <jxb:schemaBindings>
    <jxb:package name="gov.noaa.clas.neaat.schema.fgdc"/>
    </jxb:schemaBindings>
    </jxb:bindings>
    <jxb:bindings node="//xsd:complexType'@name=metadataType'">
    <jxb:class name="FgdcMetadataInterface" implClass="FgdcMetadata">
    <jxb:javadoc>Data about the content, quality, condition, and other
    characteristics of data.</jxb:javadoc>
    </jxb:class>
    </jxb:bindings>
    </jxb:bindings>
    <xsd:complexType name="metadataType">
    <xsd:sequence>
    <xsd:element ref="idinfo"/>
    <xsd:element ref="dataqual" minOccurs="0"/>
    <xsd:element ref="spdoinfo" minOccurs="0"/>
    <xsd:element ref="spref" minOccurs="0"/>
    <xsd:element ref="eainfo" minOccurs="0"/>
    <xsd:element ref="distinfo" minOccurs="0" maxOccurs="unbounded"/>
    <xsd:element ref="metainfo"/>
    </xsd:sequence>
    </xsd:complexType>[xjc] Compiling file:/C:/Joshua/trunk/schema/schema/data.xsd and others
    [xjc] [ERROR] XPath evaluation of "//xsd:complexType'@name=metadataType'" results in empty target node
    [xjc] line 10 of file:/C:/Joshua/trunk/schema/schema/fgdc.xjb

Maybe you are looking for

  • Connection Pool Failure

    Hello. I'm using wls 5.1 and Oracle 8i and an unable to make a connection pool. I keep getting the following with the message below. Where and how do I change my path? weblogic.common.ResourceException: weblogic.common.ResourceException: Could not cr

  • Is there a way to make the colour picker in the toolbar bigger?

    Hi, Is there a way to make the colour picker in the toolbar bigger? I've been using Illustrator for some time now and find this part of the software to be annoying as I frequently mis-click this tiny area and the switching between foreground and back

  • Error 116 at Unflatten from string.....

    Hi I want to save and load the control values of the tab pages I am getting the following error "Error 116 occurred at Unflatten From String            Unflatten or byte stream read operation failed due to corrupt, unexpected, or truncated data."   t

  • CS 6 Photoshop Doesn't Work

    I have to re-boot the computer every two or three images, grrr, or I have nothing but trouble. When in Camera RAW the image won't appear until it's opened in PS. I'm about ready to ask for my money back - I hate this version. All previous versions ne

  • HTMLB Tabstripitem height issues in NW07 (NW04s)

    We have an iView that initially displays with 3 tabs, and the content in the tabs are of varying heights. The 1st tab (initial tab to display) no longer dynamically sizes to the height of the content, but instead displays to the height of the largest