Class Help

All Implemented Interfaces:
Serializable, Cloneable, Copyable, DictionaryBean, UifDictionaryBean, Component, Ordered, ScriptEventSupport, LifecycleElement, Widget, org.springframework.core.Ordered

public class Help extends WidgetBase
Widget that renders help on a component

If help URL is specified then display help icon and/or if help summary is specified then display help tooltip.

Author:
Kuali Rice Team (rice.collab@kuali.org)
See Also:
  • Constructor Details

    • Help

      public Help()
  • Method Details

    • performInitialization

      public void performInitialization(Object model)
      The following initialization is performed:
      • If help action not initialized and external help is configured, get the default help action component
      The following updates are done here:
      • Invoke performInitialize on component modifiers
      Initializes the component

      Where components can set defaults and setup other necessary state. The initialize method should only be called once per component lifecycle and is invoked within the initialize phase of the view lifecylce.

      Specified by:
      performInitialization in interface LifecycleElement
      Overrides:
      performInitialization in class ComponentBase
      Parameters:
      model - - object instance containing the view data
      See Also:
    • performFinalize

      public void performFinalize(Object model, LifecycleElement parent)
      Finalize the help widget for usage

      In addition to the standard finalization the following tasks are performed:

      1. Build the external help Url
      2. Set the javascript action which opens the external help in window
      3. Set render to false if help not configured
      The following finalization is done here:
      • progressiveRender and conditionalRefresh variables are processed if set
      • If any of the style properties were given, sets the style string on the style property
      • Set the skipInTabOrder flag for nested components
      The last phase before the view is rendered

      Here final preparations can be made based on the updated view state.

      Specified by:
      performFinalize in interface LifecycleElement
      Overrides:
      performFinalize in class ComponentBase
      Parameters:
      model - - top level object containing the data
      parent - - parent component
    • buildExternalHelp

      protected void buildExternalHelp(LifecycleElement parent)
      Build the external help

      When the externalHelpUrl is blank and the helpDefinition is specified then the external help URL is looked up via the helpDefinition from the system parameters. The namespace in the helpDefinition does not need to be specified and will default to the namespace of the view.

      Set the javascript action to open the external help in a window.

      Set the html title attribute of the help icon.

      Parameters:
      parent - used to get the help title text used in the html title attribute of the help icon
    • buildTooltipHelp

      protected void buildTooltipHelp(LifecycleElement parent)
      Build the tooltip help

      The help tooltip is set on the component. To use the help tooltip bean definition, the help's tooltip is used as and intermediary for setting up the tooltip widget and then copied to the component.

      Parameters:
      parent - used for checking misconfigurations
    • getHelpAction

      public Action getHelpAction()
      HelpActionField is used for rendering external help
      Returns:
      Action for external help
    • setHelpAction

      public void setHelpAction(Action helpAction)
      Setter for helpAction
      Parameters:
      helpAction -
    • getHelpDefinition

      public HelpDefinition getHelpDefinition()
      The help definition is used as the key to retrieve the external help Url from the parameter table of the database
      Returns:
      HelpDefinition
    • setHelpDefinition

      public void setHelpDefinition(HelpDefinition helpDefinition)
      Setter for the help definition of the database.
      Parameters:
      helpDefinition -
    • getExternalHelpUrl

      public String getExternalHelpUrl()
      The external help Url

      This should contain a valid URL. When specified this URL takes precedence over the external help URL from the system parameters.

      Returns:
      Url of the external help
    • setExternalHelpUrl

      public void setExternalHelpUrl(String externalHelpUrl)
      Setter for externalHelpUrl
      Parameters:
      externalHelpUrl -
    • getTooltipHelpContent

      public String getTooltipHelpContent()
      TooltipHelpContent
      Returns:
      TooltipHelpContent
    • setTooltipHelpContent

      public void setTooltipHelpContent(String tooltipHelpContent)
      Setter for tooltipHelpContent
      Parameters:
      tooltipHelpContent -
    • getParameterService

      protected org.kuali.rice.coreservice.framework.parameter.ParameterService getParameterService()
      Retrieve the parameter service
      Returns:
      ParameterService