Interface WidgetWriter

All Superinterfaces:
UIBodyWriter, UIComponentWriter, UIDependencyRegisterer, UIFormWriter, UIJavaScriptWriter, UIResourceLocator, UISessionContext
All Known Subinterfaces:
WidgetWriterForList

public interface WidgetWriter extends UIFormWriter
This interface offers methods that can be used to create a standard EBX® widget.
Since:
5.8.0
See Also:
  • Method Details

    • getWidgetName

      String getWidgetName()
      Returns the custom widget name based on the node path to which this widget is bound. Can be used as a prefix or a suffix to generate identifiers of inner input components.

      The widget name is only to be used on custom external components (with the HTML attribute name or id for example). It must not be used to manipulate native components or widgets. Native components are internal and the widget name policy can be modified at any time.

    • getWidgetName

      String getWidgetName(Path aPath)
      Returns the custom widget name based on the given path. Can be used as a prefix or a suffix to generate identifiers of inner input components.

      The widget name is only to be used on custom external components (with the HTML attribute name or id for example). It must not be used to manipulate native components or widgets. Native components are internal and the widget name policy can be modified at any time.

      Parameters:
      aPath - location of the target relative to the current node (for maximizing reusability, it is advised to use a relative path)
    • getWidgetName

      String getWidgetName(String aLocalId)
      Returns the custom widget name based on the given string. Can be used as a prefix or a suffix to generate identifiers of inner input components.

      The widget name is only to be used on custom external components (with the HTML attribute name or id for example). It must not be used to manipulate native components or widgets. Native components are internal and the widget name policy can be modified at any time.

      Parameters:
      aLocalId - must respect the pattern [a-zA-Z0-9_.-]+
    • getWidgetNameOfParent

      String getWidgetNameOfParent()
      Returns the custom widget name of the parent component. Can be used as a prefix or a suffix to generate identifiers of inner input components.

      The web name is only to be used on custom external components (with the HTML attribute name or id for example). It must not be used to manipulate native components or widgets. Native components are internal and the web name policy can be modified at any time.

    • getTableCellStyleHandler

      UITableCellStyleHandler getTableCellStyleHandler() throws IllegalStateException
      This method allows customizing the look of a table cell.

      It can only be invoked in the context of a table grid cell display. See WidgetDisplayContext.isDisplayedInTable() for more information.

      Returns:
      the UITableCellStyleHandler to add styles on the current cell.
      Throws:
      IllegalStateException - if this method is called outside of a table cell.
    • addEmptyFieldButton

      void addEmptyFieldButton(String buttonId, boolean isDisabled, String aJavaScriptCommand)
      Adds a button with the built-in "empty field" button look and feel.

      A click on this button will execute the given JavaScript command.

    • addServiceButton

      void addServiceButton(Path aPath)
      Adds a service menu button to the specified node.

      If no services are defined for the node, or if no services are granted to the user according to access rights, no button will be added.

      The standard position of the service button is to the right of the component; the standard position of the validation message is below the component.

      Parameters:
      aPath - required, location of the target, relative to the current node; to improve reusability, use a relative path.
      See Also:
    • addUIValidationMessage

      void addUIValidationMessage(Path aPath)
      Adds the validation message associated with the specified node.

      The standard position of the validation message is below the component, and the standard position of the service button is to the right of the component.

      Parameters:
      aPath - required, location of the target, relative to the current node; to improve reusability, use a relative path.
      See Also:
    • addUIDescription

      void addUIDescription(Path aPath)
      Parameters:
      aPath - required, location of the target, relative to the current node; to improve reusability, use a relative path.
    • addUILabel

      void addUILabel(Path aPath)
      Adds the standard label of the specified data model node.

      The description and additional information about the node are available in a pop-up.

      Parameters:
      aPath - required, location of the target, relative to the current node (for better reusability, it is advised to use a relative path)
      See Also:
    • addUIDisplayValue

      void addUIDisplayValue(Path aPath)
      Displays the value of the specified field.
      Parameters:
      aPath - required, location of the target, relative to the current node; to improve reusability, use a relative path.