亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? velocityconfigurer.java

?? spring framework 2.5.4源代碼
?? JAVA
字號:
/*
 * Copyright 2002-2007 the original author or authors.
 *
 * Licensed 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.
 */

package org.springframework.web.servlet.view.velocity;

import java.io.IOException;

import org.apache.velocity.app.VelocityEngine;
import org.apache.velocity.exception.VelocityException;
import org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader;

import org.springframework.beans.factory.InitializingBean;
import org.springframework.context.ResourceLoaderAware;
import org.springframework.ui.velocity.VelocityEngineFactory;

/**
 * JavaBean to configure Velocity for web usage, via the "configLocation"
 * and/or "velocityProperties" and/or "resourceLoaderPath" bean properties.
 * The simplest way to use this class is to specify just a "resourceLoaderPath";
 * you do not need any further configuration then.
 *
 * <pre class="code">
 * &lt;bean id="velocityConfig" class="org.springframework.web.servlet.view.velocity.VelocityConfigurer"&gt;
 *   &lt;property name="resourceLoaderPath">&lt;value&gt;/WEB-INF/velocity/&lt;/value>&lt;/property&gt;
 * &lt;/bean&gt;</pre>
 *
 * This bean must be included in the application context of any application
 * using Spring's {@link VelocityView} for web MVC. It exists purely to configure
 * Velocity; it is not meant to be referenced by application components (just
 * internally by VelocityView). This class implements {@link VelocityConfig}
 * in order to be found by VelocityView without depending on the bean name of
 * this configurer. Each DispatcherServlet may define its own VelocityConfigurer
 * if desired, potentially with different template loader paths.
 *
 * <p>Note that you can also refer to a pre-configured VelocityEngine
 * instance via the "velocityEngine" property, e.g. set up by
 * {@link org.springframework.ui.velocity.VelocityEngineFactoryBean},
 * This allows to share a VelocityEngine for web and email usage, for example.
 *
 * <p>This configurer registers the "spring.vm" Velocimacro library for web views
 * (contained in this package and thus in <code>spring.jar</code>), which makes
 * all of Spring's default Velocity macros available to the views.
 * This allows for using the Spring-provided macros such as follows:
 *
 * <pre class="code">
 * #springBind("person.age")
 * age is ${status.value}</pre>
 *
 * @author Rod Johnson
 * @author Juergen Hoeller
 * @author Darren Davison
 * @see #setConfigLocation
 * @see #setVelocityProperties
 * @see #setResourceLoaderPath
 * @see #setVelocityEngine
 * @see VelocityView
 */
