0.13.3 10-Apr-2014

ReXSL core module

There are two classes that you should use in your project (both of them are always mandatory): RestfulServlet and XsltFilter. Use them in WEB-INF/web.xml:

<filter>
  <filter-name>XsltFilter</filter-name>
  <filter-class>com.rexsl.core.XsltFilter</filter-class>
</filter>
<filter-mapping>
  <filter-name>XsltFilter</filter-name>
  <servlet-name>RestfulServlet</servlet-name>
  <dispatcher>REQUEST</dispatcher>
  <dispatcher>ERROR</dispatcher>
</filter-mapping>
<servlet>
  <servlet-name>RestfulServlet</servlet-name>
  <servlet-class>com.rexsl.core.RestfulServlet</servlet-class>
  <init-param>
    <param-name>com.rexsl.PACKAGES</param-name>
    <param-value>com.example.foo</param-value>
  </init-param>
</servlet>
<servlet-mapping>
  <servlet-name>RestfulServlet</servlet-name>
  <url-pattern>/*</url-pattern>
</servlet-mapping>

RestfulServlet is responsible for handling of JAX-RS requests and converting your JAXB annotated classes into XML documents.

XsltFilter is converting XML output documents into XHTML when necessary.

This dependency you add to pom.xml (or download rexsl-core-0.13.3.jar and add it to classpath):

<dependency>
  <groupId>com.rexsl</groupId>
  <artifactId>rexsl-core</artifactId>
  <version>0.13.3</version>
</dependency>

Also take a look at rexsl-page, which helps to build RESTful XML pages.

Stylesheet annotation enables re-configuration of XSL stylesheet name for a JAXB-annotated object.

Schema annotation lets you set the name of XML Schema of a JAXB-annotated object.

ExceptionTrap servlet helps you to catch all uncaught exceptions and manage them gracefully, showing some information to your end-users.

built by maven