Delegating Rendering to a Renderer
Both MapComponent and AreaComponent delegate all of their rendering to a separate renderer. The section Performing Encoding (page 780) explains how the MapRenderer performs the encoding for MapComponent. This section explains in detail the process of delegating rendering to a renderer using AreaRenderer, which performs the rendering for AreaComponent.
To delegate rendering, you perform these tasks:
Create the Renderer class
Register the renderer with a render kit (explained in Registering a Custom Renderer with a Render Kit, page 808)
Identify the renderer type in the component's tag handler
Creating the Renderer Class
When delegating rendering to a renderer, you can delegate all encoding and decoding to the renderer, ...
Get The J2EE™ Tutorial Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.