Questions for jar


2713

How to see which JVM an executable Jar is using?

The project uses a dll which has to be copied to JVM_HOME/bin directory. From the IDE the application works fine (the dll is copied in JAVA_HOME/jre/bin) but when I try to run the application direc...
4140

How can I move the files on unix with java?

I write java in netbeans.I want to move files and create files.When I run the program on netbeans it works. Files creates and moved. But when I run program on the jar it doesnot copy or move. I give
3922

Jnlp-Prevent downloading of the jars that i referenced

I have been developed a jnlp file, and it is working properly when client downloads it from his/her browser. No problem up to here, but client can also access to the jar files that my jnlp is
607

Security considerations when hosting signed jars

What are the security implications for hosting signed jars on the internet?
6237

How to set java flags when launching a jar from the OS X GUI?

I want the flag "-Xmx1g" to be set when i click on a particular jar file in OS X.
9626

ClassNotFoundException / NoClassDefFoundError when running a Scala jar

Having a Scala project exported to a .jar with eclipse, the application started with java -jar app.jar dies with the error java.lang.ClassNotFoundException: scala.Predef$.
169

Composite component in JAR issue with cc.attrs

For my composite component which is packaged in JAR I've used a <cc:interface> with a simple <cc:attribute> and, of course a <cc:implementation>.
8957

Find for a class file in Linux that is present in JAR

I am trying to find a JAR file which contains my class using below command given in this link : Find a jar file given the class name?
662

Confusion defining the Main-Class in ant for bundling a jar

I'm trying to construct a jar file using the Amazon Mechanical Turk API. The SDK comes with a helloworld file that I'm trying to jar up as a sanity check - it is located here:
2323

ClassNotFoundException problems with manifest in created JAR

I'm trying to create a JAR file from my sources, but when I run it I get class not found exception - it can't find the main class, even though I defined it in the MANIFEST.MF file. Can you spot any
1643

Running a batch file that's inside of a jar file

I'm attempting to call a batch file which is packaged inside of a jar file from the jar file itself. I'm not altogether sure this is possible, but I figured if anyone knew how it would be someone on
4352

Share an Interface

I am writing a Java application that will load third party "drivers". I intend to develop an interface that will define the required methods that the "driver" must implement in order to work within...
1244

Eclipse: Attach source/javadoc to a library via a local property

I have a third-party library in my SVN repository and I'd like to associate source/javadoc with it locally in Eclipse. I.e., there should be some local setting (for example, an entry in the
4780

Creating one jar file that for execution from Java/Clojure

I'd like to create one jar file to execute that is implemented with java and clojure. This is the step that I took.
3240

How to build a jar using an own MANIFEST.MF in Eclipse

I have a custom MANIFEST.MF in my java-project in Eclipse.
6671

compiling an Eclipse project into a jar

I reference another eclipse project from the current project I am working on.
8859

Where to put the external jars?

I use Eclipse (3.4) and my class compiles without warning or errors.
4931

Problem running a Jar file

I've compiled a java project into a Jar file, and am having issues running it.
4209

How I find my running jar file path on unix?

I have a.jar file. I want to its path where ever it is when it running.
6503

Analyze JAR dependencies in a Java project

I'm looking for a tool that will show me a graph of JAR dependencies in my Java project based on static analysis of the compiled byte code. Specifically, I'm trying to figure out if there are unuse...
9652

Unable to access xsl file from jar file (Mule)

I have been facing trouble accessing an xsl file located inside a folder in jar file. I need to get this working in mule-config file.
9849

compiling nested jars using ant

