Displaying a simple error page from a flow

Cantor, Scott cantor.2 at osu.edu
Fri Dec 9 16:16:57 EST 2016


On 12/9/16, 4:12 PM, "users on behalf of Wessel, Keith" <users-bounces at shibboleth.net on behalf of kwessel at illinois.edu> wrote:

>    Ah. Thank you. So the setPrincipal method simply needs to know what method to call to set the principal when it actually
> goes to do the attribute resolving. Makes sense. And the apply method was the only thing I was missing.

The setPrincipal method takes a String, and the Function in question returns one, you just have to call it.

Functions are just classes with an apply() method that take an input and return an output. Our functions almost always take a ProfileRequestContext as input. The return types vary by function.

The ProfileRequestContext object is populated in scripts as a variable called "input".

So if you have a Function bean, you call bean.apply(input) to get it to run, most of the time.

Predicates/conditions are the same, they're just like functions that return boolean.

-- Scott




More information about the users mailing list