public class VelocityConfigurer extends VelocityEngineFactory
		implements VelocityConfig, InitializingBean, ResourceLoaderAware {

	/** the name of the resource loader for Spring's bind macros */
	private static final String SPRING_MACRO_RESOURCE_LOADER_NAME = "springMacro";

	/** the key for the class of Spring's bind macro resource loader */
	private static final String SPRING_MACRO_RESOURCE_LOADER_CLASS = "springMacro.resource.loader.class";

	/** the name of Spring's default bind macro library */
	private static final String SPRING_MACRO_LIBRARY = "org/springframework/web/servlet/view/velocity/spring.vm";


	private VelocityEngine velocityEngine;


	/**
	 * Set a pre-configured VelocityEngine to use for the Velocity web
	 * configuration: e.g. a shared one for web and email usage, set up via
	 * {@link org.springframework.ui.velocity.VelocityEngineFactoryBean}.
	 * <p>Note that the Spring macros will <i>not</i> be enabled automatically in
	 * case of an external VelocityEngine passed in here. Make sure to include
	 * <code>spring.vm</code> in your template loader path in such a scenario
	 * (if there is an actual need to use those macros).
	 * <p>If this is not set, VelocityEngineFactory's properties
	 * (inherited by this class) have to be specified.
	 */
	public void setVelocityEngine(VelocityEngine velocityEngine) {
		this.velocityEngine = velocityEngine;
	}

	/**
	 * Initialize VelocityEngineFactory's VelocityEngine
	 * if not overridden by a pre-configured VelocityEngine.
	 * @see #createVelocityEngine
	 * @see #setVelocityEngine
	 */
	public void afterPropertiesSet() throws IOException, VelocityException {
		if (this.velocityEngine == null) {
			this.velocityEngine = createVelocityEngine();
		}
	}

	/**
	 * Provides a ClasspathResourceLoader in addition to any default or user-defined
	 * loader in order to load the spring Velocity macros from the class path.
	 * @see org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader
	 */
	protected void postProcessVelocityEngine(VelocityEngine velocityEngine) {
		velocityEngine.setProperty(
				SPRING_MACRO_RESOURCE_LOADER_CLASS, ClasspathResourceLoader.class.getName());
		velocityEngine.addProperty(
				VelocityEngine.RESOURCE_LOADER, SPRING_MACRO_RESOURCE_LOADER_NAME);
		velocityEngine.addProperty(
				VelocityEngine.VM_LIBRARY, SPRING_MACRO_LIBRARY);
		if (logger.isInfoEnabled()) {
			logger.info("ClasspathResourceLoader with name '" + SPRING_MACRO_RESOURCE_LOADER_NAME +
					"' added to configured VelocityEngine");
		}
	}

	public VelocityEngine getVelocityEngine() {
		return this.velocityEngine;
	}

}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品剧情在线观看| 麻豆精品一二三| 日本亚洲免费观看| 成人做爰69片免费看网站| 欧美精品在欧美一区二区少妇| 中文字幕av资源一区| 免费在线视频一区| 欧美亚洲精品一区| 综合网在线视频| 大桥未久av一区二区三区中文| 欧美一卡2卡三卡4卡5免费| 亚洲精品高清在线观看| 国产精品一区二区免费不卡| 日韩欧美一区二区免费| 亚洲一区二区三区四区在线免费观看 | 国产日韩欧美精品一区| 亚洲va天堂va国产va久| 色婷婷精品大视频在线蜜桃视频| 中文字幕精品一区二区三区精品| 精品一区二区在线免费观看| 7777精品伊人久久久大香线蕉经典版下载 | 欧美日韩精品欧美日韩精品一| 国产精品不卡在线| 成人黄色综合网站| 欧美国产禁国产网站cc| 国产麻豆视频精品| 精品少妇一区二区三区免费观看| 日本午夜精品视频在线观看 | 久久九九影视网| 美女爽到高潮91| 欧美不卡123| 国产一区二区伦理| 国产网站一区二区三区| 高清国产一区二区三区| 国产三级欧美三级日产三级99| 精品一区二区三区视频| 久久综合资源网| 国产成人综合在线观看| 国产精品视频你懂的| 91在线视频观看| 亚洲一区日韩精品中文字幕| 欧美亚洲丝袜传媒另类| 日韩av一区二区在线影视| 欧美一级高清大全免费观看| 青青草原综合久久大伊人精品 | 欧美三级蜜桃2在线观看| 亚洲午夜久久久久久久久久久| 欧美日韩成人在线| 日本aⅴ免费视频一区二区三区| 日韩一区二区中文字幕| 久久99精品视频| 欧美国产欧美亚州国产日韩mv天天看完整| 国产精品中文字幕日韩精品| 亚洲国产精品成人综合 | 成人毛片老司机大片| 亚洲欧美日韩国产成人精品影院 | 国产精品乱人伦| 日本韩国欧美在线| 婷婷国产v国产偷v亚洲高清| 日韩女优制服丝袜电影| 波多野结衣亚洲| 性做久久久久久久免费看| 日韩精品一区二区三区三区免费 | 精品一区二区三区在线播放视频| 国产午夜精品一区二区三区四区 | 日韩一级二级三级精品视频| 国产精品一二三四区| 一区二区三区四区在线播放| 91精品免费在线| 99re视频精品| 理论电影国产精品| 亚洲另类一区二区| 久久人人超碰精品| 欧美老肥妇做.爰bbww视频| 国产大陆亚洲精品国产| 午夜视频在线观看一区二区| 国产片一区二区| 欧美电影影音先锋| 99精品国产91久久久久久| 狂野欧美性猛交blacked| 国产精品成人免费| 精品久久久久久久一区二区蜜臀| 在线观看亚洲精品| 成人99免费视频| 青青国产91久久久久久| 亚洲午夜久久久| 亚洲人123区| 久久久久99精品一区| 欧美丰满少妇xxxbbb| 99久久亚洲一区二区三区青草 | 麻豆精品国产91久久久久久| 亚洲精品免费在线| 国产亲近乱来精品视频| 欧美一区二区播放| 欧美日韩和欧美的一区二区| 日本高清不卡在线观看| 国产在线精品免费| 麻豆中文一区二区| 亚洲国产日韩精品| 亚洲精品中文在线影院| 中文字幕一区二区三区不卡| 久久一二三国产| 欧美白人最猛性xxxxx69交| 欧美日韩国产首页| 91一区二区在线| av在线不卡电影| 不卡的电影网站| av电影在线不卡| 成人国产免费视频| 丁香六月综合激情| 国产成人精品影视| 国产成人啪免费观看软件 | 日本一区二区视频在线观看| 精品处破学生在线二十三| 精品久久久久久最新网址| 日韩视频一区二区在线观看| 欧美一级欧美三级| 日韩一级二级三级| 精品久久久久久久久久久久久久久久久| 91精品在线观看入口| 制服丝袜国产精品| 日韩欧美视频在线| 久久精品亚洲国产奇米99 | 欧美电视剧在线看免费| 精品剧情v国产在线观看在线| xnxx国产精品| 日本一区二区三级电影在线观看| 国产欧美日韩在线观看| 中文字幕在线观看不卡| 一区二区欧美精品| 日韩二区在线观看| 久久成人av少妇免费| 国产精品一区二区你懂的| 成人国产电影网| 色香蕉成人二区免费| 欧美日产国产精品| 日韩女优视频免费观看| 国产视频一区不卡| 亚洲美女屁股眼交3| 石原莉奈一区二区三区在线观看| 韩国精品主播一区二区在线观看| 成人不卡免费av| 欧美私人免费视频| 精品日韩欧美一区二区| 国产精品理论在线观看| 亚洲第一会所有码转帖| 狠狠色丁香婷综合久久| 91网站最新网址| 日韩精品一区二区三区swag| 中文字幕一区二区日韩精品绯色| 亚洲一二三级电影| 国产精品一区二区你懂的| 91国产成人在线| 精品粉嫩超白一线天av| 亚洲综合在线五月| 国产精品1024| 欧美日韩高清一区| 中文字幕日本乱码精品影院| 日韩激情中文字幕| 99久久精品99国产精品 | 国产日韩欧美综合在线| 亚洲电影第三页| 成人黄色一级视频| 日韩一区二区三区视频在线| 亚洲天堂av老司机| 另类小说色综合网站| 欧美在线观看你懂的| 国产亚洲欧美日韩日本| 三级精品在线观看| 91在线视频观看| 久久精品视频一区二区三区| 日韩在线a电影| 色综合久久天天| 国产蜜臀av在线一区二区三区| 全国精品久久少妇| 91福利国产精品| 中文字幕国产一区| 精品制服美女丁香| 8x8x8国产精品| 亚洲国产另类av| 色呦呦日韩精品| 国产精品久久久久久久久晋中 | 欧美午夜免费电影| 中文字幕亚洲视频| 成人h版在线观看| 久久色在线观看| 久久国产精品区| 欧美日韩一区久久| 亚洲一区二区三区四区五区中文 | 日韩一级片网址| 国产精品网友自拍| 国产在线一区二区| 久久国产精品99久久人人澡| 久久99国产精品尤物| 91一区二区在线| 欧美成人精品高清在线播放 | 欧美日韩中文另类| 久久久精品人体av艺术| 亚洲国产精品嫩草影院| 成人午夜视频在线观看|