Jaxb xs:any problem

I have the following xsd.
<xs:element name="test" type="test"/>
<xs:complexType name="test">
<xs:all>
<xs:element name="Error" type="xo_000EMError"/>
</xs:all>
</xs:complexType>
<xs:complexType name="xo_000EMError">
<xs:all>
<xs:element name="Descriptions" type="xo_000EMErrorDescriptions" minOccurs="0"/>
</xs:all>
</xs:complexType>
<xs:complexType name="xo_000EMErrorDescriptions">
<xs:sequence>
     <xs:element name="Reason" maxOccurs="unbounded">
<xs:complexType>
<xs:complexContent>
<xs:extension base="xo_000EMAny">
<xs:attribute name="LNG" type="languageCode" use="required"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="xo_000EMAny" mixed="true">
<xs:complexContent mixed="true">
<xs:restriction base="xs:anyType">
<xs:sequence>
<xs:any processContents="skip" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
</xs:restriction>
</xs:complexContent>
</xs:complexType>
I use JAXB 1.0.6 (no choice on the version) to generate my sources. I tried the following with extension=false and extension=true to avoid the "skip"-warnings.
No matter which extension-parameter is used, when I read a valid xml-document I see that everything that is placed in the any block
<Reason LNG="3"><test>a test</test></Reason>
is replaced with an empty string.
Is there a possibility to obtain the content of the reason-tag? Do I have to generate it differently? Do I have to use binding?
Any help is welcome, thank you

Here is a schema fragment:
                              <xsd:element name="AK-Unemployment" type="xsd:anyType" minOccurs="0">
                                   <xsd:annotation>
                                        <xsd:documentation>The presence of this element indicates that Alaska Unemployment tax should be calculated</xsd:documentation>
                                   </xsd:annotation>
                              </xsd:element>
Then in your code you could do something like this (Note I am using the final release of JAXB):
          AnyType anyType = objFactory.createAnyType();
localTypes.setAKUnemployment(anyType);
This will result in an empty element:
<AKUnemployment></AKUnemployment>

