forked from labos/locanda
-
Notifications
You must be signed in to change notification settings - Fork 0
/
struts.xml
65 lines (59 loc) · 2.95 KB
/
struts.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?xml version="1.0" encoding="UTF-8" ?>
<!-- /* * Licensed to the Apache Software Foundation (ASF) under one * or
more contributor license agreements. See the NOTICE file * distributed with
this work for additional information * regarding copyright ownership. The
ASF licenses this file * to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance * with the License.
You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0
* * Unless required by applicable law or agreed to in writing, * software
distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT
WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the
License for the * specific language governing permissions and limitations
* under the License. */ -->
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
"http://struts.apache.org/dtds/struts-2.0.dtd">
<struts>
<constant name="struts.i18n.encoding" value="UTF-8" />
<constant name="struts.custom.i18n.resources" value="global" />
<constant name="struts.multipart.maxSize" value="1000000" />
<constant name="struts.action.excludePattern" value="/rest/.*?" />
<package name="default" extends="struts-default,json-default" namespace="/">
<interceptors>
<interceptor name="userAwareInterceptor"
class="struts.interceptor.UserAwareInterceptor"></interceptor>
<interceptor-stack name="userAwareStack">
<interceptor-ref name="userAwareInterceptor"></interceptor-ref>
<interceptor-ref name="defaultStack"></interceptor-ref>
</interceptor-stack>
</interceptors>
<default-interceptor-ref name="userAwareStack"></default-interceptor-ref>
<default-action-ref name="home"></default-action-ref>
<global-results>
<result name="notLogged">/WEB-INF/jsp/homeNotLogged.jsp</result>
<result name="nullpointer" type="redirect">home.action</result>
</global-results>
<global-exception-mappings>
<exception-mapping exception="java.lang.NullPointerException"
result="nullpointer" />
</global-exception-mappings>
<action name="locale" class="action.LocaleAction">
<result name="SUCCESS" type="redirect">${redirect}</result>
</action>
<action name="download" class="action.DownloadAction">
<result name="success" type="stream">
<param name="contentType">application/octet-stream</param>
<param name="inputName">fileInputStream</param>
<param name="contentDisposition">attachment;filename="${fileName}"</param>
<param name="bufferSize">1024</param>
</result>
</action>
<action name="birt" class="action.BirtAction">
<result type="stream">
<param name="contentType">application/pdf</param>
<param name="inputName">inputStream</param>
<param name="contentDisposition">attachment;filename="${fileName}"</param>
</result>
</action>
</package>
</struts>