Prev |  |

## Chapter 33. Dependencies

## 33.1. Project Dependencies

This section both lists the compile-time and runtime dependencies for Seam. Where the type is listed as `ear`, the library should be included in the /lib directory of your application's ear file. Where the type is listed as `war`, the library should be placed in the `/WEB-INF/lib` directory of your application's war file. The scope of the dependency is either all, runtime or provided (by JBoss AS 4.2).

Up to date version information and complete dependency information is not included in the docs, but is provided in the `/dependency-report.txt` which is generated from the Maven POMs stored in `/build`. You can generate this file by running `ant dependencyReport`.

### 33.1.1. Core

Table 33.1.

Name | Scope | Type | Notes
--- | --- | --- | ---
`jboss-seam.jar` | all | ear | The core Seam library, always required.
`jboss-seam-debug.jar` | runtime | war | Include during development when enabling Seam's debug feature
`jboss-seam-ioc.jar` | runtime | war | Required when using Seam with Spring
`jboss-seam-pdf.jar` | runtime | war | Required when using Seam's PDF features
`jboss-seam-remoting.jar` | runtime | war | Required when using Seam Remoting
`jboss-seam-ui.jar` | runtime | war | Required to use the Seam JSF controls
`jsf-api.jar` | provided |  | JSF API
`jsf-impl.jar` | provided |  | JSF Reference Implementation
`jsf-facelets.jar` | runtime | war | Facelets
`urlrewrite.jar` | runtime | war | URL Rewrite library
`quartz.jar` | runtime | ear | Required when you wish to use Quartz with Seam's asynchronous features

### 33.1.2. RichFaces

Table 33.2. RichFaces dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`richfaces-api.jar` | all | ear | Required to use RichFaces. Provides API classes that you may wish to use from your application e.g. to create a tree
`richfaces-impl.jar` | runtime | war | Required to use RichFaces.
`richfaces-ui.jar` | runtime | war | Required to use RichFaces. Provides all the UI components.

### 33.1.3. Seam Mail

Table 33.3. Seam Mail Dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`activation.jar` | runtime | ear | Required for attachment support
`mail.jar` | runtime | ear | Required for outgoing mail support
`mail-ra.jar` | compile only |  | Required for incoming mail support mail-ra.rar should be deployed to the application server at runtime
`jboss-seam-mail.jar` | runtime | war | Seam Mail

### 33.1.4. Seam PDF

Table 33.4. Seam PDF Dependencies

Name | Type | Scope | Notes
--- | --- | --- | ---
`itext.jar` | runtime | war | PDF Library
`jfreechart.jar` | runtime | war | Charting library
`jcommon.jar` | runtime | war | Required by JFreeChart
`jboss-seam-pdf.jar` | runtime | war | Seam PDF core library

### 33.1.5. JBoss Rules

The JBoss Rules libraries can be found in the `drools/lib` directory in Seam.

Table 33.5. JBoss Rules Dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`antlr-runtime.jar` | runtime | ear | ANTLR Runtime Library
`core.jar` | runtime | ear | Eclipse JDT
`drools-compiler.jar` | runtime | ear |
`drools-core.jar` | runtime | ear |
`janino.jar` | runtime | ear |
`mvel.jar` | runtime | ear |

### 33.1.6. JBPM

Table 33.6. JBPM dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`jbpm-jpdl.jar` | runtime | ear |

### 33.1.7. GWT

These libraries are required if you with to use the Google Web Toolkit (GWT) with your Seam application.

## Technology preview

GWT in Seam is marked as technology preview, so standard support is not guaranteed.

Table 33.7. GWT dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`gwt-servlet.jar` | runtime | war | The GWT Servlet libs

### 33.1.8. Spring

These libraries are required if you with to use the Spring Framework with your Seam application.

## Technology preview

Spring integration in Seam is marked as technology preview, so standard support is not guaranteed.

Table 33.8. Spring Framework dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`spring.jar` | runtime | ear | The Spring Framework library

### 33.1.9. Groovy

These libraries are required if you with to use Groovy with your Seam application.

## Technology preview

Groovy integration in Seam is marked as technology preview, so standard support is not guaranteed.

Table 33.9. Groovy dependencies

Name | Scope | Type | Notes
--- | --- | --- | ---
`groovy-all.jar` | runtime | ear | The Groovy libs

## 33.2. Dependency Management using Maven

Maven offers support for transitive dependency management and can be used to manage the dependencies of your Seam project. You can use Maven Ant Tasks to integrate Maven into your Ant build, or can use Maven to build and deploy your project.

We aren't actually going to discuss how to use Maven here, but just run over some basic POMs you could use.

Released versions of Seam are available in http://repository.jboss.org/maven2 and nightly snapshots are available in http://snapshots.jboss.org/maven2.

All the Seam artifacts are available in Maven:

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam</artifactId>

    </dependency>

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam-ui</artifactId>

    </dependency>

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam-pdf</artifactId>

    </dependency>

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam-remoting</artifactId>

    </dependency>

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam-ioc</artifactId>

    </dependency>

    <dependency>

      <groupId>org.jboss.seam</groupId>

      <artifactId>jboss-seam-ioc</artifactId>

    </dependency>

This sample POM will give you Seam, JPA (provided by Hibernate) and Hibernate Validator:

    <?xml version="1.0" encoding="UTF-8"?>

    <project xmlns="http://maven.apache.org/POM/4.0.0"

      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

      <modelVersion>4.0.0</modelVersion>

      <groupId>org.jboss.seam.example/groupId>

      <artifactId>my-project</artifactId>

      <version>1.0</version>

      <name>My Seam Project</name>

      <packaging>jar</packaging>

      <repositories>

        <repository>

          <id>repository.jboss.org</id>

          <name>JBoss Repository</name>

          <url>http://repository.jboss.org/maven2</url>

        </repository>

      </repositories>

      <dependencies>

        <dependency>

          <groupId>org.hibernate</groupId>

          <artifactId>hibernate-validator</artifactId>

          <version>3.0.0.GA</version>

        </dependency>

        <dependency>

          <groupId>org.hibernate</groupId>

          <artifactId>hibernate-annotations</artifactId>

          <version>3.3.0.ga</version>

        </dependency>

        <dependency>

          <groupId>org.hibernate</groupId>

          <artifactId>hibernate-entitymanager</artifactId>

          <version>3.3.1.ga</version>

        </dependency>

        <dependency>

          <groupId>org.jboss.seam</groupId>

          <artifactId>jboss-seam</artifactId>

          <version>2.0.0.GA</version>

        </dependency>

      </dependencies>

    </project>

Prev |  | Front page |