I got it to work. In order to add and use the package I did that:
-
Add the package to dependencies:
<dependency>
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-client</artifactId>
<version>1.8</version>
</dependency>
-
Add the package with an preceded exclamation mark to Import-Package:
<Import-Package> com.ur.urcap.api*;version="[1.1.0,2.0.0)", !com.sun.jersey.api.*, *</Import-Package>
-
Add the ArtifactId to Embed-Dependency:
<Embed-Dependency>jersey-client</Embed-Dependency>
I did not manually add any jars to my resource folder or so. After a successful building I got an error while starting polyscope, that an additional package com.sun.jersey.core
is missing. Apparently the jersey-client package has additional dependencies which need to be included as well. So I had to add jersey-core
and javax.mail
to dependencies
and also to Embed-Dependency
and then it worked. The required jar files got added automatically to the urcap file.
I hope this helps a bit