silken icon indicating copy to clipboard operation
silken copied to clipboard

Add Delegate Templates support

Open lincolncooper opened this issue 12 years ago • 1 comments

Would it be possible to add support for Delegate Templates so as to be able to specify the Package name(s) and call the setActiveDelegatePackageNames method?

lincolncooper avatar Oct 11 '12 11:10 lincolncooper

I've read about delcall/delpackage but have not personally used it (yet). I know with the current release of Silken it's not possible to use these at the moment as their is no way to pass through/set the appropriate delegate package names (i.e. setActiveDelegatePackageNames());

It would however be a minor code change to support this. It could be done in one of two ways:

  1. By providing a new Resolver similar to runtimeGlobalsResolver. A method on the resolver would return/set the package name(s).

  2. By passing through/setting a request attribute that defines the list of names. e.g.

req.setAttribute("model", boatPojo); req.setAttribute("active_deligate_package_names", ImmutableSet.of("MyDeligate");

  1. Or implement both, because it will be hard to predict how it may be used in the future.

I'll have a think about this and also see out some input from others. I'm going to make a few enhancements to Silken soon and will make these changes in this work.

codedance avatar Oct 11 '12 23:10 codedance