<?xml version="1.0" encoding="UTF-8"?>
<beans:beans xmlns="http://www.springframework.org/schema/mvc" xmlns:util="http://www.springframework.org/schema/util" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:beans="http://www.springframework.org/schema/beans" xmlns:context="http://www.springframework.org/schema/context" xsi:schemaLocation="http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd
		http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
		http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
        http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd">
 <!-- DispatcherServlet Context: defines this servlet's request-processing infrastructure -->
 <!-- Enables the Spring MVC @Controller programming model -->
 <annotation-driven/>
 <!-- Handles HTTP GET requests for /resources/** by efficiently serving up static resources in the ${webappRoot}/resources directory -->
 <resources mapping="/resources/**" location="/resources/"/>
 <resources mapping="/attach/**" location="/attach/"/>
 <resources mapping="/export/**" location="/export/"/>
 <beans:bean id="multiAccount" class="java.lang.Boolean">
  <beans:constructor-arg>
   <beans:value>false</beans:value>
  </beans:constructor-arg>
 </beans:bean>
 <!-- <beans:bean id="imagesMainFolder" class="java.lang.String"> <beans:constructor-arg> <beans:value>#{ multiAccount ? '/var/home/' : '/var/www/' }</beans:value> </beans:constructor-arg> </beans:bean> -->
 <!-- Resolves views selected for rendering by @Controllers to .jsp resources in the /WEB-INF/views directory -->
 <beans:bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
  <beans:property name="prefix" value="/WEB-INF/views/"/>
  <beans:property name="suffix" value=".jsp"/>
 </beans:bean>
 <context:component-scan base-package="org.xdams.*"/>
 <beans:bean id="multipartResolver" class="org.springframework.web.multipart.commons.CommonsMultipartResolver">
  <!-- one of the properties available; the maximum file size in bytes -->
  <beans:property name="maxUploadSize" value="-1"/>
 </beans:bean>
 <util:map id="mapExtraParam" map-class="java.util.HashMap">
  <beans:entry key="mapName" value="mapValue"></beans:entry>
 </util:map>
 <!-- multi lang -->
 <beans:bean id="messageSource" class="org.springframework.context.support.ReloadableResourceBundleMessageSource">
  <beans:property name="basename" value="WEB-INF/classes/xdams_messages"/>
  <beans:property name="defaultEncoding" value="UTF-8"/>
  <beans:property name="cacheSeconds" value="0"/>
  <beans:property name="fallbackToSystemLocale" value="false"/>
 </beans:bean>
 <beans:bean id="localeResolver" class="org.springframework.web.servlet.i18n.CookieLocaleResolver">
  <beans:property name="defaultLocale" value="it"/>
  <beans:property name="cookieName" value="xDamsLocaleCookie"></beans:property>
  <beans:property name="cookieMaxAge" value="3600"></beans:property>
 </beans:bean>
 <interceptors>
  <beans:bean class="org.springframework.web.servlet.i18n.LocaleChangeInterceptor">
   <beans:property name="paramName" value="lang"/>
  </beans:bean>
 </interceptors>
</beans:beans>