[Axis2] WSDL2Java seems to ignore xsd:any element

Hi,
Since I need to have some kind of extensibility in a web service i'm currently defining, I decided to play with the Axis2 userguide sample and tried to change the original WSDL so that the "SOAPStruct" message type would include an xsd:any element :
<complexType name="SOAPStruct">
<all>
<element type="float" name="varFloat" />
<element type="int" name="varInt" />
<element type="string" name="varString" />
<any maxOccurs="1"/>
</all>
</complexType>When I run WSDL2Java, the xsd:any element isn't mapped anywhere in the generated SOAPStruct.java, whereas the other are. I also tried just the following :
<complexType name="SOAPStruct">
<sequence>
<any/>
</sequence>
</complexType>And then I've got barely nothing in the SOAPStruct.java (except the declaration of the Factory class)
Could someone please help me with this ? I'm sure I made some kind of stupid error since using xsd:any shouldn't be really hard, I guess.
I'm using Axis2 1.0.

This seems to work for me<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="root">
  <xsd:complexType>
    <xsd:sequence>
      <xsd:element ref="foobarelements" maxOccurs="unbounded"/>
    </xsd:sequence>
  </xsd:complexType>
</xsd:element>
<xsd:element name="foo" type="xsd:anyType"  substitutionGroup="foobarelements"/>
<xsd:element name="bar" type="xsd:anyType"  substitutionGroup="foobarelements"/>
<xsd:element name="foobar" type="xsd:anyType"  substitutionGroup="foobarelements"/>
<xsd:element name="foobarelements" type="xsd:anyType"/>
</xsd:schema>

