The moose likes Beginning Java and the fly likes Pergamon Porblem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Pergamon Porblem" Watch "Pergamon Porblem" New topic

Pergamon Porblem

Kevin Brown

Joined: Aug 08, 2008
Posts: 5

I am trying to get my crawler to pull off data from in this case a pdf file on a website.. But I get an exceptions and don't know what I am doing wrong..

Here is my code:

And this is the problem I get after build:

Exception in thread "pool-1-thread-1" java.lang.NoClassDefFoundError: org/pdfbox/pdfparser/PDFParser
at net.sourceforge.pergamon.parser.Parser.createPDFParser(Unknown Source)
at retrieverappsample2.Main$3.analyze(Main.java:124)
at net.sourceforge.retriever.URLParser.analyze(Unknown Source)
at net.sourceforge.retriever.URLParser.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
at java.lang.Thread.run(Thread.java:619)
INFO MESSAGE: Crawler stopped on Fri Aug 08 22:06:15 MDT 2008
Caused by: java.lang.ClassNotFoundException: org.pdfbox.pdfparser.PDFParser
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)

[edit]Add code tags. CR[/edit]
[ August 10, 2008: Message edited by: Campbell Ritchie ]
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 41101
Welcome to JavaRanch.

It looks like the PDFBox library is not in the classpath. How are you running the code? If it's from the command line, are you using the -classpath switch?

Ping & DNS - my free Android networking tools app
Kevin Brown

Joined: Aug 08, 2008
Posts: 5
thanks for reply

no using netbeans IDE I have loaded the jar file into the classpath but its still not finding the classes.. Not sure if I am setting this up right.
Kevin Brown

Joined: Aug 08, 2008
Posts: 5
ahh nevermind its an additional package..
Kevin Brown

Joined: Aug 08, 2008
Posts: 5
no tried adding the package its still screwy anyone know the right way to add packages into netbeans IDE??
Kevin Brown

Joined: Aug 08, 2008
Posts: 5
lol got it nevermind
Rob Spoor

Joined: Oct 27, 2005
Posts: 19651

Say Kevin, there's a button that looks like a piece of paper and a pencil.

If you press that, you can edit your messages. It beats 4 messages in a row.

Because of clarity, please don't edit posts that have already had replies, or people (including me ) can get confused.
[ August 09, 2008: Message edited by: Rob Prime ]

How To Ask Questions How To Answer Questions
wood burning stoves
subject: Pergamon Porblem
Similar Threads
Regarding jackrabbit versionable node creation
HFJ - RMI issues.
RMI: ClassNotFoundException for STUB class
Eclipse wont run my RMI program?
cant run java file from command line but works with .sh file??