code: public final LogBuffer limit(int newLimit) {
          if (origin + newLimit > buffer.length || newLimit < 0) throw new IllegalArgumentException("capacity excceed: "
                                                                                                    + (origin + newLimit));
  
          limit = newLimit;
          return this;
      }
docs: Sets this buffer's limit. If the position is larger than the new limit
  then it is set to the new limit. If the mark is defined and larger than
  the new limit then it is discarded. </p>
  
  @param newLimit The new limit value; must be non-negative and no larger
  than this buffer's capacity
  @return This buffer
  @throws IllegalArgumentException If the preconditions on
  <tt>newLimit</tt> do not hold