views:

45

answers:

1

we have downloaded jar files for lambdaj and its dependencies which are again jar files. we do not know how to go about it. we have copied these files in the

C:\Program Files\Java\jre6\lib\ext

have set the class path in environment variales as:
variable: classpath
path: C:\Program Files\Java\jre6\lib\ext

but we do not know how to go further. we want to run some lambdaj programs. can anyone suggest how to run lambdaj programs?

+1  A: 

You would run a Java program that requires lambdaj in exactly the same way you'd run any other java program with an external dependency, i.e. by invoking the java executable passing in the fully-qualified name of the Main class, or the JAR with an appropriate manifest, or by deploying it in a servlet container, etc. Additionally you should be putting the LambdaJ JAR on the classpath for this invocation, not in the lib folder for your entire JVM.

What have you tried so far and why/how is it not working? Your question at the moment is a bit analogous to "I want to use Microsoft Word to view some Word documents, how do I do this?".

Update for comment 1: You said "it's not working". That doesn't help anyone address your problem as it gives no clue what you expected to happen and what you observed, only that they were different. As for where JAR files can be stored - you can put them in any directory, so long as that directory is on the classpath (or you add it to the classpath) of the Java application that runs. The canonical place to put external dependencies is in a folder called lib below the root of your project, but the important thing is that you choose somewhere consistent and sensible.

It sounds like you don't quite grok Java and classpaths yet. If you have followed some tutorials and are still stuck, ask for help to let you understand. Adding more detail to your question, including the layout of your files, the commands you issued, and the response that came back would be useful too.

Andrzej Doyle
actually we had just started using lambdaj and are not aware of how to go about jar files. we followed few steps mentioned over the net i.e. classpath setting. but still it is not working.when we import lambdaj package then i could not find that package. can u clearly tel us where are we supposed to store these jar files in order to run a simple program which has imported lambdaj package?
intern