classpath

How to set class path for client of web service in build.xml

HI, I need to know how to set class path for the client tag under web service of build.xml in java. I have to add the log4j.properties file to the client jar. Thanks Abhi ...

How to resolve Maven exec plugin: classpath too long error?

I have a large Java project with a large number of jar file dependencies. When I try to run the project (using exec) from Eclipse or Netbeans, Maven throws an exception which turns out to be a too large number of entries on the classpath (only 2/3 of the needed entries are included). Does anyone know a workaround for this? (Except from...

Include multiple jars with classpathentry

I have an eclipse's .classpath file that looks like this: <?xml version="1.0" encoding="UTF-8"?> <classpath> <classpathentry kind="src" path="src"/> <classpathentry kind="src" path="test"/> <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> <classpathentry kind="output" path="bin"/> <classpat...

maven-jar-plugin and transitive dependencies

I'm using both the assembly and jar plugins to deploy my application. I'm also using the jar plugin to help me generate the classpath in the manifest file using <addClasspath>true</addClasspath> While that seems to work, the problem comes when I try executing the jar (it has a proper main class specified) - it will fail to locate a li...

Android Eclipse Classpath - want to add classpath container path but eclipse won't let me.

I'm using Eclipse to learn to develop Android applications in Java. I haven't used Eclipse before. The project I'm trying to use (supplied by OReilly as part of 'Android Application Development') is MJAndroid. When attempting to run the project, the Run fails, and the Problems tab mentions com.java.Object can't be found, and Eclipse ask...

Compile an ActionScript class that is in a package to a swf using Flex Builder 3

How do I configure an ActionScript Project in Flex Builder 3 Pro so that I can compile an ActionScript class that is part of a package into a swf. For example, the class that I want to compile to swf is: package utils { import flash.display.Sprite; public class Tool extends Sprite { public function Tool() { } } T...

Determine location of a java class loaded by Matlab

When using java from Matlab, is there some way to figure out from where in matlab's java class path is a class being loaded? I'm trying to diagnose a error caused by conflicting versions of the same class being used simultaneously. Specifically, the class I'm looking for is org.apache.lucene.store.FSDirectory. It seems to be used by one...

ClassNotFoundException with ant's java task and classpath

Hello, I am trying to compile and run a simple java class within eclipse. The compile task works fine, and since I do not specify a destination folder the build files are in the same directory as the source. Which is alright, at the moment all I need is to learn how I can run the class with the main() method. I have tried using the ful...

Eclipse classpath entries only used for tests

In Maven, you can have compile-time dependencies and test dependencies. This is a feature I love, and the M2Eclipse plugin makes this available in Eclipse, too, which is great. So if I add jmock.jar to my project as a test dependency, it will show up on the classpath for JUnit tests, but won't be present when I'm debugging the applicatio...

Java Classpath problem

I have a Java Program that references a Jar File. The Jar File is present in the same directory as the .class File but when I try to run the program from console, I get NoClassDefFound error :-( Alternatively it runs Ok from Eclipse. Why ? ...

Ant + JUnit: NoClassDefFoundError

Ok, I'm frustrated! I've hunted around for a good number of hours and am still stumped. Environment: WinXP, Eclipse Galileo 3.5 (straight install - no extra plugins). So, I have a simple JUnit test. It runs fine from it's internal Eclipse JUnit run configuration. This class has no dependencies on anything. To narrow this problem do...

With GNU classpath, is it possible to build a crossplatform (Win32 and Linux) jar

I thought that gnu classpath was just an open source version of the Java library. Apparently it is tied heavily to the host system? Is this true. For example, would it be possible to build a gnu classpath 'rt.jar' with only Java bytecode and what are the args to use that as the bootstrap library? ...

Using wildcard for classpath?

G'day everybody, I have been using so many 3rd party libraries(jar files) that my CLASSPATH is completely messed up as i have to include the path for every single jar file that i use. I've been wondering if there is a way to include all the jar files in a folder using wildcard(*) operator (like *.jar). But it seems to be...

Using external properties files in weblogic

I am working on deploying a J2ee application that I have previously been deploying in JBOSS into Weblogic 10.3.1.0. I am running into an issue with external properties files. In Jboss I can just put the properties files into $JBOSS_HOME/server/default/conf, and they are loaded onto the system classpath and I can access them without any...

java lucene class not found problem

I keep getting this error: java.lang.NoClassDefFoundError: org/apache/lucene/index/memory/MemoryIndex Is there any way i can go about making sure java/tomcat can find this class? ...

J2ME does not find my implementation of java.util.TreeMap

What I'm trying I'm trying to use java.util.TreeMap in a J2ME application. I know that TreeMap is present on J2SE but not on J2ME, so I've made some efforts to port the J2SE 6.0 TreeMap to J2ME 1.2 and included it in my Midlet Jar. This involved porting half of the collections framework, but now I'm (theoretically) done with that and wa...

What versions/flavors of WinZip can be opened by the gnu.java.util.zip.dll v.6.0.140.8?

Evaluating a third party data processing tool, I have bumped into a case where some WinZip files cause an exception: Caused by: gnu.java.util.zip.ZipException: Unknown compression method 98 at gnu.java.util.zip.ZipFile.getInputStream(ZipFile.java:470) I have seen this with files created with WinZip 11.2 and newer. What's the lat...

getClass().getClassLoader().getResourceAsStream is throwing a NullPointerException

In Java How could getClass().getClassLoader() return null? The jar the 'class' is located in is NOT located under common/lib. The jar is NOT being boostrap-loaded. The ClassLoader for all classes within the jar is null. ...

Weblogic EAR Classloading

I am deploying an EAR in a WebLogic node with many jars defined in the bootstrap (startWeblogicServer.bat) class-path. The problem is that my ear and the bootstrap contain different versions of the same jars, not only that but certain jars contain extracted third party libraries which also differ in version from the WebLogic bootstrap ...

JBoss: WAR file in EAR can't find JAR library on classpath

Hey Guys, I am having a problem deploying an ear with bundled wars, jars, and configuration files (.properties files) on JBoss 4.3-eap. Here is my ear structure: +app.ear +lib *.jar libraries that the war's use +classes *.properties and other configuration files +META-INF application.xml jbos-a...