code: @Override
      @LogarithmicTime(amortized = true)
      public Handle<K, V> insert(K key, V value) {
          if (Constants.NOT_BENCHMARK) {
              if (key == null) {
                  throw new NullPointerException("Null keys not permitted");
              }
              // make sure there is space
              if (size == array.length - 1) {
                  if (array.length == 1) {
                      ensureCapacity(1);
                  } else {
                      ensureCapacity(2 * (array.length - 1));
                  }
              }
          }
  
          ArrayHandle p = new ArrayHandle(key, value);
          size++;
          array[size] = p;
          p.index = size;
  
          if (comparator == null) {
              fixup(size);
          } else {
              fixupWithComparator(size);
          }
  
          return p;
      }
docs: {@inheritDoc}