Class AbstractDiffRequest.AbstractBuilder<B extends AbstractDiffRequest.AbstractBuilder<B,R>,R>

java.lang.Object
com.atlassian.bitbucket.util.BuilderSupport
com.atlassian.bitbucket.content.AbstractDiffRequest.AbstractBuilder<B,R>
Direct Known Subclasses:
CompareDiffRequest.Builder, DiffRequest.Builder
Enclosing class:
AbstractDiffRequest

protected abstract static class AbstractDiffRequest.AbstractBuilder<B extends AbstractDiffRequest.AbstractBuilder<B,R>,R> extends BuilderSupport
  • Constructor Details

    • AbstractBuilder

      protected AbstractBuilder()
    • AbstractBuilder

      protected AbstractBuilder(@Nonnull AbstractDiffRequest request)
  • Method Details

    • build

      @Nonnull public abstract R build()
    • contextLines

      @Nonnull public B contextLines(int value)
      Specifies the number of context lines to include around added/removed lines. 0 and positive values are treated as the number of lines to request. Any negative value is treated as a request for the system-configured default number of lines.

      When requesting the default number of context lines, it is encouraged to use AbstractDiffRequest.DEFAULT_CONTEXT_LINES for clarity: contextLines(DiffRequest.DEFAULT_CONTEXT_LINES).

      Parameters:
      value - the number of context lines to include around added and removed lines in the diff, which may be AbstractDiffRequest.DEFAULT_CONTEXT_LINES to use the default number
      Returns:
      this
    • filter

      @Nonnull public B filter(@Nullable DiffContentFilter value)
    • path

      @Nonnull public B path(@Nullable String value)
    • paths

      @Nonnull public B paths(@Nullable Iterable<String> values)
    • paths

      @Nonnull public B paths(@Nullable String value, @Nullable String... values)
    • whitespace

      @Nonnull public B whitespace(@Nonnull DiffWhitespace value)
    • self

      @Nonnull protected abstract B self()