Provided is a method, system, program, and data structures for generating
a user interface. An application program processes data and generates application
output and a user interface module processes the application output to generate
output data to render on an output device. The user interface module generates
output data to render on the output device in response to processing statements
in the user interface module. The user interface module reaches a processing point
where the user interface module does not include statements to generate output
data. After reaching the processing point, the user interface module receives an
interaction object from the application program specifying data to generate as
output data. The user interface module then generates output data to render on
the output device from the interaction object.