<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xmlns:util="http://www.springframework.org/schema/util"
  xsi:schemaLocation="http://www.springframework.org/schema/beans
    http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
    http://www.springframework.org/schema/util
    http://www.springframework.org/schema/util/spring-util-2.5.xsd">

  <bean id="localConfiguration" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
    <property name="location" value="file:/etc/unitedfront2/localConfiguration.properties"/>
  </bean>

  <bean id="availableLocales" class="java.util.ArrayList">
    <constructor-arg>
      <list>
        <util:constant static-field="java.util.Locale.JAPANESE"/>
        <util:constant static-field="java.util.Locale.ENGLISH"/>
      </list>
    </constructor-arg>
  </bean>

  <bean id="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
    <property name="basename" value="messages"/>
  </bean>

  <bean id="themeSource" class="org.springframework.ui.context.support.ResourceBundleThemeSource">
    <property name="basenamePrefix" value="theme_"/>
  </bean>

  <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
    <property name="driverClassName" value="${dataSource.driver}"/>
    <property name="url" value="${dataSource.url}"/>
    <property name="username" value="${dataSource.username}"/>
    <property name="password" value="${dataSource.password}"/>
    <property name="maxActive" value="${dataSource.maxActive}"/>
    <property name="maxIdle" value="${dataSource.maxIdle}"/>
    <property name="initialSize" value="${dataSource.initialSize}"/>
    <property name="maxWait" value="${dataSource.maxWait}"/>
    <property name="testOnBorrow" value="${dataSource.testOnBorrow}"/>
    <property name="testOnReturn" value="${dataSource.testOnReturn}"/>
    <property name="validationQuery" value="${dataSource.validationQuery}"/>
  </bean>

  <!-- Services -->
  <bean id="captchaService" class="com.octo.captcha.service.image.DefaultManageableImageCaptchaService"/>

</beans>
