Search code examples
kmllibrariesjak

Adding KML Library JAK


How do I add a the JAK Library to my java project so I can use it? I Dont understand how to I acctually make it useable in my Java Porject if it is on Gittub and I dont see the Jar Files.

Can Anyone please help me with a little guidance? I've checked online and 0 videos about it so All I can ask is help from you guys.


Solution

  • Adding jar dependencies to a Java project depends on what build tools are used (e.g. Maven, Gradle, Ant, etc.). If you're using an IDE, the project can be created around the build artifact (pom.xml for Maven projects, build.gradle for Gradle, etc.) or explicitly add jar files to the CLASSPATH for that project.

    If you have a Maven project, add this dependency to your pom.xml file:

    <dependency>
        <groupId>de.micromata.jak</groupId>
        <artifactId>JavaAPIforKml</artifactId>
        <version>2.2.1</version>
    </dependency>
    

    For Gradle project, add this to your build.gradle file:

    dependencies {  
      compile group: 'de.micromata.jak', name: 'JavaAPIforKml', version: '2.2.1'
      //...
    }
    

    Alternatively, you can manually download the jars from the official dev.java.net Maven 2 repository. Note that JAK depends on JAXB libraries so you will need them also. Review the POM for JAK for details.