Configuring Maven project
This page describes how to add JxBrowser to a Maven-based project.
Repository
In order to obtain JxBrowser JAR files using Maven you need to add the following code to the repositories
section of your pom.xml
file:
<repository>
<id>com.teamdev</id>
<url>https://europe-maven.pkg.dev/jxbrowser/eaps</url>
</repository>
The link to the https://europe-maven.pkg.dev/jxbrowser/eaps
Maven repository is not accessible in a web browser as it’s hosted on Google Cloud’s Artifact Registry.
The Maven repository for releases is available in US region at https://us-maven.pkg.dev/jxbrowser/eaps
.
Dependencies
Cross-platform
If your project runs on Windows, macOS, and Linux, please add the following code to the dependencies
section of your pom.xml
file:
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-cross-platform</artifactId>
<version>8.0.0</version>
<type>pom</type>
</dependency>
Platform-specific
If you need JxBrowser JAR files only for a specific platform, you can use the appropriate dependency as described below.
If your Java application runs only on Windows and macOS platforms, and you do not need Linux dependency, you can include only Windows and macOS dependencies.
Windows 32-bit
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-win32</artifactId>
<version>8.0.0</version>
</dependency>
Windows 64-bit
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-win64</artifactId>
<version>8.0.0</version>
</dependency>
Windows 64-bit ARM
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-win64-arm</artifactId>
<version>8.0.0</version>
</dependency>
macOS 64-bit
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-mac</artifactId>
<version>8.0.0</version>
</dependency>
macOS 64-bit ARM
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-mac-arm</artifactId>
<version>8.0.0</version>
</dependency>
Linux 64-bit
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-linux64</artifactId>
<version>8.0.0</version>
</dependency>
Linux 64-bit ARM
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-linux64-arm</artifactId>
<version>8.0.0</version>
</dependency>
GUI toolkit
If you want to display web content in your Java Swing/JavaFX GUI application, then you need to include one of the following dependencies as well:
Swing
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-swing</artifactId>
<version>8.0.0</version>
</dependency>
JavaFX
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-javafx</artifactId>
<version>8.0.0</version>
</dependency>
SWT
<dependency>
<groupId>com.teamdev.jxbrowser</groupId>
<artifactId>jxbrowser-swt</artifactId>
<version>8.0.0</version>
</dependency>