Win a copy of Beginning Java 17 Fundamentals: Object-Oriented Programming in Java 17 this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

ERROR : Incompatible object argument ??

 
Ranch Hand
Posts: 261
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone,
I have a servlet class which receives data entered by the user on the UI front and then it creates an instance of another class file (an XML Parser class). However, when the parser class is instantiated WebSphere throws an error which reads as follows :
[Servlet Error]-[(class: xmlParse/ParseXMLUsingDom, method: readXML signature: ()Ljava/lang/String;) Incompatible object argument for method call]: java.lang.VerifyError: (class: xmlParse/ParseXMLUsingDom, method: readXML signature: ()Ljava/lang/String Incompatible object argument for method call

Any and all help regarding this problem would be very welcome. I am using WSAD v 5.0.0
 
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Anirvan Majumdar:
Hello everyone,
I have a servlet class which receives data entered by the user on the UI front and then it creates an instance of another class file (an XML Parser class). However, when the parser class is instantiated WebSphere throws an error which reads as follows :
[Servlet Error]-[(class: xmlParse/ParseXMLUsingDom, method: readXML signature: ()Ljava/lang/String;) Incompatible object argument for method call]: java.lang.VerifyError: (class: xmlParse/ParseXMLUsingDom, method: readXML signature: ()Ljava/lang/String Incompatible object argument for method call

Any and all help regarding this problem would be very welcome. I am using WSAD v 5.0.0




We had a similar problem with WASD, and ended up taking the jdom.jar files out of our WASD directories. I know there has to be a better way than that, but we didn't know it at the time. Now, when we deploy the thing, we get the same error. I think the problem can be solved by adjusting the build path and the order in which jars are loaded.

If you were to load the real jdom.jar (not WASDs) first, you shouldn't have a problem. Please let me know if this works, cause I'd like to try the same thing!
 
Anirvan Majumdar
Ranch Hand
Posts: 261
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ron,
I didn't try your approach, though what i did was remove the jar file (xerces.jar) and substituted it with a more recent version (xercesImpl.jar). This has successfully removed the problem. I think the error occurred in the first place because of the version conflict of the older JAR file and the JDK version of my application.
 
WHAT is your favorite color? Blue, no yellow, ahhhhhhh! Tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic