Widget Code

Widget code is divided functionally into:

  • A controller that contains all the logic required to produce the values needed to render a widget.

  • A view that use the values generated by the controller to produce the final output.

Widget views are always implemented in JSP. Controllers, however, may be implemented either in JSP or in Java. These two different kinds of widget are described further in the following sections.