You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by Claude Brisson <cl...@renegat.net> on 2008/12/13 17:48:30 UTC

[TOOLS] Setting scoped attributes

I made a WebappUberspector to allow expressions like:

	#set($session.foo = 'bar') 

for $request, $session and $application, instead of

	#set($junk = $session.setAttribute('foo','bar))

which use the brand new ChainableUberspector mechanism. I'd like to
include it in the trunk and make it the default in the tools
velocity.property file, but since the user may already use a custom
uberspector, the default configuration will be lost.

That is, I'd put in org/apache/velocity/tools/view/velocity.properties
(tools defaults) :

  # Use the WebappUberspector to allow setting of scoped attributes
  runtime.introspector.uberspect = o.a.v.util.introspection.UberspectImpl,o.a.v.tools.view.WebappUberspector

but users already using the SecureUberspector in their
velocity.properties won't see any change and will have to update their
config if they want the new syntax to be available.	

Does it seem ok to you?

  Claude




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org


Re: [TOOLS] Setting scoped attributes

Posted by Claude Brisson <cl...@renegat.net>.
And I just recalled that the tools only wanted velocity-1.5, so I guess
I'll only put it on the wiki for now...

never mind.

  Claude

On sam, 2008-12-13 at 17:48 +0100, Claude Brisson wrote:
> I made a WebappUberspector to allow expressions like:
> 
> 	#set($session.foo = 'bar') 
> 
> for $request, $session and $application, instead of
> 
> 	#set($junk = $session.setAttribute('foo','bar))
> 
> which use the brand new ChainableUberspector mechanism. I'd like to
> include it in the trunk and make it the default in the tools
> velocity.property file, but since the user may already use a custom
> uberspector, the default configuration will be lost.
> 
> That is, I'd put in org/apache/velocity/tools/view/velocity.properties
> (tools defaults) :
> 
>   # Use the WebappUberspector to allow setting of scoped attributes
>   runtime.introspector.uberspect = o.a.v.util.introspection.UberspectImpl,o.a.v.tools.view.WebappUberspector
> 
> but users already using the SecureUberspector in their
> velocity.properties won't see any change and will have to update their
> config if they want the new syntax to be available.	
> 
> Does it seem ok to you?
> 
>   Claude
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
> For additional commands, e-mail: dev-help@velocity.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org


Re: [TOOLS] Setting scoped attributes

Posted by Nathan Bubna <nb...@gmail.com>.
Yeah, if they can set their own uberspect, they should be able to read
the release notes and adapt their uberspect setting if they want to
use this feature.

The more important question to me is whether we want to require Engine
1.6+ for Tools 2.0.  This would be the first dependency on Engine 1.6.
  I've been debating this myself...

On Sat, Dec 13, 2008 at 8:48 AM, Claude Brisson <cl...@renegat.net> wrote:
> I made a WebappUberspector to allow expressions like:
>
>        #set($session.foo = 'bar')
>
> for $request, $session and $application, instead of
>
>        #set($junk = $session.setAttribute('foo','bar))
>
> which use the brand new ChainableUberspector mechanism. I'd like to
> include it in the trunk and make it the default in the tools
> velocity.property file, but since the user may already use a custom
> uberspector, the default configuration will be lost.
>
> That is, I'd put in org/apache/velocity/tools/view/velocity.properties
> (tools defaults) :
>
>  # Use the WebappUberspector to allow setting of scoped attributes
>  runtime.introspector.uberspect = o.a.v.util.introspection.UberspectImpl,o.a.v.tools.view.WebappUberspector
>
> but users already using the SecureUberspector in their
> velocity.properties won't see any change and will have to update their
> config if they want the new syntax to be available.
>
> Does it seem ok to you?
>
>  Claude
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
> For additional commands, e-mail: dev-help@velocity.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org