Interface IToolbarbutton

    • Field Detail

      • DEFAULT

        static final IToolbarbutton DEFAULT
        Constant for default attributes of this immutable component.
    • Method Detail

      • getWidgetClass

        default java.lang.String getWidgetClass()
        Returns the client widget class.

        Default: "zul.wgt.Toolbarbutton"

        Specified by:
        getWidgetClass in interface IComponent<IToolbarbutton>
      • getMode

        default java.lang.String getMode()
        Returns the current mode.

        Default: "default"

      • withMode

        IToolbarbutton withMode​(java.lang.String mode)
        Returns a copy of this immutable component with the specified mode.

        Sets the mode to "default" and "toggle"

        Parameters:
        mode - The mode of this component.

        Default: "default".

        Returns:
        A modified copy of the this object
      • withMode

        default IToolbarbutton withMode​(IToolbarbutton.Mode mode)
        Returns a copy of this immutable component with the specified mode.

        Sets the mode to "default" and "toggle"

        Parameters:
        mode - The mode of this component.

        Default: "default".

        Returns:
        A modified copy of the this object
      • isChecked

        default boolean isChecked()
        Returns whether it is checked.

        Default: false.

      • withChecked

        IToolbarbutton withChecked​(boolean checked)
        Returns a copy of this immutable component with the specified checked.

        Sets whether it is checked.

        Parameters:
        checked - Whether it is checked.

        Default: false.

        Returns:
        A modified copy of the this object
      • of

        static IToolbarbutton of​(java.lang.String label)
        Returns the instance with the given label.
        Parameters:
        label - The label that the component
      • of

        static IToolbarbutton of​(java.lang.String label,
                                 java.lang.String image)
        Returns the instance with the given label and image.
        Parameters:
        label - The label that the button holds.
        image - The image that the button holds.
      • ofImage

        static IToolbarbutton ofImage​(java.lang.String image)
        Returns the instance with the given image.
        Parameters:
        image - The image that the button holds.
      • ofId

        static IToolbarbutton ofId​(java.lang.String id)
        Returns the instance with the given id.
        Parameters:
        id - The id to identify this component
      • withId

        IToolbarbutton withId​(java.lang.String value)
        Copy the current immutable object by setting a value for the id attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for id
        Returns:
        A modified copy of the this object
      • withAction

        IToolbarbutton withAction​(@Nullable
                                  ActionHandler value)
        Copy the current immutable object by setting a value for the action attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for action (can be null)
        Returns:
        A modified copy of the this object
      • withActions

        IToolbarbutton withActions​(ActionHandler... elements)
        Copy the current immutable object with elements that replace the content of actions.
        Parameters:
        elements - The elements to set
        Returns:
        A modified copy of this object
      • withActions

        IToolbarbutton withActions​(java.lang.Iterable<? extends ActionHandler> elements)
        Copy the current immutable object with elements that replace the content of actions. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        elements - An iterable of actions elements to set
        Returns:
        A modified copy of this object
      • withVisible

        IToolbarbutton withVisible​(boolean value)
        Copy the current immutable object by setting a value for the visible attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for visible
        Returns:
        A modified copy of the this object
      • withMold

        IToolbarbutton withMold​(java.lang.String value)
        Copy the current immutable object by setting a value for the mold attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for mold
        Returns:
        A modified copy of the this object
      • withEventListenerMap

        IToolbarbutton withEventListenerMap​(@Nullable
                                            EventListenerMap value)
        Copy the current immutable object by setting a value for the eventListenerMap attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for eventListenerMap (can be null)
        Returns:
        A modified copy of the this object
      • withWidgetListeners

        IToolbarbutton withWidgetListeners​(java.util.Map<java.lang.String,​? extends java.lang.String> entries)
        Copy the current immutable object by replacing the widgetListeners map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the widgetListeners map
        Returns:
        A modified copy of this object
      • withWidgetOverrides

        IToolbarbutton withWidgetOverrides​(java.util.Map<java.lang.String,​? extends java.lang.String> entries)
        Copy the current immutable object by replacing the widgetOverrides map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the widgetOverrides map
        Returns:
        A modified copy of this object
      • withClientAttributes

        IToolbarbutton withClientAttributes​(java.util.Map<java.lang.String,​? extends java.lang.String> entries)
        Copy the current immutable object by replacing the clientAttributes map with the specified map. Nulls are not permitted as keys or values. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        entries - The entries to be added to the clientAttributes map
        Returns:
        A modified copy of this object
      • withLeft

        IToolbarbutton withLeft​(@Nullable
                                java.lang.String value)
        Copy the current immutable object by setting a value for the left attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for left (can be null)
        Returns:
        A modified copy of the this object
      • withTop

        IToolbarbutton withTop​(@Nullable
                               java.lang.String value)
        Copy the current immutable object by setting a value for the top attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for top (can be null)
        Returns:
        A modified copy of the this object
      • withZIndex

        IToolbarbutton withZIndex​(int value)
        Copy the current immutable object by setting a value for the zIndex attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for zIndex
        Returns:
        A modified copy of the this object
      • withHeight

        IToolbarbutton withHeight​(@Nullable
                                  java.lang.String value)
        Copy the current immutable object by setting a value for the height attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for height (can be null)
        Returns:
        A modified copy of the this object
      • withWidth

        IToolbarbutton withWidth​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the width attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for width (can be null)
        Returns:
        A modified copy of the this object
      • withTooltiptext

        IToolbarbutton withTooltiptext​(@Nullable
                                       java.lang.String value)
        Copy the current immutable object by setting a value for the tooltiptext attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for tooltiptext (can be null)
        Returns:
        A modified copy of the this object
      • withZclass

        IToolbarbutton withZclass​(@Nullable
                                  java.lang.String value)
        Copy the current immutable object by setting a value for the zclass attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for zclass (can be null)
        Returns:
        A modified copy of the this object
      • withSclass

        IToolbarbutton withSclass​(@Nullable
                                  java.lang.String value)
        Copy the current immutable object by setting a value for the sclass attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for sclass (can be null)
        Returns:
        A modified copy of the this object
      • withStyle

        IToolbarbutton withStyle​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the style attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for style (can be null)
        Returns:
        A modified copy of the this object
      • withDraggable

        IToolbarbutton withDraggable​(java.lang.String value)
        Copy the current immutable object by setting a value for the draggable attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for draggable
        Returns:
        A modified copy of the this object
      • withFocus

        IToolbarbutton withFocus​(boolean value)
        Copy the current immutable object by setting a value for the focus attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for focus
        Returns:
        A modified copy of the this object
      • withDroppable

        IToolbarbutton withDroppable​(java.lang.String value)
        Copy the current immutable object by setting a value for the droppable attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for droppable
        Returns:
        A modified copy of the this object
      • withVflex

        IToolbarbutton withVflex​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the vflex attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for vflex (can be null)
        Returns:
        A modified copy of the this object
      • withHflex

        IToolbarbutton withHflex​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the hflex attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for hflex (can be null)
        Returns:
        A modified copy of the this object
      • withRenderdefer

        IToolbarbutton withRenderdefer​(int value)
        Copy the current immutable object by setting a value for the renderdefer attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for renderdefer
        Returns:
        A modified copy of the this object
      • withClientAction

        IToolbarbutton withClientAction​(@Nullable
                                        java.lang.String value)
        Copy the current immutable object by setting a value for the clientAction attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for clientAction (can be null)
        Returns:
        A modified copy of the this object
      • withTabindex

        IToolbarbutton withTabindex​(@Nullable
                                    java.lang.Integer value)
        Copy the current immutable object by setting a value for the tabindex attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for tabindex (can be null)
        Returns:
        A modified copy of the this object
      • withCtrlKeys

        IToolbarbutton withCtrlKeys​(@Nullable
                                    java.lang.String value)
        Copy the current immutable object by setting a value for the ctrlKeys attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for ctrlKeys (can be null)
        Returns:
        A modified copy of the this object
      • withContext

        IToolbarbutton withContext​(@Nullable
                                   java.lang.String value)
        Copy the current immutable object by setting a value for the context attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for context (can be null)
        Returns:
        A modified copy of the this object
      • withPopup

        IToolbarbutton withPopup​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the popup attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for popup (can be null)
        Returns:
        A modified copy of the this object
      • withTooltip

        IToolbarbutton withTooltip​(@Nullable
                                   java.lang.String value)
        Copy the current immutable object by setting a value for the tooltip attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for tooltip (can be null)
        Returns:
        A modified copy of the this object
      • withLabel

        IToolbarbutton withLabel​(java.lang.String value)
        Copy the current immutable object by setting a value for the label attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for label
        Returns:
        A modified copy of the this object
      • withIconSclass

        IToolbarbutton withIconSclass​(@Nullable
                                      java.lang.String value)
        Copy the current immutable object by setting a value for the iconSclass attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for iconSclass (can be null)
        Returns:
        A modified copy of the this object
      • withIconSclasses

        IToolbarbutton withIconSclasses​(java.lang.String... elements)
        Copy the current immutable object with elements that replace the content of iconSclasses. The array is cloned before being saved as attribute values.
        Parameters:
        elements - The non-null elements for iconSclasses
        Returns:
        A modified copy of this object
      • withIconTooltip

        IToolbarbutton withIconTooltip​(@Nullable
                                       java.lang.String value)
        Copy the current immutable object by setting a value for the iconTooltip attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for iconTooltip (can be null)
        Returns:
        A modified copy of the this object
      • withIconTooltips

        IToolbarbutton withIconTooltips​(java.lang.String... elements)
        Copy the current immutable object with elements that replace the content of iconTooltips. The array is cloned before being saved as attribute values.
        Parameters:
        elements - The non-null elements for iconTooltips
        Returns:
        A modified copy of this object
      • withImage

        IToolbarbutton withImage​(@Nullable
                                 java.lang.String value)
        Copy the current immutable object by setting a value for the image attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for image (can be null)
        Returns:
        A modified copy of the this object
      • withHoverImage

        IToolbarbutton withHoverImage​(@Nullable
                                      java.lang.String value)
        Copy the current immutable object by setting a value for the hoverImage attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for hoverImage (can be null)
        Returns:
        A modified copy of the this object
      • withPreloadImage

        IToolbarbutton withPreloadImage​(boolean value)
        Copy the current immutable object by setting a value for the preloadImage attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for preloadImage
        Returns:
        A modified copy of the this object
      • withDir

        IToolbarbutton withDir​(java.lang.String value)
        Copy the current immutable object by setting a value for the dir attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for dir
        Returns:
        A modified copy of the this object
      • withOrient

        IToolbarbutton withOrient​(java.lang.String value)
        Copy the current immutable object by setting a value for the orient attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for orient
        Returns:
        A modified copy of the this object
      • withType

        IToolbarbutton withType​(java.lang.String value)
        Copy the current immutable object by setting a value for the type attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for type
        Returns:
        A modified copy of the this object
      • withDisabled

        IToolbarbutton withDisabled​(boolean value)
        Copy the current immutable object by setting a value for the disabled attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for disabled
        Returns:
        A modified copy of the this object
      • withAutodisable

        IToolbarbutton withAutodisable​(@Nullable
                                       java.lang.String value)
        Copy the current immutable object by setting a value for the autodisable attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for autodisable (can be null)
        Returns:
        A modified copy of the this object
      • withTarget

        IToolbarbutton withTarget​(@Nullable
                                  java.lang.String value)
        Copy the current immutable object by setting a value for the target attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for target (can be null)
        Returns:
        A modified copy of the this object
      • withUpload

        IToolbarbutton withUpload​(@Nullable
                                  java.lang.String value)
        Copy the current immutable object by setting a value for the upload attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for upload (can be null)
        Returns:
        A modified copy of the this object
      • withHref

        IToolbarbutton withHref​(@Nullable
                                java.lang.String value)
        Copy the current immutable object by setting a value for the href attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for href (can be null)
        Returns:
        A modified copy of the this object
      • withWidgetClass

        IToolbarbutton withWidgetClass​(java.lang.String value)
        Copy the current immutable object by setting a value for the widgetClass attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for widgetClass
        Returns:
        A modified copy of the this object