Similar Messages

  • 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.

  • MacBook Pro does not boot when 'cold', Windows 7 on the other hand boots without any problem

    Hey everyone,
    I have a strange problem with my MacBook Pro mid 2009 13" running OSX Mavericks. For more than a year I have trouble booting my laptop. A 'cold' start (a fresh boot) usually ends with the prohibition sign on a grey back ground (starting in verbose mode results in the error message that the main drive could not be found). So far so strange.
    I have Windnows 7 installed as a bootcamp partition. If I start the laptop with Windows booting is no problem and Windows runs smoothly (what a terrible world we live in). If I let the laptop run for let say 10 minutes and restart the laptop Mac OS starts without any problems. (It doesn't work if I immediately restart after windows booted; also reinstalling Mac OS as a clean install from an external medium did not change the problem; disk utility always finds something to repair but neither discpermission repair nor disk repair got rid of the problem).
    As an additional comment a WD 500GB Scorbio Blue replaced the original hard drive about a years ago. I had no problems with the hard drive initally and I can't really believe that there is a problem with the hardware, I mean, why does Windows start and Mac OS doesn't?
    Thanks for your time and help!
    Marco

    This isn't a direct answer to your issue but have you considered installing Wine so you can run the occasional windows app directly in OSX? It's a much more elegant solution IMHO. This avoids restarting all the time with Bootcamp and avoids crashing all the time (and the security risks) with Windows running.

  • Hi. I am just about to move from the UK to Kuwait. Will I have any problems using my iPhone 4 and able to join a local carrier using this device please?

    Hi. I am just about to move from the UK to Kuwait. Will I have any problems using my iPhone 4 and able to join a local carrier using this device please?

    If your phone is locked to a particular carrier, you must contact them to request they unlock it. Once they've taken care of that and you've followed the instructions to complete the unlock process, you will be able to use the phone elsewhere.
    ~Lyssa

  • I have owned my MacBook Pro for several months.  Initially, I did not have any problems.  Now I have a problem with Yahoo Mail.  I can open my account, but when I try to get at my mail, 2 out of 3 times I get the spinning ball that never stops.  Now what?

    I have owned my MacBook Pro for several months without having any problems with it. Recently I am having trouble with my Yahoo Mail.  I can open it fine, but 2 out of 3 times when I try to actually open a message, the spinning ball comes on the screen and does not stop. Sometimes, I can log out or force quit and come back in to my account and use it.  Other times, I run into the same problem.  Any suggestions?

    Killerfinch wrote:
    My new yahoo account nestles comfortably in iCloud on the mine iPad.
    No, your Yahoo account is not in iCloud (which only handles iCloud mail), it is in Yahoo, and the Yahoo mail account is on your iPad.
    But the MacBook Pro will have none of it! I write this question now as I fear that I will be totally demented very soon and unable to formulate my thoughts clearly!
    Get the correct settings for your account from Yahoo and set it up manually.
    By the way, I also find the "password" issue problematical. It seems Apple want my Apple password rather than my eMail password. All very confusing.
    That would depend on what you are trying to do.

  • I have bought a Season pass for The Big Bang Theory. I have downloaded alle recent Epiodes without any Problems. But now... i can't download the latest Version for free. Itunes doesn't recognize my Season pass and let's me buy it again. Whats going?

    I have bought a Season pass for The Big Bang Theory. I have downloaded alle recent Epiodes without any Problems. But now... i can't download the latest Version for free. Itunes doesn't recognize my Season pass and let's me buy it again. Whats going? Do I miss something?
    Best regards,
    Michele

    Contact iTunes Customer Service and request assistance
    Use this Link  >  Apple  Support  iTunes Store  Contact

  • I am trying to connect to my friend's wifi, i have a very strong signal indicated on my ipad, but cannot connect to the internet.  Yesterday i connected without any problem, can anybody tell me why i cannot connect today?

    i am trying to connect to my friend's wifi, i have a very strong signal indicated on my ipad, but cannot connect to the internet.  Yesterday i connected without any problem, can anybody tell me why i cannot connect today?

    Some things to try first:
    1. Turn Off your iPad. Then turn Off (disconnect power cord for 30 seconds or longer) the wireless router & then back On. Now boot your iPad. Hopefully it will see the WiFi.
    2. Go to Settings>Wi-Fi and turn Off. Then while at Settings>Wi-Fi, turn back On and chose a Network.
    3. Change the channel on your wireless router (Auto or Channel 6 is best). Instructions at http://macintoshhowto.com/advanced/how-to-get-a-good-range-on-your-wireless-netw ork.html
    4. Go into your router security settings and change from WEP to WPA with AES.
    5.  Renew IP Address: (especially if you are droping internet connection)
        •    Launch Settings app
        •    Tap on Wi-Fi
        •    Tap on the blue arrow of the Wi-Fi network that you connect to from the list
        •    In the window that opens, tap on the Renew Lease button
    6. Potential Quick Fixes When Your iPad Won’t Connect to Your Wifi Network
    http://ipadinsight.com/ipad-tips-tricks/potential-quick-fixes-when-your-ipad-won t-connect-to-your-wifi-network/
    ~~~~~~~~~~~~~~~~~~~~~~~~~
    iOS 6 Wifi Problems/Fixes
    Wi-Fi Fix for iOS 6
    https://discussions.apple.com/thread/4823738?tstart=240
    How To: Workaround iPad Wi-Fi Issues
    http://www.theipadfan.com/workaround-ipad-wifi-issues/
    Another Fix For iOS 6 WiFi Problems
    http://tabletcrunch.com/2012/10/27/fix-ios-6-wifi-problems-ssid/
    Wifi Doesn't Connect After Waking From Sleep - Sometimes increasing screen brightness prevents the failure to reconnect after waking from sleep. According to Apple, “If brightness is at lowest level, increase it by moving the slider to the right and set auto brightness to off.”
    Fix For iOS 6 WiFi Problems?
    http://tabletcrunch.com/2012/09/27/fix-ios-6-wifi-problems/
    Did iOS 6 Screw Your Wi-Fi? Here’s How to Fix It
    http://gizmodo.com/5944761/does-ios-6-have-a-wi+fi-bug
    How To Fix Wi-Fi Connectivity Issue After Upgrading To iOS 6
    http://www.iphonehacks.com/2012/09/fix-wi-fi-connectivity-issue-after-upgrading- to-ios-6.html
    iOS 6 iPad 3 wi-fi "connection fix" for netgear router
    http://www.youtube.com/watch?v=XsWS4ha-dn0
    Apple's iOS 6 Wi-Fi problems
    http://www.zdnet.com/apples-ios-6-wi-fi-problems-linger-on-7000004799/
    ~~~~~~~~~~~~~~~~~~~~~~~
    How to Boost Your Wi-Fi Signal
    http://ipad.about.com/od/iPad_Troubleshooting/a/How-To-Boost-Your-Wi-Fi-Signal.h tm
    Troubleshooting a Weak Wi-Fi Signal
    http://ipad.about.com/od/iPad_Troubleshooting/a/Troubleshooting-A-Weak-Wi-Fi-Sig nal.htm
    How to Fix a Poor Wi-Fi Signal on Your iPad
    http://ipad.about.com/od/iPad_Troubleshooting/a/How-To-Fix-A-Poor-Wi-Fi-Signal-O n-Your-iPad.htm
    iOS Troubleshooting Wi-Fi networks and connections  http://support.apple.com/kb/TS1398
    iPad: Issues connecting to Wi-Fi networks  http://support.apple.com/kb/ts3304
    WiFi Connecting/Troubleshooting http://www.apple.com/support/ipad/wifi/
    How to Fix: My iPad Won't Connect to WiFi
    http://ipad.about.com/od/iPad_Troubleshooting/ss/How-To-Fix-My-Ipad-Wont-Connect -To-Wi-Fi.htm
    iOS: Connecting to the Internet http://support.apple.com/kb/HT1695
    iOS: Recommended settings for Wi-Fi routers and access points  http://support.apple.com/kb/HT4199
    How to Quickly Fix iPad 3 Wi-Fi Reception Problems
    http://osxdaily.com/2012/03/21/fix-new-ipad-3-wi-fi-reception-problems/
    iPad Wi-Fi Problems: Comprehensive List of Fixes
    http://appletoolbox.com/2010/04/ipad-wi-fi-problems-comprehensive-list-of-fixes/
    Connect iPad to Wi-Fi (with troubleshooting info)
    http://thehowto.wikidot.com/wifi-connect-ipad
    Fix iPad Wifi Connection and Signal Issues  http://www.youtube.com/watch?v=uwWtIG5jUxE
    Fix Slow WiFi Issue https://discussions.apple.com/thread/2398063?start=60&tstart=0
    How To Fix iPhone, iPad, iPod Touch Wi-Fi Connectivity Issue http://tinyurl.com/7nvxbmz
    Unable to Connect After iOS Update - saw this solution on another post.
    https://discussions.apple.com/thread/4010130
    Note - When troubleshooting wifi connection problems, don't hold your iPad by hand. There have been a few reports that holding the iPad by hand, seems to attenuate the wifi signal.
    Wi-Fi or Bluetooth settings grayed out or dim
    http://support.apple.com/kb/TS1559
    ~~~~~~~~~~~~~~~
    If any of the above solutions work, please post back what solved your problem. It will help others with the same problem.
     Cheers, Tom

  • Hello everyone: I am going to buy a new ipad in Australia and after that I am going back to China. I am just wondering if I can use it in China without any problem? Do I have to unlock or something like that?

    Hello everyone: I am going to buy a new ipad in Australia and after that I am going back to China. I am just wondering if I can use it in China without any problem? Do I have to unlock or something like that?

    The iPad is not locked. Read the specifications.
    http://www.apple.com/ipad/specs/

  • I am going to buy unlocked iphone 5.. i will be going to india nxt months and will stay there for a while... so my question is will i get warrenty in india.. and will there be any problem with using indian sims..?? thnx for the help..

    i am going to buy unlocked iphone 5.. i will be going to india nxt months and will stay there for a while... so my question is will i get warrenty in india.. and will there be any problem with using indian sims..?? thnx for the help..

    The warranty for the iPhone is not and has never been International.
    Warranty and support are ONLY valid in the country of origin.  The only exception is the EU where the entire EU is treated as one country.
    If the device will be used in India, buy it in India.
    An unlocked iPhone will work on any supported GSM carrier world wide.  The LTE portion of a US purchased, unlocked iPhone is unlikely to work outside North America as it does not support the appropriate bands used in other countries.

  • I have been using Final Cut pro v6 without any problems but recently had to reinstall.  Since then I can't open and view all my Quicktime clips.  They appear white in timeline which means you can hear audio but not view picture.  Any tips?

    I have been using Final Cut Pro without any problems - v6 - for ages.  I recently had a hardware issue and had to reinstall the software.  Since then I can't open most of my QT clips in my fcp project.  They appear as white clips - audio only no pictures.  There are a few QT clips you can view as regular thumbnail images and they play ok.  What's the issue?  I have fcp v6.0.6 and QT v7.  Any thoughts on what to do next?

    Yes I did software updates which updated fcp to 6.0.6 and QT to version 7.7.  That's as far as updates have taken me although i have requested daily updates.  I forgot to say the clips don't play in QT view either.  Again sound but no pictures when they are played.

  • A magazine's app on my iPad has stopped working.  When I open the Newsstand folder and click on the app, the screen dims briefly, then returns to the Newsstand folder. The other app in my Newsstand folder (Wall Street Journal) opens without any problem.

    A magazine's app on my iPad has stopped working.  When I open the Newsstand folder and click on the app, the screen dims briefly, then returns to the Newsstand folder. The other app in my Newsstand folder (Wall Street Journal) opens without any problem, and this magazine's app opens just fine on my wife's iPad.
    I have deleted the app and reinstalled it from the Apple store and that makes no difference.  I have also done a hard reboot on my iPad with no result.
    Any thoughts about what might be wrong? 

    Hey everyone in Apple world!
    I figured out how to fix the flashing yellow screen problem that I've been having on my MBP!  Yessssss!!!
    I found this super handy website with the golden answer: http://support.apple.com/kb/HT1379
    I followed the instructions on this page and here's what I did:
    Resetting NVRAM / PRAM
    Shut down your Mac.
    Locate the following keys on the keyboard: Command (⌘), Option, P, and R. You will need to hold these keys down simultaneously in step 4.
    Turn on the computer.
    Press and hold the Command-Option-P-R keys before the gray screen appears.
    Hold the keys down until the computer restarts and you hear the startup sound for the second time.
    Release the keys.
    I went through the 6 steps above twice, just to make sure I got rid of whatever stuff was holding up my bootup process.  Since I did that, my MBP boots up just like normal.  No flashing yellow screen anymore!!   
    (Note that I arrived at this solution when I first saw this page: http://support.apple.com/kb/TS2570?viewlocale=en_US)
    Let me know if this works for you!
    Elaine

  • I am receiving a new ipad (3 i guess) from my mom who is in the U.S but i am currently in the philippines. I ofcourse, want to have apps,games,movies etc. can i use an itunes giftcard (also from the U.S) to buy my apps without any problems?

    i am receiving a new ipad (3 i guess) from my mom who is in the U.S but i am currently in the philippines. I ofcourse, want to have apps,games,movies etc. on it. can i use an itunes giftcard (also from the U.S) to buy my apps without any problems?

    No.
    iTunes terms of service:
    The iTunes Service is available to you only in the United States, its territories, and possessions. You agree not to use or attempt to use the iTunes Service from outside these locations. Apple may use technologies to verify your compliance.

  • I can use my appleID without any problems for using to download new apps in the app-store or Itunes - Problem: I can´t use my ID at facetime and Imessage - I´d like to add an EMail account on top to my mobile number. My password will not be accepted!!!???

    I can use my appleID without any problems for using to download new apps in the app-store or Itunes - Problem: I can´t use my ID at facetime and Imessage -
    I´d like to add an EMail account on top to my mobile number to use more this services. My password will not be accepted!!!??? I try it and i try it and i try ist, throughout the same problem. Whats on? The user help desk said, i´ve to reset and use the WLAN key new as well as possible - no way!

    Contact the App store for Apple ID help. Their support link is on the right of the App store window
    LN

  • I can't download Snapchat on my iPod Touch 4G- it says I need IOS 7 which I can't get. However, I was able to download an older version of the app from iTunes last weekend without any problems. How do I download an earlier version of Snapchat?

    Last weekend I was able to download an earlier version of Snapchat from iTunes without any problems.
    I now won't let me download Snapchat at all, saying it needs IOS 7.
    Why is it doing this and how can I download an earlier version of Snapchat onto my iPod again?
    I don't understand why this week it has started saying I need IOS 7, without giving me the option to download an earlier version.
    Many Thanks

    Try:
    Starting when iOS 7 was released, Apple now allows downloading the last compatible version of some apps (iOS 4.2.1 and later only)
    App Store: Downloading Older Versions of Apps on iOS - Apple Club
    App Store: Install the latest compatible version of an app
    You first have to download the non-compatible version on your computer. Then when you try to purchase the version on your iPod you will be offered a compatible version if one exists.
    However, sometimes a previous version is not available.

  • Any problems to upgrade Mac to Lion with sync with iPhone 3G?

    Do you know if there are any problems to sync iPhone 3G (version 3.1.3) with MacBookpro after installing Lion on it?
    I don't want to upgrade iPhone to version 4 because many known problems.
    I'd like install Lion on Mac but the question is: Mac will be sync, via iTunes, with iPhone 3G after this installation? Thanks

    You will notice that it runs more slowly if you choose to upgrade. Other than that, I have not heard of an major issues with iOS 8.
    I too have an iPhone 4S and am going to hold off on upgrading unless I have to restore my phone or an app I'm using requires me to update in order for it to work.
    ~Lyssa

Maybe you are looking for

  • Downloading flash player problems

    Im trying to download Adobe Flash Player however wants i allow the activex, it still wont load. comes back with a message the Windows classifies it as an unknown publisher. I had tried disabling my firewall however this did not help. any suggestions?

  • Cash Discount Clearing account

    Hi all! When i set up G/L determination, i don't know Cash Discount Clearing account will appear in what tracsaction. Can you show me any transaction relate with this account. Thank you!

  • PR Overall Release Workflow - Agents Determination Failed

    Dear All WF Experts, I have used the standard workflow WS20000077 for PR Overall Release. I have assigned the agents to the task TS20000159 by position maintained in the Workflow Organizational Management Structure. The agents' names are showing corr

  • Applying template or button not possible

    when applying a template in DVDSP4.0.2 the application comes up with a window applying template, DVDSP cannot quit however. Applying/creating a button is not possible! Re-installing the software did not solve the problem. Does anyone knows how to sol

  • Calc - Agg - issue

    Hi All, We are aggregating all members below (California) Entity. Fix (Member 1) @IDescendants(California) End Fix Californial is a duplicate member and it is not being accepted. Any suggestion on how to aggregate. we have tried Agg(Entity) also.....