Similar Messages

  • XSD any elements in any order

    Hi,
    I'm trying to figure out how to create an element that permits any number of certain elements to occur in any order, and I seem to be quite stuck. For example, given the special elements foo, bar, and foobar, I'd like to be able to create an XSD definition for the following:
    <root>
    <foo/>
    <bar/>
    <bar/>
    <foo/>
    <foobar/>
    <bar/>
    <foobar/>
    <bar/>
    <foo/>
    </root>
    Any ideas? I can do this:
    <xsd:element name="root">
    <xsd:complexType>
    <xsd:sequence>
    <xsd:choice minOccurs="0">
    <xsd:element name="foo" type="FooType">
    <xsd:element name="bar" type="BarType">
    <xsd:element name="foobar" type="FooBarType">
    </xsd:choice>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    But this seems not to work quite as expected. It lets me create:
    <root><foo/></root>, <root><bar/></root>, or <root><foobar/></root>
    But it doesn't permit having multiple occurrences of <foo> or even an occurrence of <foo> and one of <bar>.
    Thanks

    This seems to work for me<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <xsd:element name="root">
      <xsd:complexType>
        <xsd:sequence>
          <xsd:element ref="foobarelements" maxOccurs="unbounded"/>
        </xsd:sequence>
      </xsd:complexType>
    </xsd:element>
    <xsd:element name="foo" type="xsd:anyType"  substitutionGroup="foobarelements"/>
    <xsd:element name="bar" type="xsd:anyType"  substitutionGroup="foobarelements"/>
    <xsd:element name="foobar" type="xsd:anyType"  substitutionGroup="foobarelements"/>
    <xsd:element name="foobarelements" type="xsd:anyType"/>
    </xsd:schema>

  • Attemp to build loosely coupled WS using xsd:any & xsd:anyType?

    Dear All,
    i want to write a loosely coupled web service that allow
    the server to evolve independently to the client. (main
    purpose is to extend the service by adding more properties
    in the request / response message)
    i want to achieve the loosely coupled goal by adding
    xsd:any or xsd:anyType to the request / response messages
    (i.e. wsdl ComplexType). (just follow the normal XML
    guideline).
    i have try to write simple program with xsd:any (which
    mapped to SOAPElement in JAX-RPC). And the result seems
    good and can achieve my goal. ( i can consume the service
    in java and .net without problem).
    but later, i read some article, in the web, (like this: http://www.ibm.com/developerworks/xml/library/ws-tip-xsdcaution.html)
    that clams it is better to use xsd:anyType instead of
    xsd:any (as anyType is mapped to SOAPElement or java
    object if server/client can deserialize it).
    as far as i know, the support of xsd:anyType is not standardized / madatory.
    could anyone tell me your comment about using xsd:anyType or xsd:any?
    how about the support of xsd:anyType across different platform / tools?
    xsd:anyAttribute seems not supported by jax-rpc, could you please comment on using this element in the wsdl? good or bad?
    oracle will map this element to an oracle proprietary java object.
    am i choosing the right way to achieve loosely-coupled WS? any other way?
    some article claims to send request as xml doc. but it
    seems that is not very convenient to server and client as
    both sides need to write code for serialization /
    deserialization.
    why not use the existing automatic XML <--> java object provided by the jax-rpc standard?
    Thank you very much
    Message was edited by:
    lsp

    Hello,
    Is your question related to very specific element of your message or for the complete message.
    Using any/anyType even if powerful could be sometimes complex for Web Service Client developer to handle since the Java object (SOAPElement or Object) is not typed so doing late binding of schema force people to do the mapping themself any.
    So before choosing this in a wide scope on your project think also to its impact for end user/developers, and I think you are on the good path, as you said anyType will recognize the object.
    I am inviting you to also look at the Oracle Web Services Interoperability documentation.
    and this article from SUN: Interoperability With Patterns and Strategies for Document-Based Web Services
    Regards
    Tugdual Grall

  • Oracle Service Bus strict validatition of xsd:any

    Hello,
    I'm trying to get an xsd:any validated in the OSB, processContent for it is strict. I realize the XSD that declares the any element has to be imported by the XSD that the OSB is validating in the first place. My question is: is it possible to instruct the OSB to validate the xsd:any against another schema that is not imported by the one I'm validating against?
    For example:
    A.xsd is like:
    <xsd:schema targetNamespace="http://foo" xmlns:xsd="http://www.w3.org/2001/XMLSchema" >
    <xsd:element name="root">
    <xsd:complexType>
    <xsd:sequence minOccurs="1" maxOccurs="1">
    <xsd:any namespace="##any" minOccurs="1" maxOccurs="unbounded" processContents="strict"/>
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    </xsd:schema>
    B.xsd is like:
    <xsd:schema targetNamespace="http://bar" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    <xsd:element name="x" type="xsd:integer"/>
    </xsd:schema>
    So there is no import of B.xsd in the A.xsd.
    But I would like this to be validated in the OSB:
    <foo:root xmlns:foo="http://foo" xmlns:bar="http://bar">
    <bar:x>1</bar:x>
    </foo:root>
    Of course I get the error saying that the declaration of the element bar:x is not defined. Can I instruct the OSB to search for the B.xsd somewhere?
    Thanks!

    Manoj written:
    OSB cannot resolve dependencies in XSD/WSDL even if the URI is standard one. We have to use Edit References button for resolving dependencies in XSD/WSDL resources. Click on Edit References and resolve your dependencies. OSB will internally link the resources, and the above error will be gone. So it seems that for all includes and imports, you have to resolve dependencies locally i.e. all included/imported resources should be present in service bus configuration even if the URI of those are a standard one.
    I am not sure how you could change it at console as there again it asks to resolve dependency if you provide a valid HTTP URL.
    Regards,
    Anuj

  • JAXB compiler problem in handling xsd:any and nillble = "true"

    Dear all,
    i am using jdeveloper 10.1.3.1 production release version.
    i am designing a xml schema that contain element of attribute nillable="true", for extensible, contain tag <xsd:any>.
    but i encounter 2 problem:
    1. for xml schema element with attribute nillable="true", no corresponding isNil(), setNil
    method is generated (refer to jaxb 1.0 spec. 5.7.1)
    2. cannot handle tag <xs:any> that generate incorrect java source code (cannot compile) [refer to jaxb 1.0 spec 5.9.5)
    *** i have add jaxb customization tag inside the <xs:any> tag
    ***   <xs:annotation><xs:appinfo>
    ***               <jaxb:property name="Extension"/>
    ***</xs:appinfo></xs:annotation>
    Does oracle's JAXB implementation conform to the JAXB 1.0 spec?
    Is it a known bug?
    Could anybody help me?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Refer to section
    E.2 Not Required XML Schema
    concepts
    "A JAXB implementation is not required to support the following XML Schema
    concepts for this version of the specification. A JAXB implementation may
    choose to support these features in an implementation dependent manner."
    E.2.2 Not supported while manipulating the XML
    content
    Schema component: wildcard
    (any)
    how can i know if an xml element with xsi:nil="true" (unmarshal)
    and set xsi:nil="true" for an element (marshal) ?
    According to the JAXB 1.0 specification:
    If {nillable} is "true", the methods setNil() and isNil() are
    generated.

  • How to assign and transform or how to deal with xsd:anyType elements in 10g

    Hi,
    Any Update on this please...
    Hi,
    we are using canonical model as part of 10g, here I am not able to assign or tranform elements of type xsd:anyType to/from to other type elements. Solution with an example and quick reply is appreciated.
    =========================================
    Hi,
    By using copy-of xslt construct again input element structure is getting copied into the target mapper file, by using value-of xsl:construct just the value is getting assigned. Can you please elaborate on how to use this xsd:anyType elements in assign and tranform activities, overall how to use these elements in 10g, while implementing the canonical model.
    ex:
    xsl file: by using value-of
    <xsl:template match="/">
    <ns1:abstractRef>
    <ns1:amount>
    <xsl:value-of select="/ns1:BPELProcess1ProcessRequest/ns1:input"/>
    </ns1:amount>
    </ns1:abstractRef>
    </xsl:template>
    Result:
    <abstract1>
    -<abstractRef xmlns:ns1="http://xmlns.oracle.com/BPELProcess1" xmlns="http://sample/test">
    <ns1:amount>6556</ns1:amount>
    </abstractRef>
    </abstract1>
    Here amount is of type xsd;anyType which is present in the abstract complexType.
    xsl file: by using copy-of:
    <xsl:template match="/">
    <ns1:abstractRef>
    <ns1:amount>
    <xsl:copy-of select="/ns1:BPELProcess1ProcessRequest/ns1:input"/>
    </ns1:amount>
    </ns1:abstractRef>
    </xsl:template>
    Result:
    <abstract1>
    -<abstractRef xmlns:ns1="http://xmlns.oracle.com/BPELProcess1" xmlns="http://sample/test">
    <ns1:amount>
    <ns1:input>6556</ns1:input>
    </ns1:amount>
    </abstractRef>
    </abstract1>
    and while using it on assign activity, it is not assigning the input value to the xsd:anyType element, please provide an example on how to do this activity along with tranform.
    Edited by: user12679330 on Mar 1, 2010 4:46 AM

    >
    Try bpelx:append as a copy rule.
    >
    Since this thread is over three years old it will be interesting to see if OP is still waiting for a reply. ;)

  • Mapping the xsd:any tag from one schema to other in BPEL

    I am using soa suite 11g
    I have 2 schemas with <xsd:any> tag
    at run time the xml based on one xsd can have tags as below in place of xsd:any tag
    <*number* xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeId="1001" readOnly="False">P00001</number>
    <*description* xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeId="1002" readOnly="False">Test Part created for Mapping</description>
    <*itemType* xsi:type="common:AgileListEntryType" xmlns:common="http://xmlns.oracle.com/AgileObjects/Core/Common/V1" attributeId="1081" readOnly="False">
    <selection>
    <id>10141</id>
    <apiName>Part</apiName>
    <value>Part</value>
    </selection>
    </itemType>
    <*lifecyclePhase* xsi:type="common:AgileListEntryType" xmlns:common="http://xmlns.oracle.com/AgileObjects/Core/Common/V1" attributeId="1084" readOnly="True">
    <selection>
    <id>976</id>
    <apiName>PRELIMINARY</apiName>
    <value>Preliminary</value>
    </selection>
    </lifecyclePhase>
    and in othe xsd it can be
    <key1001 attributeId="5001">P00002</key1001>
    <key1002 attributeId="5002">Test Part created for Mapping</key1002>
    I can create a DVM to have mapping of attribute id's values 1001 -5001 ,1002-5002 but how to wire/map the any nodes and the attribute id element of one any node to other in XSLT mapper.At design time I am not aware that what all tags can substitute in place of any.
    I need to map these two any tags.How to do this in transform activity xslt mapper in BPEL.It does not allow me to directly wire two any tags
    Request someone to help me on this.stuck on this for long .

    I have figured out that with xpath and copy-of operation I can copy all nodes that come in place of xsd:any from one schema to other .But beofre copying I want to change the attribute values of the node that come in place of xsd:any based on the mapping stored in the DVM.Request some one to please help .

  • XML Schema any element

    I have a list of schema files and they a number of elements in them. But for my data extraction i use only close to 300 tags. When i register the schema I get an error that a table cannot of have more than 1000 columns. My work mate is working on Annotations and I am planning to build a new schema to make extract only these 300 tag names and also make sure the XML file can be validated like it did earlier. Explaining this i came across a complex type element called *<any>* which can be used to allow elements to be available which are not declared within the schema file.
    My Original schema file looks something like below,
    <xsd:complexType name="WfInformation">
    <xsd:all minOccurs="0">
    <xsd:element name="Company" type="WfCompany" minOccurs="0" />
    <xsd:element name="HeadOffice" type="WfOffice" minOccurs="0" />
    <xsd:element name="IndependentOffice" type="WfIOffice" minOccurs="0" />
    <xsd:element name="AffiliateCompany" type ="WfIAOffice" minOccurs="0" />
    <xsd:element name="Number" type="xsd:string" minOccurs="0" />
    <xsd:element name="ReferenceID" type="xsd:string" minOccurs="0" />
    </xsd:all>
    </xsd:complexType>
    of the above list of items i use only elements Company, HeadOffice, Number. After reading through some documentation I wanted to <any> tag like below,
    <xsd:complexType name="WfInformation">
    *<xsd:sequence>*
    <xsd:element name="Company" type="WfCompany" minOccurs="0" />
    <xsd:element name="HeadOffice" type="WfOffice" minOccurs="0" />
    *<xsd:any processContents="lax"/>*
    *<xsd:any processContents="lax"/>*
    <xsd:element name="Number" type="xsd:string" minOccurs="0" />
    *<xsd:any processContents="lax"/>*
    *</xsd:sequence>*
    </xsd:complexType>
    My question is if I am correcting the lines as i mentioned above will be Register schema again fail with same reason that i have 1000 columns. As i understand every element inside an Complex element is stored as a column value. In that case will this redesign work. Or is there any other way to approach re-desgin the XML Schema.

    Thanks. I think that leaves out my option to create a totally new Schema to suit my XML files.
    Only other option we have is to use Annotations.
    I think my colleague - eoin62 would have shared the XML Schema files earlier through your oracle email address.
    Please refer thread - How to register multiple XSD files
    But we received a reply and we knew very little on how to make changes to Admin.xsd and how would that solve our problem. Please correct me if i am incorrect. Because the biggest Schema was estimate.xsd that has close to 800+ elements. I am not sure if my colleague sent you the necessary tag names we use within the Schema. We have close to around 300 tags we use. But our combined XML Schema has close to 1600+ If we have to annotate, i thought it would be better we tell Oracle which tagswe need, which inturn should should help better create XMLtype table against a Schema and work on performance.
    Your earlier reply was,
    Basically in XML Schema Admin.xsd element AdminCompin WorkfileTypeneeds to be stored Out of line..
    Add the annotations xdb:SQLInline=”false” and xdb:defaultTable=”ADMIN_COMP_XML”. to the element..
    if you can share with our XML Schema on how to annotate or if you can share a location that shows how an annotated or non-annotated Schema works that would help us correcting our Schema files.
    Thanks for all your support. We have gone a long way in XML Parsing in the last 6 weeks.
    Edited by: beta32c on Feb 19, 2013 12:09 AM

  • BPELProcess - Assign Activity - xsd choice element difficulties

    Hi,
    I am trying to copy values from a pipe ("|") delimited text file that has been picked - up by a file adaptor and converted into xml of form (C1,C2,C3,...,Cn). My problem arises when I need to populate an xsd:choice element with C5 & C6 as the same type. If you need more info just let me know, Please advise...
    Kind Regards,
    Warren.

    well, lets say ur looking at the 'Copy Rules' screen, my converted string delimited file is on the left and the xsd im copying to is the right+ :
    body                             body
    spiLine                           ServiceOrder
    C1 ------------------- orderType
    C2 ------------------- refrence number
    ... +choice
    +equipment
    C5 ------------------ value
    C6
    if you can make any sense of this, what I need is to create another equipment node to assign C6 too, in the xsd:choice element...

  • Mapping of any element in BPEL

    Hello Experts,
    Need some help on this.I am unable to understand how to map <any> element with the <any> element.In my xsd i have a input element with any any an Output element with any i am unable to map.While mapping it pops up the message as "cannot map any to anyAttribute from source" Enter xpath-expression manually.Plz help
    Thanks in Advance
    Edited by: Irfan Shaikh on Feb 8, 2013 2:10 PM
    Edited by: Irfan Shaikh on Feb 8, 2013 2:25 PM

    Just open the source view and Enter xpath-expression manually as the message suggests...

  • Any Element Support

    Does XDB support xml schema with any elements? What will the any element mapped to?
    Thanks
    Bob

    The reason I'm asking is that the following test case is not working for me - Please help.
    1). My xsd file "Test.xsd" -
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb" version="1.0">
         <xs:element name="TestAny" type="ComplexType" xdb:defaultTable="TEST_ANY"/>
         <xs:complexType name="ComplexType" xdb:SQLType="XDB_COMPLEX_TYPE">
              <xs:sequence>
                   <xs:any minOccurs="1" maxOccurs="unbounded"/>
              </xs:sequence>
         </xs:complexType>
    <xs:element name="Element1" type="xs:string" />
    <xs:element name="Element2" type="xs:string" />
    </xs:schema>
    2). After registering with Oracle, the following Objects generated -
    TNAME TABTYPE
    Element1413_TAB TABLE
    Element2412_TAB TABLE
    TEST_ANY TABLE
    SQL> desc test_any
    Name Null? Type
    TABLE of SYS.XMLTYPE(XMLSchema "http://MOB5164:8080/Test.xsd" Element "TestAny") STORAGE Object-rela
    tional TYPE "XDB_COMPLEX_TYPE"
    SQL> desc "XDB_COMPLEX_TYPE"
    "XDB_COMPLEX_TYPE" is NOT FINAL
    Name Null? Type
    SYS_XDBPD$ XDB.XDB$RAW_LIST_T
    SYS_XDBANY411$ VARCHAR2(4000)
    SQL> desc "Element1413_TAB"
    Name Null? Type
    TABLE of SYS.XMLTYPE(XMLSchema "http://MOB5164:8080/Test.xsd" Element "Element1")
    SQL> desc "Element2412_TAB"
    Name Null? Type
    TABLE of SYS.XMLTYPE(XMLSchema "http://MOB5164:8080/Test.xsd" Element "Element2")
    3). ftp xml file "Test.xml" to XDB - (the file has been validated by XMLSpy)
    <?xml version="1.0" encoding="utf-8"?>
    <TestAny xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://mob5164:8080/Test.xsd">
         <Element1>this is element 1</Element1>
         <Element1>this is element 1</Element1>
         <Element2>this is element 2</Element2>
         <Element2>this is element 2</Element2>
         <Element1>this is element 1</Element1>
    </TestAny>
    4). The file is loaded into the XDB repository instead of to table TEST_ANY.
    Bob

  • Accessing xsd:any in the process

    Folks,
    I have an input element, which contains xsd:any . we have defined a schema with several elements and the request message can contain any of these elments defined in the schema. At runtime, how can identify which element was sent my consumer and access those values in BPEL Process?
    Thanks/steve

    I also have the same requirement .Please let me know the if anyone have done it so far.
    any documentation is also of great help.
    Thanks
    Deepthi

  • I write both JPG and DNG files in the camera.   Camera is a Leica Monochrom.   Photo, unlike iPhoto, seems to ignore DNG files and only imports JPG files.   What am I missing here?

    I write both JPG and DNG files in the camera.   Camera is a Leica Monochrom.   Photo, unlike iPhoto, seems to ignore DNG files and only imports JPG files when both are present on the SD card.  JPGs are used for quick proofing on an iPad.    DNG RAW files are edited on a Mac Pro (2013).    Other than deleting the JPGs before importing images from the SD card,  is there any way to force Photo to select and import only the DNG images?

    Thanks Larry,
    I did see the J stacked in the lower left of the thumbnails but couldn't figure out how to get to whatever is below it.   How do you select R?  
    I use an iPad to do quick proofs of my images.   A JPG is good enough for a proof ( dust on the lens,  composition, blown out image, etc. ).   The iPad is JPG friendly and can load the images quickly.    Serious editing takes place on my Mac Pro with the DNG files.   I use the same workflow with the the Leica M 240.   iPhoto has been a quick and easy importer to the Mac capturing all of the metadata in the EXIF sidecar file ( location, date, time,  camera settings, lens type).  A quick scan in iPhoto for the "keepers" let's me export those worth editing to Lightroom/Bridge/Photoshop.  I typically shoot 50 images from three locations in a normal day.  If I'm lucky I'll get 1 worth real work to add to the portfolio.  

  • Urgent!! - Validating Any Element using schema

    Hi,
    I am relatively new to XML. I need to return the out in XML. Here is the sample schema
    <?xml version="1.0"?>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
                   targetNamespace="http://www.its.ws/Inventory"
         xmlns="http://www.its.ws/Inventory">
         <xsd:element name="RESULT">
              <xsd:complexType>
                   <xsd:sequence>
                        <xsd:element ref="DESCRIPTION"/>
                        <xsd:any minOccurs="0"/>
                   </xsd:sequence>
                   <xsd:attribute name="Status" use="required" type="xsd:integer"/>
                   <xsd:attribute name="ErrorCode" use="required" type="xsd:integer"/>
              </xsd:complexType>
         </xsd:element>
         <xsd:element name="DESCRIPTION" type="xsd:string"/>
         <xsd:element name="DELIVERY">
              <xsd:complexType>
                   <xsd:sequence>
                        <xsd:element ref="po_del_date"/>
                        <xsd:element ref="po_del_qty"/>
                   </xsd:sequence>
         </xsd:complexType>
         </xsd:element>
         <xsd:element name="po_del_date" type="xsd:string" />
         <xsd:element name="po_del_qty" type="xsd:string"/>
    </xsd:schema>
    And here is my XML
    <?xml version="1.0"?>
    <Result xmlns="http://www.its.ws/Inventry"
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
              xsi:schemaLocation="http://www.its.ws/Inventry Inventry.xsd"
              Status="1" ErrorCode="12">
              <Description>Vendor Code is NULL</Description>
              <Delivery>
                        <PurchaseOrderDelDate>2002-09-24</PurchaseOrderDelDate>
                        <PurchaseOrderDelQty>100.00</PurchaseOrderDelQty>
              </Delivery>
    </Result>
    In my XML file,
    I may or may not have Delivery element.
    If allows to have delivery element, doesn't validated it.
    When i validated in XMLWriter, it validates the Delivery element.
    Is this a bug in Oracle XML Engine or i am missing anything.
    Thanks in advance for ur advice

    Sorry, thats not the correct xml file.
    <?xml version="1.0"?>
    <RESULT xsi:schemaLocation="http://www.its.ws/Inventory ResultAny.xsd"
              xmlns="http://www.its.ws/Inventory"
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
              STATUS="0"
              ERRORCODE="0">
         <DESCRIPTION>There is no description defined</DESCRIPTION>
         <DELIVERY>
                        <!--<po_del_date>asdf</po_del_date>
                        <po_del_qty>asdf</po_del_qty>
                        -->
         </DELIVERY>
    </RESULT>
    Above is sample XML file. I am not concentrating on namespace, schema file and location ect,
    I have commented po_del_date & po_del_qty. There present is mandatory. It just checks whether xml file is proper or not, it does not validate, DELIVERY elements childs.
    When i validate it in XMLWriter, which users MSXML 4.x, it validates.

  • Jaxb xsd:any problem

    I am not sure how to set the namespace (please see schema snippet below). Do I do this with setAny(java.lang.Object)? What kind of object do I pass to setAny() because it is trying to class cast it to JAXBObject. How do I create an instance of JAXBObject?
    I have in my xsd:
    <xsd:element name="order">
              <xsd:complexType>
                   <xsd:sequence>
                        <xsd:any namespace="urn:abc.com" minOccurs="0" maxOccurs="1"/>
                        <xsd:element ref="a"/>
                        <xsd:element ref="b"/>
                   </xsd:sequence>
                   <xsd:attribute name="locale" type="xsd:string" use="optional"/>
                   <xsd:attribute name="sourceid" type="xsd:string" use="optional"/>
              </xsd:complexType>
         </xsd:element>

    Refer to section
    E.2 Not Required XML Schema
    concepts
    "A JAXB implementation is not required to support the following XML Schema
    concepts for this version of the specification. A JAXB implementation may
    choose to support these features in an implementation dependent manner."
    E.2.2 Not supported while manipulating the XML
    content
    Schema component: wildcard
    (any)
    how can i know if an xml element with xsi:nil="true" (unmarshal)
    and set xsi:nil="true" for an element (marshal) ?
    According to the JAXB 1.0 specification:
    If {nillable} is "true", the methods setNil() and isNil() are
    generated.

Maybe you are looking for

  • UTL_SMTP send HTML email with embedded image?

    Hi, I can use UTL_SMTP to send an HTML email ok, but does anyone have an example of how to include an inline embedded image in the email? Thanks!

  • How to execute code from a text file?

    Hello all! How to execute some code lines from a text file? For example my file is: String varname = "somecontents"; JFrame frame = new JFrame(); frame.setVisible(true);How can I get contents of this file and parse them if I want get new JFrame and a

  • Cinelerra 1.2.1 progress

    Hello all, im able now to compile cinelerra without any errors but some warnings still remain. But befor you are looking foreward to using cinelerra 1.2.1 on archlinux, you should recognice, that there seems to be problems with glibc-NPTL or somethin

  • MODULEPOOL-TABLECONTROL

    <<Moderator message: please use a meaningful subject, and not in all CAPITALS.  Thank-you>> Hai,   goodmorning to all,this is srinivas. my problem is that i have created a module pool pgm using tabstrip control.now i need to insert table control in t

  • ITunes reading external hard drive.

    My iTunes library was on an external hard drive. I got a new external hard drive and transfered everything over to the new drive. iTunes sees the music but it asks me to locate each song before it will play. I have to go through folders to find the e