NodeBody

The body of a FunctionNode set through FunctionNode.Builder.body; it runs on the workflow's coroutine, so it must not block, and asynchronous work belongs in a BasePublisherNode. input arrives as the node's input type, in JSON form on an untyped port (a whole number as a Long, a fraction as a Double, an object as a Map), or as a Content message, and may be a predecessor's own collection, so the body must not mutate it. Return null for no output, a value of the output type, or an Event to emit as it is (an Event with content sends a message, and an output goes in the return value, not in the Event), and ask the user with requestInput.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
abstract fun apply(context: Context, input: I): O