I have a Java project,Parent, which depends on a Child sub-project (in the form of a JAR). This Child depends on library A and B and those get bundled in with Child. Parent uses Aand B as well (m...
2678

Insert a dependent jar into an installer jar

I have a multi-module maven project with an installer sub-project. The installer will be distributed as an executable JAR. It will setup the DB and extract the WAR file to the app server. I would l...
8673

JOGL 2.0 doesn't support GLCanvas ,Texture ,Animator , but jogl 1.0 does?

I downloaded jogl 2.0 from here , the file jogl-all.jar , and ran a simple code example taken from here :
9845

Multiple jars in classpath not working

I have seen several very similar questions on stackoverflow, but haven't come across anything that exactly matches my problem. I have a folder with several .java files, and another folder with two ...
7626

How to share jar within multiple portlets?

I'm using several jars in my portlets, for instance c3p0. Now I want to avoid to put the jars in every of my portlets lib folders. How can I share one jar file within multiple portlets? And how sho...
3111

Android - How to add system service with java library?

I need your help. Is it possible to add a system service that uses a java library (.jar file)?
9071

How to get the path of a running JAR file?

My code runs inside a JAR file, say foo.jar, and I need to know, in the code, in which folder the running foo.jar is.
6483

hide some class file or package in jar file

How can I export a jar without some class or package which I don't want others to use,but which is needed in project,means I can't delete them.
1686

Class-Path in jar file with combined libraries

I am trying to create a jar file that is "self contained" concerning the libraries it needs.
4838

How to share configuration files across modules in Maven

I am working on a java maven project with several modules.
3384

Android Library Project - Resources$NotFoundException

I'm trying to create a library project to use it for a Unity3d Plugin. All is correct but when i'm trying to show a custom progressDialog for example i'm doing this, getting Resources$NotFoundExcep...
3258

How do I include jars in a groovy script?

I have a groovy script that needs a library in a jar. How do I add that to the classpath? I want the script to be executable so I'm using #!/usr/bin/env groovy at the top of my script.
4332

Error when creating an executable test-jar in Maven

I'm trying to create a JAR that I can put on a non development machine and run some unit tests that exercise a web service. I've read that there are many ways to do this in maven. I'm focusing on...
5274

Is it possible to auto create directory hierarchy in .jar file?

I'm rarely using java, so my knowledge of modern ecosystem is very limited :(. AFAIK, Java is heavy glued with directory hierarchy and file names: for example, if i have a .jar file with
1693

Reference jars inside a jar

I have a jar whose content looks as shown below,
1349

JavaFx jar file does not open corrent with double click (Mac)

I have quite big problem, which drives me crazy. Not sure what is the best way to describe my problem, so I am just going to write what I do and what happens:
5781
6545

Eclipse error: “The import XXX cannot be resolved”

I'm trying to work with Hibernate in Eclipse.
5654

scala :How to read file in jar

I have directory structure like this
5836

How to package libraries into my jar using Ant

My application relies on two external libraries, I have both in jar format and have added them to my classpath, making it possible to run my application within NetBeans.
429

ClassNotFoundException: com.mysql.jdbc.Driver. JDBC MySQL driver for web application

So I have a .jar file for the MySQL JDBC driver, it is under my libraries source folder and I have the following code:
2447

How to prevent jar decompilation

I have created a plugin project in Eclipse, distributed as a jar.
5456

Installing JavaMail 1.4.7 on Linux Ubuntu 12.04 LTS

I want to install JavaMail to establish an SMTP connection between two clients (and if you know other ways of establishing that connection, please let me know). I'm using Eclipse IDE to run the pro...
739

How to create a .jar file using the terminal

I'm trying to create a .jar file using the mac terminal but am having bit of trouble. I followed the steps here but was unsuccessful. I got this error message:
3657

Debugging a library I wrote (deployed as JAR file) that is used by 3rd party client

I am using an application that allows me to insert business logic via a JavaBean, in the form of a JAR file. The problem is, I want to be able to set breakpoints in my code, to troubleshoot it. B...
2700

Java difference between running from netbeans and cmd

I have a program that writes text data to files. When I run it from netbeans the files are in a correct encoding and you can read them with a notepad. When I run it from cmd using java -cp ....jar ...
8297

Android app including android lib including jar

I have following projects configuration under eclipse :
7011

Building jar with dependencies maven

I can't find a comprehencive guide to how maven building actually works. And trying to follow the advice I find at stackoverflow I wound up with a monster sized maven build branch that still doesn't
1334

What happens when two Java frameworks need third one but each of the two need different version of third one?

In my Java project I'm using two different frameworks (let's say A.jar and B.jar) and both of them require one common framework (let's say Log4j.jar) but in two different versions. How it is treate...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.