aboutsummaryrefslogtreecommitdiff
path: root/pdf-as-web/src/main/webapp/WEB-INF
diff options
context:
space:
mode:
Diffstat (limited to 'pdf-as-web/src/main/webapp/WEB-INF')
-rw-r--r--pdf-as-web/src/main/webapp/WEB-INF/decorators.xml13
-rw-r--r--pdf-as-web/src/main/webapp/WEB-INF/decorators/default_layout.jsp41
-rw-r--r--pdf-as-web/src/main/webapp/WEB-INF/sitemesh.xml16
-rw-r--r--pdf-as-web/src/main/webapp/WEB-INF/web.xml74
4 files changed, 120 insertions, 24 deletions
diff --git a/pdf-as-web/src/main/webapp/WEB-INF/decorators.xml b/pdf-as-web/src/main/webapp/WEB-INF/decorators.xml
new file mode 100644
index 00000000..6a6ed0a0
--- /dev/null
+++ b/pdf-as-web/src/main/webapp/WEB-INF/decorators.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<decorators defaultdir="/WEB-INF/decorators">
+ <excludes>
+ <pattern>/assets/*</pattern>
+ </excludes>
+
+ <decorator name="layout" page="default_layout.jsp">
+ <pattern>/*</pattern>
+ <pattern>/Sign</pattern>
+ <pattern>/ProvidePDF</pattern>
+ <pattern>/ErrorPage</pattern>
+ </decorator>
+</decorators> \ No newline at end of file
diff --git a/pdf-as-web/src/main/webapp/WEB-INF/decorators/default_layout.jsp b/pdf-as-web/src/main/webapp/WEB-INF/decorators/default_layout.jsp
new file mode 100644
index 00000000..1179d48c
--- /dev/null
+++ b/pdf-as-web/src/main/webapp/WEB-INF/decorators/default_layout.jsp
@@ -0,0 +1,41 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<%@ taglib uri="http://www.opensymphony.com/sitemesh/decorator"
+ prefix="decorator"%>
+<%@page contentType="text/html; charset=UTF-8"%>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
+<head>
+ <meta charset="utf-8"/>
+ <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
+ <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
+ <meta name="description" content="PDF-Signatur"/>
+ <meta name="author" content="EGIZ"/>
+ <link rel="shortcut icon" href="assets/ico/favicon.png"/>
+
+ <title><decorator:title></decorator:title></title>
+ <link href="assets/css/bootstrap.css" rel="stylesheet"/>
+
+ <link href="assets/css/pdfas.css" rel="stylesheet"/>
+ <decorator:head></decorator:head>
+</head>
+
+<body>
+ <div class="container">
+ <div class="header">
+ <h3 class="text-muted">PDF-Signatur</h3>
+ </div>
+
+ <div class="row marketing">
+ <div class="col-lg-12">
+ <decorator:body></decorator:body>
+ </div>
+ </div>
+
+ <div class="footer">
+ <p>&copy; EGIZ 2014</p>
+ </div>
+
+ </div>
+ <!-- /container -->
+</body>
+</html> \ No newline at end of file
diff --git a/pdf-as-web/src/main/webapp/WEB-INF/sitemesh.xml b/pdf-as-web/src/main/webapp/WEB-INF/sitemesh.xml
new file mode 100644
index 00000000..d8dfb3c9
--- /dev/null
+++ b/pdf-as-web/src/main/webapp/WEB-INF/sitemesh.xml
@@ -0,0 +1,16 @@
+<sitemesh>
+ <property name="decorators-file" value="/WEB-INF/decorators.xml" />
+ <excludes file="${decorators-file}" />
+
+ <page-parsers>
+ <parser content-type="text/html"
+ class="com.opensymphony.module.sitemesh.parser.FastPageParser" />
+ </page-parsers>
+
+ <decorator-mappers>
+ <mapper
+ class="com.opensymphony.module.sitemesh.mapper.ConfigDecoratorMapper">
+ <param name="config" value="${decorators-file}" />
+ </mapper>
+ </decorator-mappers>
+</sitemesh> \ No newline at end of file
diff --git a/pdf-as-web/src/main/webapp/WEB-INF/web.xml b/pdf-as-web/src/main/webapp/WEB-INF/web.xml
index 44298afe..81fa6dad 100644
--- a/pdf-as-web/src/main/webapp/WEB-INF/web.xml
+++ b/pdf-as-web/src/main/webapp/WEB-INF/web.xml
@@ -9,36 +9,32 @@
<description>
PDF-AS-WEB Application
</description>
+ <filter>
+ <filter-name>ExceptionCatchFilter</filter-name>
+ <display-name>ExceptionCatchFilter</display-name>
+ <description></description>
+ <filter-class>at.gv.egiz.pdfas.web.filter.ExceptionCatchFilter</filter-class>
+ </filter>
+ <filter>
+ <filter-name>sitemesh</filter-name>
+ <filter-class>com.opensymphony.sitemesh.webapp.SiteMeshFilter</filter-class>
+ </filter>
-
- <!-- Context initialization parameters that define shared String constants
- used within your application, which can be customized by the system administrator
- who is installing your application. The values actually assigned to these
- parameters can be retrieved in a servlet or JSP page by calling: String value
- = getServletContext().getInitParameter("name"); where "name" matches the
- <param-name> element of one of these initialization parameters. You can define
- any number of context initialization parameters, including zero. <context-param>
- <param-name>webmaster</param-name> <param-value>myaddress@mycompany.com</param-value>
- <description> The EMAIL address of the administrator to whom questions and
- comments about this application should be addressed. </description> </context-param> -->
-
- <!-- Servlet definitions for the servlets that make up your web application,
- including initialization parameters. With Tomcat, you can also send requests
- to servlets not listed here with a request like this: http://localhost:8080/{context-path}/servlet/{classname}
- but this usage is not guaranteed to be portable. It also makes relative references
- to images and other resources required by your servlet more complicated,
- so defining all of your servlets (and defining a mapping to them with a servlet-mapping
- element) is recommended. Servlet initialization parameters can be retrieved
- in a servlet or JSP page by calling: String value = getServletConfig().getInitParameter("name");
- where "name" matches the <param-name> element of one of these initialization
- parameters. You can define any number of servlets, including zero. -->
+ <filter-mapping>
+ <filter-name>sitemesh</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
+ <filter-mapping>
+ <filter-name>ExceptionCatchFilter</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
<servlet>
<servlet-name>SignServlet</servlet-name>
<description>
The Sign Servlet allows Users to Sign PDF Documents ...
</description>
- <servlet-class>at.gv.egiz.pdfas.web.servlets.SignServlet</servlet-class>
+ <servlet-class>at.gv.egiz.pdfas.web.servlets.ExternSignServlet</servlet-class>
<load-on-startup>5</load-on-startup>
</servlet>
<servlet>
@@ -59,6 +55,24 @@
<description></description>
<servlet-class>at.gv.egiz.pdfas.web.servlets.VerifyServlet</servlet-class>
</servlet>
+ <servlet>
+ <servlet-name>PDFData</servlet-name>
+ <display-name>PDFData</display-name>
+ <description></description>
+ <servlet-class>at.gv.egiz.pdfas.web.servlets.PDFData</servlet-class>
+ </servlet>
+ <servlet>
+ <servlet-name>ErrorPage</servlet-name>
+ <display-name>ErrorPage</display-name>
+ <description></description>
+ <servlet-class>at.gv.egiz.pdfas.web.servlets.ErrorPage</servlet-class>
+ </servlet>
+ <servlet>
+ <servlet-name>TestServlet</servlet-name>
+ <display-name>TestServlet</display-name>
+ <description></description>
+ <servlet-class>at.gv.egiz.pdfas.web.servlets.TestServlet</servlet-class>
+ </servlet>
<!-- Define mappings that are used by the servlet container to translate
a particular request URI (context-relative) to a particular servlet. The
@@ -85,6 +99,18 @@
<servlet-name>VerifyServlet</servlet-name>
<url-pattern>/VerifyServlet</url-pattern>
</servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>PDFData</servlet-name>
+ <url-pattern>/PDFData</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>ErrorPage</servlet-name>
+ <url-pattern>/ErrorPage</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>TestServlet</servlet-name>
+ <url-pattern>/TestServlet</url-pattern>
+ </servlet-mapping>
<!-- Define the default session timeout for your application, in minutes.
From a servlet or JSP page, you can modify the timeout for a particular session
@@ -95,7 +121,7 @@
</session-config>
<welcome-file-list>
- <welcome-file>signstart.jsp</welcome-file>
+ <welcome-file>index.jsp</welcome-file>
</welcome-file-list>
</web-app> \ No newline at end of file