code: public RingbufferConfig setInMemoryFormat(InMemoryFormat inMemoryFormat) {
          checkNotNull(inMemoryFormat, "inMemoryFormat can't be null");
          checkFalse(inMemoryFormat == NATIVE, "InMemoryFormat " + NATIVE + " is not supported");
          this.inMemoryFormat = inMemoryFormat;
          return this;
      }
docs: Sets the in-memory format.
  <p>
  The in-memory format controls the format of the stored item in the
  ringbuffer:
  <ol>
  <li>{@link InMemoryFormat#OBJECT}: the item is stored in deserialized
  format (a regular object)</li>
  <li>{@link InMemoryFormat#BINARY}: the item is stored in serialized format
  (a binary blob) </li>
  </ol>
  <p>
  The default is binary. The object InMemoryFormat is useful when:
  <ol>
  <li>the object stored in object format has a smaller footprint than in
  binary format</li>
  <li>if there are readers using a filter. Since for every filter
  invocation, the object needs to be available in object format.</li>
  </ol>
  
  @param inMemoryFormat the new in memory format
  @return the updated Config
  @throws NullPointerException     if inMemoryFormat is {@code null}
  @throws IllegalArgumentException if {@link InMemoryFormat#NATIVE} in-memory
  format is selected