| <?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 beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd"> |
| |
| <!-- |
| - Application context definition for "sample" DispatcherServlet. |
| --> |
| |
| <beans> |
| |
| <bean id="urlMapping" class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping"> |
| <property name="mappings"> |
| <props> |
| <prop key="index">indexController</prop> |
| <prop key="jsecurity.jnlp">jnlpController</prop> |
| <prop key="login">loginController</prop> |
| <prop key="logout">logoutController</prop> |
| <prop key="unauthorized">loginController</prop> |
| </props> |
| </property> |
| </bean> |
| |
| <bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver"> |
| <property name="viewClass" value="org.springframework.web.servlet.view.InternalResourceView"/> |
| <property name="prefix" value="/WEB-INF/resources/"/> |
| <property name="suffix" value=".jsp"/> |
| </bean> |
| |
| <!-- ========================================================= |
| Spring controllers |
| ========================================================= --> |
| <bean name="loginController" class="org.apache.ki.samples.spring.web.LoginController"> |
| <property name="commandClass" value="org.apache.ki.samples.spring.web.LoginCommand"/> |
| <property name="formView" value="login"/> |
| <property name="successView" value="redirect:/s/index"/> |
| <property name="securityManager" ref="securityManager"/> |
| </bean> |
| |
| <bean name="logoutController" class="org.apache.ki.samples.spring.web.LogoutController"/> |
| |
| <bean id="jnlpController" class="org.apache.ki.samples.spring.web.JnlpController"> |
| <property name="jnlpView" value="jsecurity.jnlp"/> |
| </bean> |
| |
| <bean id="indexController" class="org.apache.ki.samples.spring.web.IndexController"> |
| <property name="commandClass" value="org.apache.ki.samples.spring.web.SessionValueCommand"/> |
| <property name="formView" value="sampleIndex"/> |
| <property name="successView" value="sampleIndex"/> |
| <property name="sampleManager" ref="sampleManager"/> |
| </bean> |
| |
| <bean name="urlController" class="org.springframework.web.servlet.mvc.UrlFilenameViewController"/> |
| |
| </beans> |