Error

This object contains a script error description to notify the calling code of an exceptional runtime condition.

When an error is returned from a script evaluation, it is converted to a Java™ exception and thrown from the script evaluator class..

Availability
IBM Security Identity Manager 7.0

Provided by
com.ibm.itim.script.extensions.EnroleExtension

Methods

setMessage()
Sets the message for the error.

getMessage()
Retrieves the error message for the error.

setErrorCode()
Sets the error code for the error.

getErrorCode()
Retrieves the error code for the error.

Usage
    var sn = subject.getProperty("sn"); if(sn == null || sn.length == 0) { error.setMessage("sn was missing"); return error; } else { return sn[0]; }

Parent topic: JavaScript extension reference