processRequest

fun processRequest(request: JSONObject, processor: Any): EncodableResult<Any?>

Processes a request to invoke a function on the given processor object safely.

Return

An EncodableResult containing the result of the function call or an error.

Parameters

request

A JSONObject containing the function name and arguments. - functionName: The name of the function to invoke (String). - functionArgs: The arguments for the function (JSONObject).

processor

The object containing the functions to be invoked.