Interface WebeditStatusNoteBuilder


@NonExtendable public interface WebeditStatusNoteBuilder
Builder for a WebeditStatusNote.
 WebeditStatusNote note = context
     .createNote()
     .title("Translation missing")
     .text("This page is not translated yet.")
     .icon(context.requireSpecialist(ImageAgent.TYPE).getImageFromUrl("module/translate.png"))
     .color(WebeditColor.VANILLA)
     .visibleOnLoad(true)
     .addItem(new TranslateActionItem())
     .create();
 
Since:
5.2.516
See Also:
  • Method Details

    • color

      @NotNull @NotNull WebeditStatusNoteBuilder color(@Nullable @Nullable WebeditColor color)
      Sets the color associated with the status note to create.
      Parameters:
      color - The color of the status information, or null.
      Returns:
      This builder instance.
      Since:
      5.2.516
    • icon

      @NotNull @NotNull WebeditStatusNoteBuilder icon(@Nullable @Nullable Image<?> icon)
      Sets the icon associated with the status note to create. Use ImageAgent to create an Image instance.
      Parameters:
      icon - The icon of the status information, or null.
      Returns:
      This builder instance.
      Since:
      5.2.516
    • title

      @NotNull @NotNull WebeditStatusNoteBuilder title(@NotNull @NotNull String title)
      Sets the title of the status note to create.
      Parameters:
      title - The title of the status information.
      Returns:
      This builder instance.
      Since:
      5.2.516
    • text

      @NotNull @NotNull WebeditStatusNoteBuilder text(@Nullable @Nullable String text)
      Sets the text of the status note to create.
      Parameters:
      text - The text of the status information, or null.
      Returns:
      This builder instance.
      Since:
      5.2.516
    • visibleOnLoad

      @NotNull @NotNull WebeditStatusNoteBuilder visibleOnLoad(boolean visibleOnLoad)
      Sets the initial visibility of the status note after the preview has been loaded. By default the status note will not be visible on preview load.
      Parameters:
      visibleOnLoad - The initial visibility of the status information.
      Returns:
      This builder instance.
      Since:
      5.2.516
    • addItem

      @NotNull @NotNull WebeditStatusNoteBuilder addItem(@NotNull @NotNull WebeditStatusNoteItem item)
      Adds a item eligible for display in the status note's contextual setting. Actions specified here will be displayed in the status note's UI.
      Parameters:
      item - The item to be added
      Returns:
      This builder instance.
      Since:
      5.2.516
    • setItems

      @NotNull @NotNull WebeditStatusNoteBuilder setItems(@NotNull @NotNull Collection<? extends WebeditStatusNoteItem> items)
      Sets the items eligible for display in the status note's contextual setting. Actions specified here will be displayed in the status note's UI.
      Parameters:
      items - The items to be set
      Returns:
      This builder instance.
      Since:
      5.2.516
    • create

      @NotNull @NotNull WebeditStatusNote create()
      Creates a new WebeditStatusNote based on the previously configured settings.
      Returns:
      The new WebeditStatusNote instance.
      Since:
      5.2.516