code: void update(@NonNull List<PageEntry> entries) {
          if (entries.isEmpty()) {
              // Nothing to do.
              return;
          }
  
          // Apply the in-place updates and collect the new entries to be added.
          val ci = applyUpdates(entries);
          if (ci.changes.isEmpty()) {
              // Nothing else to change. We've already updated the keys in-place.
              return;
          }
  
          val newPage = applyInsertsAndRemovals(ci);
  
          // Make sure we swap all the segments with those from the new page. We need to release all pointers to our
          // existing buffers.
          this.header = newPage.header;
          this.data = newPage.data;
          this.contents = newPage.contents;
          this.footer = newPage.footer;
          this.count = newPage.count;
      }
docs: Updates the contents of this BTreePage with the given entries. Entries whose keys already exist will update the data,
  while Entries whose keys do not already exist will be inserted.
  
  After this method completes, this BTreePage:
  * May overflow (a split may be necessary)
  * Will have all entries sorted by Key
  
  @param entries The Entries to insert or update. This List must be sorted by {@link PageEntry#getKey()}.
  @throws IllegalDataFormatException If any of the entries do not conform to the Key/Value size constraints.
  @throws IllegalArgumentException   If the entries are not sorted by {@link PageEntry#getKey()}.