code: public ItemsSketch<T> getResult() {
      if (gadget_ == null) {
        return ItemsSketch.getInstance(maxK_, comparator_);
      }
      return ItemsSketch.copy(gadget_); //can't have any externally owned handles.
    }
docs: Gets the result of this Union operation as a copy of the internal state.
  This enables further union update operations on this state.
  @return the result of this Union operation