This week's book giveaway is in the OCAJP forum.
We're giving away four copies of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) and have Khalid A Mughal & Rolf W Rasmussen on-line!
See this thread for details.
Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error with JSP: Doesn't work with my object, it does with a String

 
Jon Pepe
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm reediting: It's a Maven project and I have to add a external file to the repository.

I'm explaining what happened. The class Nodo had a method that uses JDOM library, and it was failing. That's why it worked with a string, a string doesn't use that library. Now I have supressed that method and it works, but I still need that method. Do you know how can I make it work? As I say down here, I use Springsource Tool Suite (eclipse) and I had added the jdom.jar file as a external jar in the build path.


Hi guys,
I hope you can help me. I'm creating an easy MVC web app with Spring Framework (using STS) and I'm having problems with JSP.

I have a jsp page where I want to show some properties of my object "Nodo", but I'm getting this error:


---------------------------------
NODO CLASS


-------------------------------------
CONTROLLER


-------------------------------------
WEB.XML

--------------------------------------------------
SIM-SERVLET.XML


----------------


I hope it's a silly error and you can help me, it would be great for me. Thank you.
 
Jon Pepe
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course the class Nodo have setters and getters:

 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65111
89
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/jdom/JDOMException

Looks like you are missing the jar file for JDOM.
 
Jon Pepe
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault wrote:
javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/jdom/JDOMException

Looks like you are missing the jar file for JDOM.


I've got it in the build path, I added as a external JAR with Eclipse.

I use JDOM for extracting information from an .xml document in a method in the Nodo class. I tried supressing it and it works! So I have to do something with that .jar because in the moment of the building something goes wrong. Can someone help me?

Bear Bibeault, thank you very much, really.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65111
89
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You should have mentioned this is an IDE setup issue. Moved to the IDEs forum.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic