이 콘텐츠는 선택한 언어로 제공되지 않습니다.

Chapter 1. Seam Tutorial


1.1. Using the Seam examples

Seam provides a number of example applications which demonstrate how to use a variety of Seam's features. This tutorial will guide you through a few of those examples to help you get started learning Seam. The Seam examples are located in the examples subdirectory of the Seam distribution. The first example, on registration, is in the examples/registration directory.
Each example has the same directory structure:
  • The view directory contains view-related files such as web page templates, images and stylesheets.
  • The resources directory contains deployment descriptors and other configuration files.
  • The src directory contains the application source code.
Note that all examples are built and run from the Ant build.xml, so you will need a recent version of Ant installed before you get started.

1.1.1. Running the examples on JBoss Enterprise Application Platform

The examples are configured for use on JBoss Enterprise Application Platform. You will need to set jboss.home, in the shared build.properties file (in the root folder of your Seam installation) to the location of your JBoss Enterprise Application Platform installation.
Once you have set the location of JBoss Enterprise Application Platform and started the application server, you can build and deploy any example by typing ant explode in that example's directory. Any example that is packaged as an EAR (Enterprise Archive) deploys to a URL like /seam-example, where example is the name of the example folder, with one exception: if the example folder begins with "seam", the prefix "seam" is omitted. For instance, if JBoss Enterprise Application Platform is running on port 8080, the URL for the Registration example is http://localhost:8080/seam-registration/, whereas the URL for the SeamSpace example is http://localhost:8080/seam-space/.
If, on the other hand, the example is packaged as a WAR, then it deploys to a URL like /jboss-seam-example.

Note

Several of the examples — groovybooking, hibernate, jpa, and spring — can only be deployed as a WAR.

1.1.2. Running the example tests

Most of the examples come with a suite of TestNG integration tests. The easiest way to run the tests is to run ant test.
It is also possible to run the tests inside your IDE using the TestNG plug-in. This requires you to run ant test before running or debugging Seam test cases in JBoss Developer Studio. Consult the readme.txt in the examples directory of the Seam distribution for more information.
맨 위로 이동
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

Theme

© 2025 Red Hat