ScriptedPredicate
The predicate bean named shibboleth.Conditions.Scripted executes a JSR-223 scriptlet against a ProfileRequestContext to produce a true/false result.
Configuration
A Scripted Predicate is instantiated using one of two static factory methods (rather than created directly by invoking a Java constructor), so they have a different syntax in Spring. You can refer to the javadoc for complete details.
Alternative Input Types
Most of the conditions used in the IdP configuration tend to be of the signature Predicate<ProfileRequestContext>, which this bean provides. In some unusual cases, a different input type is used. In such cases, this bean can’t be used, but a Java class that is higher up in the class hierarchy can be substituted instead, net.shibboleth.shared.logic.ScriptedPredicate
Using this class is essentially the same as using the parent bean except that the bean declaration contains this:
<bean id="example" class="net.shibboleth.shared.logic.ScriptedPredicate">
instead of:
In addition, adding the property named “inputType” and setting it to a specific class type expected as input will constrain the class and raise an error if an unexpected type is passed into the script.
Reference