org.springframework.web.servlet.view.velocity
Class VelocityViewResolver

org.springframework.context.support.ApplicationObjectSupport
  |
  +--org.springframework.web.context.support.WebApplicationObjectSupport
        |
        +--org.springframework.web.servlet.view.AbstractCachingViewResolver
              |
              +--org.springframework.web.servlet.view.UrlBasedViewResolver
                    |
                    +--org.springframework.web.servlet.view.velocity.VelocityViewResolver

public class VelocityViewResolver
extends UrlBasedViewResolver

Convenience subclass of UrlBasedViewResolver that supports VelocityView (i.e. Velocity templates) and custom subclasses of it.

The view class for all views generated by this resolver can be specified via setViewClass. See UrlBasedViewResolver's javadocs for details.

Author:
Juergen Hoeller
Since: 13.12.2003
See Also: org.springframework.web.servlet.view.UrlBasedViewResolver.setViewClass(java.lang.Class), org.springframework.web.servlet.view.UrlBasedViewResolver.setPrefix(java.lang.String), org.springframework.web.servlet.view.UrlBasedViewResolver.setSuffix(java.lang.String), org.springframework.web.servlet.view.UrlBasedViewResolver.setRequestContextAttribute(java.lang.String), setDateToolAttribute(java.lang.String), VelocityView

Constructor Summary
VelocityViewResolver()
          Sets default viewClass to VelocityView.

Method Summary
 voidsetDateToolAttribute(String dateToolAttribute)
          Set the name of the DateHool helper object to expose in the Velocity context of this view, or null if not needed.

Methods inherited from class org.springframework.web.servlet.view.UrlBasedViewResolver
setContentType, setPrefix, setRequestContextAttribute, setSuffix, setViewClass

Methods inherited from class org.springframework.web.servlet.view.AbstractCachingViewResolver
isCache, resolveViewName, setCache

Methods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, setApplicationContext

Constructor Detail

VelocityViewResolver

public VelocityViewResolver()
Sets default viewClass to VelocityView.
See Also:
org.springframework.web.servlet.view.UrlBasedViewResolver.setViewClass(java.lang.Class)
Method Detail

setDateToolAttribute

public void setDateToolAttribute(String dateToolAttribute)
Set the name of the DateHool helper object to expose in the Velocity context of this view, or null if not needed. DateTool is from Velocity Tools.

Association Links

to Class java.lang.String