Interface RenderContext

  • All Known Implementing Classes:
    NullRenderContext, WebXmlRenderContext

    public interface RenderContext

    The RenderContext is used to render a component. It is passed into the WComponent.paint(RenderContext) method as an argument and also the specific Renderer instance used to render the component. Components themselves must not rely on knowledge of the context.

    The appropriate Renderer for each component is obtained from the UIManager, which calls the getRenderPackage() method to obtain the package name which contains all of the renderers for a given type of context.

    RenderContext subclasses should contain additional data & methods which are necessary to render the component in the context. For example, a Web/HTTP renderer may include a reference to the ServletResponse.

    Since:
    1.0.0
    Author:
    Yiannis Paschalidis
    • Method Detail

      • getRenderPackage

        String getRenderPackage()
        Return the java package name which contains the renderers for this renderer. This package must contain a public class named "RendererFactory", which implements the RendererFactory interface.
        Returns:
        the renderer package name.