Class TextControlBase

All Implemented Interfaces:
Serializable, Cloneable, Copyable, DictionaryBean, UifDictionaryBean, Component, Ordered, ScriptEventSupport, Control, SizedControl, TextControl, ContentElement, LifecycleElement, org.springframework.core.Ordered
Direct Known Subclasses:
GroupControl, SpinnerControl, UserControl

public class TextControlBase extends ControlBase implements TextControl, SizedControl
Represents a HTML Text control, generally rendered as a input field of type 'text'. This can display and receive a single value
Author:
Kuali Rice Team (rice.collab@kuali.org)
See Also:
  • Constructor Details

    • TextControlBase

      public TextControlBase()
  • Method Details

    • performFinalize

      public void performFinalize(Object model, LifecycleElement parent)
      The following actions are performed:
      • Defaults maxLength, minLength (if not set) to maxLength of parent field
      Parses the disabled expressions, if any, to equivalent javascript and evaluates the disable/enable when changed property names.
      Specified by:
      performFinalize in interface LifecycleElement
      Overrides:
      performFinalize in class ControlBase
      Parameters:
      model - top level object containing the data
      parent - parent component
    • getSize

      public int getSize()
      Retrieves the configured size for the control, which reflects the display width in characters for the control within the UI
      Specified by:
      getSize in interface SizedControl
      Specified by:
      getSize in interface TextControl
      Returns:
      int control size
      See Also:
    • setSize

      public void setSize(int size)
      Description copied from interface: SizedControl
      Sets the size for the control
      Specified by:
      setSize in interface SizedControl
      Specified by:
      setSize in interface TextControl
      Parameters:
      size -
      See Also:
    • getMaxLength

      public Integer getMaxLength()
      Maximum number of characters that can be inputted.

      If not set on control, max length of field will be used

      Specified by:
      getMaxLength in interface TextControl
      Returns:
      max number of characters
    • setMaxLength

      public void setMaxLength(Integer maxLength)
      Specified by:
      setMaxLength in interface TextControl
      See Also:
    • getMinLength

      public Integer getMinLength()
      Minimum number of characters that can be inputted.

      If not set on control, min length of field will be used

      Specified by:
      getMinLength in interface TextControl
      Returns:
      max number of characters
    • setMinLength

      public void setMinLength(Integer minLength)
      Specified by:
      setMinLength in interface TextControl
      See Also:
    • getDatePicker

      public DatePicker getDatePicker()
      Renders a calendar that can be used to select a date value for the text control.
      Specified by:
      getDatePicker in interface TextControl
      Returns:
      data picker instance
    • setDatePicker

      public void setDatePicker(DatePicker datePicker)
      Specified by:
      setDatePicker in interface TextControl
      See Also:
    • isTextExpand

      public boolean isTextExpand()
      If set to true, this control will have a button which can be clicked to expand the text area through a popup window so the user has more space to type and see the data they are entering in this text field.
      Specified by:
      isTextExpand in interface TextControl
      Returns:
      boolean if control has text expand enabled, false if not
    • setTextExpand

      public void setTextExpand(boolean textExpand)
      Specified by:
      setTextExpand in interface TextControl
      See Also:
    • getWatermarkText

      public String getWatermarkText()
      Gets the watermark text for this TextControl.

      A watermark typically appears as light gray text within the text input element whenever the element is empty and does not have focus. This provides a hint to the user as to what the input is used for, or the type of input that is required.

      Specified by:
      getWatermarkText in interface TextControl
      Returns:
      the watermarkText
    • setWatermarkText

      public void setWatermarkText(String watermarkText)
      Specified by:
      setWatermarkText in interface TextControl
      See Also: