Class ScriptedDataConnector.DataConnectorScriptEvaluator
java.lang.Object
net.shibboleth.utilities.java.support.scripting.AbstractScriptEvaluator
net.shibboleth.idp.attribute.resolver.dc.impl.ScriptedDataConnector.DataConnectorScriptEvaluator
- Enclosing class:
- ScriptedDataConnector
private class ScriptedDataConnector.DataConnectorScriptEvaluator extends AbstractScriptEvaluator
Evaluator bound to the DataConnector semantic.
-
Field Summary
Fields inherited from class net.shibboleth.utilities.java.support.scripting.AbstractScriptEvaluator
DEFAULT_ENGINE
-
Constructor Summary
Constructors Constructor Description DataConnectorScriptEvaluator(EvaluableScript theScript)
Constructor. -
Method Summary
Modifier and Type Method Description private void
checkValues(IdPAttribute attribute)
Ensure that all the values in the attribute are of the correct type.protected Map<String,IdPAttribute>
execute(AttributeResolutionContext resolutionContext, AttributeResolverWorkContext workContext)
Execution hook.protected Object
finalizeContext(ScriptContext scriptContext, Object scriptResult)
protected void
prepareContext(ScriptContext scriptContext, Object... input)
Methods inherited from class net.shibboleth.utilities.java.support.scripting.AbstractScriptEvaluator
evaluate, getCustomObject, getHideExceptions, getLogPrefix, getOutputType, getReturnOnError, setCustomObject, setHideExceptions, setLogPrefix, setOutputType, setReturnOnError
-
Constructor Details
-
DataConnectorScriptEvaluator
Constructor.- Parameters:
theScript
- the script we will evaluate.
-
-
Method Details
-
execute
@Nullable protected Map<String,IdPAttribute> execute(@Nonnull AttributeResolutionContext resolutionContext, @Nonnull AttributeResolverWorkContext workContext) throws ResolutionExceptionExecution hook.- Parameters:
resolutionContext
- resolution contextworkContext
- work context- Returns:
- script result
- Throws:
ResolutionException
- if the script fails
-
prepareContext
- Specified by:
prepareContext
in classAbstractScriptEvaluator
-
finalizeContext
@Nullable protected Object finalizeContext(@Nonnull ScriptContext scriptContext, @Nullable Object scriptResult) throws ScriptException- Overrides:
finalizeContext
in classAbstractScriptEvaluator
- Throws:
ScriptException
-
checkValues
Ensure that all the values in the attribute are of the correct type.- Parameters:
attribute
- the attribute to look at
-