0

This is the third time I've installed it. I had it working on Windows, and up until a few days ago on Linux. I've done all I can do and I don't understand how to run this Java program.

The source code is a folder with a lib, src some jars and a classpath and project file. The classpath file makes some declarations like classpathentry=src/main and path=lib, path=src.

All of these make sense. There is a folder 'main' inside 'src'.

The tiny file I'm trying to run starts off by

import de.l3s.boilerpipe.demo

I'm trying to run 'Oneliner.java'. I cannot compile it.

No matter what/where that class file is, I cannot run it. It results in a noclassdeffound. I've run it in the main, the src, the root, the demo, the ... anywhere. I've tried compiling it in different directories, running it with various java command line switches that were recommended. Supposedly you can have it 'search' for the file, which I've yet to experience. The sheer stubbornness of this java environment is terrifying. And massively humiliating for me.

hippietrail
  • 15,848
  • 18
  • 99
  • 158
user723220
  • 817
  • 3
  • 12
  • 20
  • If you do a jar -tf on the jars and grep for the classname is it there? And is "demo" the name of a class, or package? Need details. – Dave Newton Oct 31 '11 at 03:30
  • Ok I did that. All of the jars return locations where I expected, in the main folder. Either de. or Org. – user723220 Oct 31 '11 at 04:34
  • But sadly ( and I mean sadly), I always receive this message: wrong name de.l3s.boilerpipe.demo.Oneliner I've tried compiling, copying, running from, the 'de' folder, the folder below it, the folder above it, anywhere, everywhere. this is madness. this is true absolute total madness. each time I type "java Oneliner" and see the same message, I laugh in an increasingly terrifying manner. – user723220 Oct 31 '11 at 04:37
  • i just don't understand. i don't understand. this is the worst psychological pain i've been through in some time. mainly because I had this working, and do not know why it stopped. i wish I could just understand what de.l3s.boilerpipe.demo.Oneliner not being found means. I've wasted my entire weekend typing 'java Oneliner" over and over. – user723220 Oct 31 '11 at 04:45
  • demo is the name of a package. I wish somebody could just explain to me one thing. When I compile a java program, does it matter where. secondly, when I run it, why can't I run it from any place? and if not, then where can I run it. where can I compile and run. this Oneliner.java. based on the existence of this de.l3s.boilerpipe.demo and the three JAR files. Where can I put those JAR files so I don't have to go through this? – user723220 Oct 31 '11 at 04:49
  • http://download.oracle.com/javase/tutorial/java/package/managingfiles.html – Dave Newton Oct 31 '11 at 14:15

2 Answers2

6

I had the same problem with installing it. The 'Getting Started' page is poor quality.

My solution was to use a python wrapper, which you can find here: https://github.com/misja/python-boilerpipe

It takes care of all of the dependencies you'll need (however, you might be missing jpype if you're on a Mac. In that case, you'll need to install it manually from: http://jpype.sourceforge.net/).

Vikdor
  • 23,934
  • 10
  • 61
  • 84
wle8300.com
  • 2,588
  • 1
  • 23
  • 29
1

The best way to start using the boilerpipe algorithm (and to see what it is for) is to use the demo site: http://boilerpipe-web.appspot.com/

If you want to integrate the boilerpipe library into your applications, or even intent to modify/improve the code, you will definitely need solid Java programming skills.

As a quick-start I suggest that you install a recent version of the Eclipse IDE for Java Developers and import boilerpipe-core as a project. This avoids pretty much of the classpath configuration, and almost everything should be set up correctly for you.

The classpath file you mentioned is probably ".classpath", which is part of the Eclipse project configuration. You don't need it unless you want an Eclipse project.

Christian Kohlschütter
  • 3,032
  • 1
  • 18
  • 13
  • Thank you Mr. Kohlschutte. I would like to learn Java, but life is not long enough. I will try these instructions. I am designing a wordpress page which imports news articles using Boilerpipe and then transforms the text into 'logic' using lexicographical libraries, word lists, parts-of-speech to determine if the news article is 'biased', and then produces a strictly informative version of the same article. It's purely for my own amusement. Thanks for chiming in, and good luck with further development of this project, which will be part of the foundation of the semantic web. – user723220 Nov 05 '11 at 22:06
  • And please excuse my mental state, I am a musician, CG artist and web developer from NYC who does pay too much rent and does not nearly have enough fun – user723220 Nov 05 '11 at 22:08