Class RenderContext.Builder

java.lang.Object
com.atlassian.bitbucket.markup.RenderContext.Builder
Enclosing class:
RenderContext

public static class RenderContext.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
    • Builder

      public Builder(@Nonnull RenderContext context)
  • Method Details

    • build

      @Nonnull public RenderContext build()
      Returns:
      the built context
    • clearData

      @Nonnull public RenderContext.Builder clearData()
      Clears any provided data.
      Returns:
      this
    • data

      @Nonnull public RenderContext.Builder data(@Nonnull Map<String,Object> value)
      Parameters:
      value - a map containing additional data to make available when rendering, which is appended to any existing data
      Returns:
      this
    • hardwrap

      @Nonnull public RenderContext.Builder hardwrap(boolean value)
      Parameters:
      value - true to convert newlines to breaks; otherwise, false to leave them intact
      Returns:
      this
    • hardwrap

      @Nonnull public RenderContext.Builder hardwrap(@Nullable Boolean value)
      Parameters:
      value - TRUE to convert newlines to breaks; FALSE to leave them intact; or null to use the system-configured default
      Returns:
      this
      Since:
      5.11
    • htmlEscape

      @Nonnull public RenderContext.Builder htmlEscape(boolean value)
      Parameters:
      value - true if HTML should be escaped in the input markup; otherwise, false to retain HTML
      Returns:
      this
    • htmlEscape

      @Nonnull public RenderContext.Builder htmlEscape(Boolean value)
      Parameters:
      value - TRUE if HTML should be escaped in the input markup; FALSE to retain HTML; or null to use the system-configured default
      Returns:
      this
      Since:
      5.11
    • includeHeadingId

      @Nonnull public RenderContext.Builder includeHeadingId(boolean value)
      Parameters:
      value - true if an ID should be added for each rendered header rendered; otherwise, false to render headers without IDs
      Returns:
      this
      Since:
      5.11
    • includeHeadingId

      @Nonnull public RenderContext.Builder includeHeadingId(Boolean value)
      Parameters:
      value - TRUE if an ID should be added for each rendered header rendered; FALSE to render headers without IDs; or null to use the system-configured default
      Returns:
      this
      Since:
      5.11
    • urlMode

      @Nonnull public RenderContext.Builder urlMode(@Nonnull UrlMode value)
      Parameters:
      value - the mode to use when rendering URLs
      Returns:
      this