Look at IDP-970 ?
Tom Zeller
tzeller at dragonacea.biz
Tue Oct 25 12:26:23 EDT 2016
On Oct 25, 2016, at 10:59 AM, Cantor, Scott <cantor.2 at osu.edu> wrote:
>> I may have missed you today, but could you look at the
>> IsAttributeRequiredPredicate when you have a chance ?
>
> The Predicate should just be stateless, and have the HttpServletRequest injected along with the other strategies, and declared in the flow beans. Then just export it to the view context inside the view-state as a view scope object.
>
> To make that work, you need to move the getRequestedAttributes call down into the apply() method. Yes, it's a bit less efficient, but that's life.
>
> Another way to go would be to go at this more directly with a Function instead of a Predicate and just have it run and return a set of attribute IDs that are required and inject that set into the view. That might be simpler and less work.
FWIW I started at populating the attr release context with the map of requested attributes, perhaps the function to do so could be injected into the appropriate populate action. That function in this case could be injected with the predicate, that's the model I believe.
But I don't really like instantiating the predicate in the view-state. Kinda yuck.
I agree though.
Tom
More information about the dev
mailing list