Moving from com.sun.xml classes to the new xml support integrated in java

So far, for our XML implementation, we have used the DocumentEx, ElementEx, etc. from com.sun.xml.
We understand that xml is now supported by the java itself (javax.xml.parsers?) and we wish to update our code to use the newer API.
Is there a simple mapping between the old DocumentEx and ElementEx and new classes in javax.xml? Can it really be simple to "get rid" of com.sun.xml?

The combination of the:
Oracle XML SQL Utility
and
Oracle XML Parser for PLSQL V2
give you what you need.
null

Similar Messages

  • Getting the JAXB exception like "Two classes have the same XML type name-"

    Getting the JAXB exception like "Two classes have the same XML type name...",
    Here is the exception details:
    Exception in thread "main" com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions Two classes have the same XML type name "city". Use @XmlType.name and @XmlType.namespace to assign different names to them. this problem is related to the following location: at com.model.City at public com.model.City com.model.Address.getCurrentCity() at com.model.Address this problem is related to the following location: at com.common.City at public com.common.City com.model.Address.getPreviousCity() at com.model.Address
    at com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException$Builder.check(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl$JAXBContextBuilder.build(Unknown Source) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(Unknown Source) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(Unknown Source) at javax.xml.bind.ContextFinder.find(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at com.PojoToXSD.main(PojoToXSD.java:17)
    I took the example like:
    package com.model; ---->this package contains 'Address' class and 'City' class
    public class Address {
    private String areaName; private City currentCity; private com.common.City previousCity;
    package com.model;
    public class City {
    private String cityName;
    Another city class in "com.common" package.
    package com.common;
    public class City {
    private String pinCode;
    We need to create XSDs and needs to do the Marshalling and unmarshalling with the existing code in our project(like as above example code), code does not have any annotations like "@XmlRootElement/@XmlType" and we can not able to change the source code.
    I would like to know is there any solution to fix the above issue or any other ways to create XSDs and marshaling/unmarshalling(like MOXy..etc)?
    It would be great if i can get the solution from any one....May thanks in advance.
    Thanks,
    Satya.

    Getting the JAXB exception like "Two classes have the same XML type name...",
    Here is the exception details:
    Exception in thread "main" com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions Two classes have the same XML type name "city". Use @XmlType.name and @XmlType.namespace to assign different names to them. this problem is related to the following location: at com.model.City at public com.model.City com.model.Address.getCurrentCity() at com.model.Address this problem is related to the following location: at com.common.City at public com.common.City com.model.Address.getPreviousCity() at com.model.Address
    at com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException$Builder.check(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.(Unknown Source) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl$JAXBContextBuilder.build(Unknown Source) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(Unknown Source) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(Unknown Source) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at javax.xml.bind.ContextFinder.newInstance(Unknown Source) at javax.xml.bind.ContextFinder.find(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at javax.xml.bind.JAXBContext.newInstance(Unknown Source) at com.PojoToXSD.main(PojoToXSD.java:17)
    I took the example like:
    package com.model; ---->this package contains 'Address' class and 'City' class
    public class Address {
    private String areaName; private City currentCity; private com.common.City previousCity;
    package com.model;
    public class City {
    private String cityName;
    Another city class in "com.common" package.
    package com.common;
    public class City {
    private String pinCode;
    We need to create XSDs and needs to do the Marshalling and unmarshalling with the existing code in our project(like as above example code), code does not have any annotations like "@XmlRootElement/@XmlType" and we can not able to change the source code.
    I would like to know is there any solution to fix the above issue or any other ways to create XSDs and marshaling/unmarshalling(like MOXy..etc)?
    It would be great if i can get the solution from any one....May thanks in advance.
    Thanks,
    Satya.

  • Two classes have the same XML type name??? Please, help...

    Hello!
    I have a simple web service class. I generated the ws server-side classes using wsgen.
    I created a jar file from the generated code.
    Then :
    Endpoint endPoint = Endpoint.create(
    new WebServicesUnitImpl()
    String wsFinalName = "http://localhost:9999/akarmi";
    endPoint.publish( wsFinalName );
    The web service started fine.
    Then called wsimport, and the generated classes have been placed into a jar file.
    Then called the code like this:
    WebServicesUnitImplService service = new WebServicesUnitImplService();
    WebServicesUnitImpl unit = service.getWebServicesUnitImplPort();
    unit.serviceXXX();
    but the code doesn't work at all, resulting this error message:
    Two classes have the same XML type name "{http://ws.components.core.ilogique.vii.com/}getMessages". Use @XmlType.name and @XmlType.namespace to assign different names to them.
         this problem is related to the following location:
              at com.vii.ilogique.core.components.ws.GetMessages
              at public com.vii.ilogique.core.components.ws.GetMessages com.vii.ilogique.core.components.ws.ObjectFactory.createGetMessages()
              at com.vii.ilogique.core.components.ws.ObjectFactory
         this problem is related to the following location:
              at com.vii.ilogique.core.components.ws.GetMessages
    I have this error report on all generated class file! How can i fix this?
    What is the main problem? The SE usage? I copied the lates jax-ws jars into endorsed lib resulting the same.
    Any help is appreciate.

    Hello!
    I have a simple web service class. I generated the ws server-side classes using wsgen.
    I created a jar file from the generated code.
    Then :
    Endpoint endPoint = Endpoint.create(
    new WebServicesUnitImpl()
    String wsFinalName = "http://localhost:9999/akarmi";
    endPoint.publish( wsFinalName );
    The web service started fine.
    Then called wsimport, and the generated classes have been placed into a jar file.
    Then called the code like this:
    WebServicesUnitImplService service = new WebServicesUnitImplService();
    WebServicesUnitImpl unit = service.getWebServicesUnitImplPort();
    unit.serviceXXX();
    but the code doesn't work at all, resulting this error message:
    Two classes have the same XML type name "{http://ws.components.core.ilogique.vii.com/}getMessages". Use @XmlType.name and @XmlType.namespace to assign different names to them.
         this problem is related to the following location:
              at com.vii.ilogique.core.components.ws.GetMessages
              at public com.vii.ilogique.core.components.ws.GetMessages com.vii.ilogique.core.components.ws.ObjectFactory.createGetMessages()
              at com.vii.ilogique.core.components.ws.ObjectFactory
         this problem is related to the following location:
              at com.vii.ilogique.core.components.ws.GetMessages
    I have this error report on all generated class file! How can i fix this?
    What is the main problem? The SE usage? I copied the lates jax-ws jars into endorsed lib resulting the same.
    Any help is appreciate.

  • Create start-up class in the config.xml

    Is there a specific location to insert <startup-class>...</startup-class> in the config.xml? It doesn't seems to work when I inserted it at the end between </saf-agent> and </domain> in the config.xml. Any idea?

    rwooleen,
    I am writing a script to insert the <startup-class> .. </startup-class> into the config.xml. Any hints as to where is a reliable spot to insert in the config.xml? Aside from this, is there any straight forward command prompt to do this.
    Thanks.

  • How can I access files that I moved from an older MacBook Pro to a newer one via Firewire and Migration assistant.  The files show up on the new MacBook but cannot be opened.  Thanks!

    How can I access files that I moved from an older MacBook Pro to a newer one via Firewire and Migration assistant?  The files show up on the new MacBook but cannot be opened.  Thanks!

    Get info then check permissions then add your curent user name (it was probably different on old Mac) and give your username full read/write permissions.

  • After moving from my home country (Poland) to the Middle East (UAE) with the same computer I can not get connected to Apple Store and iTunes Store.

    After moving from my home country (Poland) to the Middle East (UAE) with the same computer I can not get connected to Apple Store and iTunes Store. Any clue why?
    Regards,
    Maciek

    Click the round flag icon bottom right corner of the App Store window.

  • Moving tabs from one window to another makes the new window vanish. I have hot corners enabled so when I move up to the right corner of my display I can see all my open windows but when I click on the tab that I moved to make it its own window it vanishes

    Moving tabs from one window to another makes the new window vanish. I have hot corners enabled so when I move up to the right corner of my display I can see all my open windows but when I click on the tab that I moved to make it its own window it vanishes

    I came up with an alternative solution.
    Instead of actually trying to move the JInternalFrame from one JDesktopPane to another, I added a single, maximized JInternalFrame to the left side. When one of the right side frames is to be docked, I merely copy its ContentPane to the single JInternalFrame on the left, set the original to be non-visible, and adjust the properties of the JSplitPane to make the "docked" frame appear.
    When the "close" button on the docked frame is pressed, I simply undo this procedure to "undock" the frame and redisplay it on the right-hand side (with its content intact from the docked frame, but in its original position).

  • HT1473 I recently had to replace my hard drive and lost my iTunes library. Now I cannot transfer the library from my iPod to iTunes on the new hard drive (same computer). How can I complete the transfer?

    I recently had to replace my hard drive and lost my iTunes library.  When I try to transfer the content from my iPod to iTunes on the new hard drive (same computer), it would only let me transfer iTunes store purchases. How can I complete the transfer of all the content on the iPod back onto the computer?

    Recover media from iPod
    See this post for options on moving your iPod data back to your computer.
    tt2

  • I have not synced my iphone to my new computer.  My old computer is dead.  How do I keep the music on my iphone from disappearing and get synced to the new computer?

    I have not synced my iphone to my new computer.  My old computer is dead. How do I keep the music from disappearing and get synced to the new computer?

    This will cost you http://www.wideanglesoftware.com/touchcopy/index.php
    or see this doc http://discussions.apple.com/docs/DOC-3141

  • I got a new iPhone yesterday. The sales people set it up to use. I want to have all the apps, pics, etc from my iPod to be on the new iPhone. How do I do this from my iCloud backup  of the iPod??

    I got a new iPhone yesterday. The sales people set it up to use. I want to have all the apps, pics, etc from my iPod to be on the new iPhone. How do I do this from my iCloud backup  of the iPod??

    http://support.apple.com/kb/HT1766?viewlocale=en_US&locale=en_US
    Go to Settings>General>Reset and tap Erase All Content and Settings.  This will erase your device.  Then you will go through the setup screens again as you did when your device was new, and when given the option, select Restore from iCloud Backup.
    This link gives another overview of backup and restore:
    http://support.apple.com/kb/HT4859?viewlocale=en_US&locale=en_US
    Be aware that photos should always be synced to a computer for archiving and that relying on a restore from an icloud backup may not return all (or any) of your photos.  Once on the computer, you can sync the photos to the new device...
    Syncing Photos:
    From device to computer...
    http://support.apple.com/kb/HT4083
    From computer to device...
    http://support.apple.com/kb/HT4236

  • Error: 0xC020902A at Data Flow Task, XML Source [24515]: The "component "XML Source" (24515)" failed because truncation occurred, and the truncation row disposition on "output column "MsgLev1" (26196)" specifies failure on truncation. A truncation error o

    When I was Importing data from XML to SqlServer using SSIS , I am getting this error. The import is working if i use small file and not working if I use large XMl file. Can any one of you guys help me out with the issue?
    Error: 0xC020902A at Data Flow Task, XML Source [24515]: The "component "XML Source" (24515)" failed because truncation occurred, and the truncation row disposition on "output column "MsgLev1" (26196)" specifies failure on truncation. A truncation error occurred on the specified object of the specified component.
    Error: 0xC02092AF at Data Flow Task, XML Source [24515]: The component "XML Source" (24515) was unable to process the XML data. Pipeline component has returned HRESULT error code 0xC020902A from a method call.
    Error: 0xC0047038 at Data Flow Task: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED.  The PrimeOutput method on component "XML Source" (24515) returned error code 0xC02092AF.  The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing.  There may be error messages posted before this with more information about the failure.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "SourceThread0" has exited with error code 0xC0047038.  There may be error messages posted before this with more information on why the thread has exited.
    Error: 0xC0047039 at Data Flow Task: SSIS Error Code DTS_E_THREADCANCELLED.  Thread "WorkThread0" received a shutdown signal and is terminating. The user requested a shutdown, or an error in another thread is causing the pipeline to shutdown.  There may be error messages posted before this with more information on why the thread was cancelled.
    Error: 0xC0047039 at Data Flow Task: SSIS Error Code DTS_E_THREADCANCELLED.  Thread "WorkThread1" received a shutdown signal and is terminating. The user requested a shutdown, or an error in another thread is causing the pipeline to shutdown.  There may be error messages posted before this with more information on why the thread was cancelled.
    Error: 0xC0047039 at Data Flow Task: SSIS Error Code DTS_E_THREADCANCELLED.  Thread "WorkThread3" received a shutdown signal and is terminating. The user requested a shutdown, or an error in another thread is causing the pipeline to shutdown.  There may be error messages posted before this with more information on why the thread was cancelled.
    Error: 0xC0047039 at Data Flow Task: SSIS Error Code DTS_E_THREADCANCELLED.  Thread "WorkThread4" received a shutdown signal and is terminating. The user requested a shutdown, or an error in another thread is causing the pipeline to shutdown.  There may be error messages posted before this with more information on why the thread was cancelled.
    Error: 0xC0047039 at Data Flow Task: SSIS Error Code DTS_E_THREADCANCELLED.  Thread "WorkThread2" received a shutdown signal and is terminating. The user requested a shutdown, or an error in another thread is causing the pipeline to shutdown.  There may be error messages posted before this with more information on why the thread was cancelled.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread0" has exited with error code 0xC0047039.  There may be error messages posted before this with more information on why the thread has exited.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread1" has exited with error code 0xC0047039.  There may be error messages posted before this with more information on why the thread has exited.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread2" has exited with error code 0xC0047039.  There may be error messages posted before this with more information on why the thread has exited.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread3" has exited with error code 0xC0047039.  There may be error messages posted before this with more information on why the thread has exited.
    Error: 0xC0047021 at Data Flow Task: SSIS Error Code DTS_E_THREADFAILED.  Thread "WorkThread4" has exited with error code 0xC0047039.  There may be error messages posted before this with more information on why the thread has exited.

    The reason is in the first line of the error.  It doesn't have anything to do with the size of your XML file - it has to do with the contents of the "MsgLev1" column.  You (or the XSD) has indicated that the values in this column not exceed a certain size - but one of the values in the file that's failing is larger than that.
    In order to fix the problem, you're going to need to increase the allocated space for that column.  In order to do that, you're going to need to find out what the required size of that data is - either from someone who ought to know, or by direct examination of the file.  If you want to know which entity has this overly large data element in it, you need to configure the error handling of the XML Source to "redirect truncation errors".  Then you can hook up the XML Source's error output to another destination where you can see which rows are problematic.
    Talk to me on

  • Hello, i have mac book air Software  Mac OS X Lion 10.7.5 (11G63) from 2011, i want to install the new os x mavericks 10.9.5. does it slowly my mac? thanks

    hello, i have mac book air Software  Mac OS X Lion 10.7.5 (11G63) from 2011, i want to install the new os x mavericks 10.9.5. does it slowly my mac? thanks

    OS X Mavericks
    System Requirements
    http://support.apple.com/kb/HT5842
    MacBook Air runs OK with 4GB RAM, but with 8GB RAM installed, Mavericks runs well.
    http://www.everymac.com/systems/apple/macbook-air/specs/macbook-air-core-i5-1.7- 13-mid-2011-specs.html

  • How do I transfer playlists from itunes to my ipod on the new itunes format?

    how do I transfer playlists from itunes to my ipod on the new itunes format?

    I had the same question. Someone answered perfectly here https://discussions.apple.com/message/20575126#20575126
    The answer was click View > Show sidebar. Devices and playlists will display in the left sidebar once again. Copy playlists into iPod as usual.

  • My iphone is broken and i am getting a new one sent out. How do i get everything from my old phone copied to the new one so its exactly the same??

    My iphone is broken and i am getting a new one sent out. How do i get everything from my old phone copied to the new one so its exactly the same??

    As long as they are already ticked in your iTunes then yes. Just to check do a sync and as long as everything stays the same you are good to go.

  • I have an older Ipod Touch, I bought a new one and the Itunes on my computer is too old to recognize my new Ipod Touch and cannot be updated.  Is there a creditable software program I can use to get all my old music from my old iPod Touch to the new one?

    I have an older iPod Touch, I bought a new one and the Itunes on my computer is too old to recognize my new iPod Touch and Itunes cannot be updated.  Is there a creditable software program I can use to get all my old music from my old iPod Touch to the new one?  It is my understanding that the music cannot be saved onto my new iTunes, b/c I did not have iCloud. I have over 2,000 songs I just cannot part with. PLEASE PLEASE PLEASE help some how!!  THANKS!

    I had the same problem with my iPad, i couldn't get the newer version of itunes because the computer was too old and my iPad couldnt sync with the old itunes. I got a PC from school a few months later so that solved the problem for me. Unfortunately i don't think there would be a program to put your music on your iPod, iTunes should be the only way to transfer files to Apple devices. What operating system are you running and what version of it is it?

Maybe you are looking for