Class HtmlWidgetRenderer

  • Direct Known Subclasses:
    FoFormRenderer, HtmlMenuRenderer, HtmlTreeRenderer

    public class HtmlWidgetRenderer
    extends java.lang.Object
    Widget Library - HTML Widget Renderer implementation. HtmlWidgetRenderer is a base class that is extended by other widget HTML rendering classes.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String module  
      static java.lang.String whiteSpace
      Characters that are appended to the end of each rendered element.
      protected boolean widgetCommentsEnabled  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void appendWhitespace​(java.lang.Appendable writer)
      Helper method used to append whitespace characters to the end of each rendered element.
      java.lang.String buildBoundaryComment​(java.lang.String boundaryType, java.lang.String widgetType, java.lang.String widgetName)
      Helper method used to build the boundary comment string.
      static java.lang.String formatBoundaryComment​(java.lang.String boundaryType, java.lang.String widgetType, java.lang.String widgetName)  
      static java.lang.String getAjaxParamsFromTarget​(java.lang.String target)
      Extracts parameters from a target URL string, prepares them for an Ajax JavaScript call.
      void renderBeginningBoundaryComment​(java.lang.Appendable writer, java.lang.String widgetType, ModelWidget modelWidget)
      Renders the beginning boundary comment string.
      void renderEndingBoundaryComment​(java.lang.Appendable writer, java.lang.String widgetType, ModelWidget modelWidget)
      Renders the ending boundary comment string.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • module

        public static final java.lang.String module
      • whiteSpace

        public static final java.lang.String whiteSpace
        Characters that are appended to the end of each rendered element. Currently set to CR/LF.
        See Also:
        Constant Field Values
      • widgetCommentsEnabled

        protected boolean widgetCommentsEnabled
    • Constructor Detail

      • HtmlWidgetRenderer

        public HtmlWidgetRenderer()
    • Method Detail

      • appendWhitespace

        public void appendWhitespace​(java.lang.Appendable writer)
                              throws java.io.IOException
        Helper method used to append whitespace characters to the end of each rendered element.
        Parameters:
        writer - The writer to write to
        Throws:
        java.io.IOException
      • buildBoundaryComment

        public java.lang.String buildBoundaryComment​(java.lang.String boundaryType,
                                                     java.lang.String widgetType,
                                                     java.lang.String widgetName)
        Helper method used to build the boundary comment string.
        Parameters:
        boundaryType - The boundary type: "Begin" or "End"
        widgetType - The widget type: "Screen Widget", "Form Widget", etc.
        widgetName - The widget name
      • formatBoundaryComment

        public static java.lang.String formatBoundaryComment​(java.lang.String boundaryType,
                                                             java.lang.String widgetType,
                                                             java.lang.String widgetName)
      • renderBeginningBoundaryComment

        public void renderBeginningBoundaryComment​(java.lang.Appendable writer,
                                                   java.lang.String widgetType,
                                                   ModelWidget modelWidget)
                                            throws java.io.IOException
        Renders the beginning boundary comment string.
        Parameters:
        writer - The writer to write to
        widgetType - The widget type: "Screen Widget", "Form Widget", etc.
        modelWidget - The widget
        Throws:
        java.io.IOException
      • renderEndingBoundaryComment

        public void renderEndingBoundaryComment​(java.lang.Appendable writer,
                                                java.lang.String widgetType,
                                                ModelWidget modelWidget)
                                         throws java.io.IOException
        Renders the ending boundary comment string.
        Parameters:
        writer - The writer to write to
        widgetType - The widget type: "Screen Widget", "Form Widget", etc.
        modelWidget - The widget
        Throws:
        java.io.IOException
      • getAjaxParamsFromTarget

        public static java.lang.String getAjaxParamsFromTarget​(java.lang.String target)
        Extracts parameters from a target URL string, prepares them for an Ajax JavaScript call. This method is currently set to return a parameter string suitable for the Prototype.js library.
        Parameters:
        target - Target URL string
        Returns:
        Parameter string