Interface IBreadcrumb

All Superinterfaces:
IAnyGroup<IBreadcrumb>, IChildable<IBreadcrumb,IBreadcrumbitem>, IComponent<IBreadcrumb>, IHtmlBasedComponent<IBreadcrumb>, IXulElement<IBreadcrumb>

Immutable Breadcrumb component.

A breadcrumb navigation. Contains an ordered list of IBreadcrumbitem.

Since:
11.0.0
Author:
peaker
See Also:
  • Breadcrumb
  • Field Details

    • DEFAULT

      static final IBreadcrumb DEFAULT
      Constant for default attributes of this immutable component.
  • Method Details

    • getWidgetClass

      default String getWidgetClass()
      Returns the client widget class.

      Default: "zul.wgt.Breadcrumb"

      Specified by:
      getWidgetClass in interface IComponent<IBreadcrumb>
    • getSeparator

      @Nullable default String getSeparator()
      Returns the separator between items, or null when it was reset to the default.

      Default: "/".

    • withSeparator

      IBreadcrumb withSeparator(@Nullable String separator)
      Returns a copy of this immutable component with the specified separator.

      Sets the separator. Also accepts icon form: "icon:z-icon-chevron-right".

      Parameters:
      separator - the separator between items, or null to reset to the default, as Breadcrumb.setSeparator(String) does.

      Default: "/".

      Returns:
      A modified copy of the this object
    • getMaxItems

      default int getMaxItems()
      Returns the maximum number of items to display before collapsing.

      Default: 0 (no limit).

    • withMaxItems

      IBreadcrumb withMaxItems(int maxItems)
      Returns a copy of this immutable component with the specified maxItems.

      Sets the maximum number of items to display before collapsing.

      Use 0 to disable collapse (default). A non-zero value must be >= 2 — the collapse always keeps the first and last item, so maxItems = 1 cannot actually hide anything and is rejected.

      Parameters:
      maxItems - the maximum number of items to display before collapsing.

      Default: 0.

      Returns:
      A modified copy of the this object
      Throws:
      org.zkoss.zk.ui.WrongValueException - if maxItems is negative or equal to 1.
    • of

      static IBreadcrumb of(Iterable<? extends IBreadcrumbitem> children)
      Returns the instance with the given IBreadcrumbitem children.
      Parameters:
      children - The children of IBreadcrumbitem
    • of

      static IBreadcrumb of(IBreadcrumbitem... children)
      Returns the instance with the given IBreadcrumbitem children.
      Parameters:
      children - The children of IBreadcrumbitem
    • ofId

      static IBreadcrumb ofId(String id)
      Returns the instance with the given id.
      Parameters:
      id - The id to identify this component