0

We have an existing JavaEE web application. We need to connect to a document repository via webdav. I am trying to use sardine but the couldn't find clear setup instructions. Is the Maven build mandatory? Or, is it possible to simply include sardine.jar in our application and use the below code?

Sardine sardine = SardineFactory.begin("username", "password");
List<DavResource> resources = sardine.list("http://myhost.com/modeshape-webdav/sample/default");
for (DavResource res : resources)
{
  System.out.println(res);
}
Spartan
  • 1,167
  • 4
  • 20
  • 40
user1549605
  • 273
  • 3
  • 17
  • Maven will bring you all needed dependencies, because the Sardine library can depend on other libs, and they can depend on another libs, and so on. But you can choose to solve this dependencies on you own, and in such case you don't need Maven. – Jozef Chocholacek Sep 24 '15 at 06:32
  • thanks, I added sardine library and had to resolve multiple jar dependency issues – user1549605 Oct 08 '15 at 16:25

1 Answers1

0

If you use Maven, you can add this dependency in your pom.xml to use Sardine :

<dependency>
  <groupId>com.github.lookfirst</groupId>
  <artifactId>sardine</artifactId>
  <version>5.5</version>
</dependency>
Pinpin
  • 16
  • 1