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

<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
    version="2.4">

<!-- listener setting -->

  <listener>
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  </listener>

  <context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>/WEB-INF/applicationContext.xml</param-value>
  </context-param>

  <listener>
    <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
  </listener>

  <context-param>
    <param-name>log4jConfigLocation</param-name>
    <param-value>/WEB-INF/classes/log4j.properties</param-value>
  </context-param>

  <context-param>
    <param-name>webAppRootKey</param-name>
    <param-value>TERASOLUNA for Spring(thin)</param-value>
  </context-param>

<!-- filter setting -->

  <!-- アクセス権限チェック -->
  <!-- example
  <filter>
    <filter-name>authorizationControlFilter</filter-name>
    <filter-class>
      jp.terasoluna.fw.web.thin.AuthorizationControlFilter
    </filter-class>
  </filter>

  <filter-mapping>
    <filter-name>authorizationControlFilter</filter-name>
    <url-pattern>/*</url-pattern>
  </filter-mapping>
  -->

<!-- servlet setting -->

  <servlet>
    <servlet-name>action</servlet-name>
    <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
    <init-param>
      <param-name>config</param-name>
      <param-value>/WEB-INF/struts-config.xml</param-value>
    </init-param>
    <init-param>
      <param-name>debug</param-name>
      <param-value>2</param-value>
    </init-param>
    <init-param>
      <param-name>detail</param-name>
      <param-value>2</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
  </servlet>

  <!-- Standard Action Servlet Mapping -->
  <servlet-mapping>
    <servlet-name>action</servlet-name>
    <url-pattern>*.do</url-pattern>
  </servlet-mapping>

  <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
  </welcome-file-list>

  <error-page>
    <exception-type>java.lang.Exception</exception-type>
    <location>/error.jsp</location>
  </error-page>

  <error-page>
    <error-code>404</error-code>
    <location>/error.jsp</location>
  </error-page>

  <jsp-config>
    <!-- Strutsタグ -->
    <taglib>
      <taglib-uri>/struts-bean</taglib-uri>
      <taglib-location>/WEB-INF/tlds/struts-bean.tld</taglib-location>
    </taglib>
    <taglib>
      <taglib-uri>/struts-html</taglib-uri>
      <taglib-location>/WEB-INF/tlds/struts-html.tld</taglib-location>
    </taglib>
    <taglib>
      <taglib-uri>/struts-logic</taglib-uri>
      <taglib-location>/WEB-INF/tlds/struts-logic.tld</taglib-location>
    </taglib>

    <!-- TERASOLUNAカスタムタグ -->
    <taglib>
      <taglib-uri>/terasoluna</taglib-uri>
      <taglib-location>/WEB-INF/tlds/terasoluna.tld</taglib-location>
    </taglib>

    <taglib>
      <taglib-uri>/terasoluna-struts</taglib-uri>
      <taglib-location>/WEB-INF/tlds/terasoluna-struts.tld</taglib-location>
    </taglib>
  </jsp-config>

</web-app>
