Grows the map size after an insertion. If necessary, performs a rehash of the map.
432515
private void growSize() {
		size++;

		if (size > maxSize) {
			if (keys.length == Integer.MAX_VALUE) {
				throw new IllegalStateException("Max capacity reached at size=" + size);
			}

			// Double the capacity.
			rehash(keys.length << 1);
		}
	}
206739
protected void checkMapSize()
  {
    if ((map instanceof EmbeddedSlotMap) && map.size() >= LARGE_HASH_SIZE) {
      SlotMap newMap = new HashSlotMap();
      for (Slot s : map) {
        newMap.addSlot(s);
      }
      map = newMap;
    }
  }
156737
@Override
    protected void grow()
    {
        int newSize = newSize();
        ring = (double[]) newArray(ring, size, new double[newSize]);
        size = newSize;
    }
608474
public void append(Map<?, ?> map) {
		if (map == null || map.size() == 0)
			return;

		for (Map.Entry<?, ?> entry : map.entrySet()) {
			String key = StringConverter.toString(entry.getKey());
			Object value = entry.getValue();
			super.put(key, value);
		}
	}
1214207
@Override
  protected final void increaseNewListSize() throws IOException {
    // register old situation
    int tmpOldSize = newKeyList.length;
    int tmpNewPosition = newPosition;
    // increase
    super.increaseNewListSize();
    // reconstruct
    T1[] tmpNewAdvancedValueSumList = newAdvancedValueSumList;
    T2[] tmpNewAdvancedValueSumOfLogsList = newAdvancedValueSumOfLogsList;
    T1[] tmpNewAdvancedValueSumOfSquaresList = newAdvancedValueSumOfSquaresList;
    T1[] tmpNewAdvancedValueMinList = newAdvancedValueMinList;
    T1[] tmpNewAdvancedValueMaxList = newAdvancedValueMaxList;
    long[] tmpNewAdvancedValueNList = newAdvancedValueNList;
    newAdvancedValueSumList = operations.createVector1(newSize);
    newAdvancedValueSumOfLogsList = operations.createVector2(newSize);
    newAdvancedValueSumOfSquaresList = operations.createVector1(newSize);
    newAdvancedValueMinList = operations.createVector1(newSize);
    newAdvancedValueMaxList = operations.createVector1(newSize);
    newAdvancedValueNList = new long[newSize];
    newPosition = tmpNewPosition;
    System.arraycopy(tmpNewAdvancedValueSumList, 0, newAdvancedValueSumList, 0,
        tmpOldSize);
    System.arraycopy(tmpNewAdvancedValueSumOfLogsList, 0,
        newAdvancedValueSumOfLogsList, 0, tmpOldSize);
    System.arraycopy(tmpNewAdvancedValueSumOfSquaresList, 0,
        newAdvancedValueSumOfSquaresList, 0, tmpOldSize);
    System.arraycopy(tmpNewAdvancedValueMinList, 0, newAdvancedValueMinList, 0,
        tmpOldSize);
    System.arraycopy(tmpNewAdvancedValueMaxList, 0, newAdvancedValueMaxList, 0,
        tmpOldSize);
    System.arraycopy(tmpNewAdvancedValueNList, 0, newAdvancedValueNList, 0,
        tmpOldSize);
  }
1107965
private void updateScaleList() {
		refreshPixelLength(); /* retrieve pixelLength from mapWidget. Needed in case mapWidget wasn't fully initialized
					the previous time the pixelLength was requested */

		// Update lookup map (stores user friendly representation):
		valueToScale.clear();
		if (!Double.isNaN(pixelLength) && (0.0 != pixelLength)) {
			for (Double scale : scaleList) {
				// Eliminate duplicates and null:
				if (scale != null) {
					String value = ScaleConverter.scaleToString(scale, precision, significantDigits);
					valueToScale.put(value, scale);
				}
			}

			List<String> availableScales = new ArrayList<String>();

			for (Double scale : scaleList) {
				if (mapView.isResolutionAvailable(pixelLength / scale)) {
					availableScales.add(ScaleConverter.scaleToString(scale, precision, significantDigits));
				}
			}

			scaleItem.setValueMap(availableScales.toArray(new String[availableScales.size()]));

			isScaleItemInitialized = true;
		}
	}
236101
public void putMemorySize(String key, MemorySize size) {
		checkNotNull(key);
		checkNotNull(size);
		put(key, size.toString());
	}
351582
private void growReservoir() {
    currItemsAlloc_ = SamplingUtil.getAdjustedSize(reservoirSize_, currItemsAlloc_ << rf_.lg());
    data_.ensureCapacity(currItemsAlloc_);
  }
135920
private void grow() {
    int newCapacity = buf.length + (buf.length >> 1);
    if (newCapacity - (Integer.MAX_VALUE - 8) > 0) {
      newCapacity = Integer.MAX_VALUE - 8;
    }
    buf = Arrays.copyOf(buf, newCapacity);
    this.limit = newCapacity;
  }
90830
private void growToSize (int minCapacity) {
		if (minCapacity < 0) // overflow
			throw new GdxRuntimeException("Capacity upper limit exceeded.");
		int oldCapacity = queue.length;
		// Double size if small; else grow by 50%
		int newCapacity = (int)((oldCapacity < 64) ? ((oldCapacity + 1) * CAPACITY_RATIO_HI) : (oldCapacity * CAPACITY_RATIO_LOW));
		if (newCapacity < 0) // overflow
			newCapacity = Integer.MAX_VALUE;
		if (newCapacity < minCapacity) newCapacity = minCapacity;
		Object[] newQueue = new Object[newCapacity];
		System.arraycopy(queue, 0, newQueue, 0, size);
		queue = newQueue;
	}
50664
public void updateSizes(@ProgressDrawableSize int size) {
        if (size == LARGE) {
            setSizeParameters(CIRCLE_DIAMETER_LARGE, CIRCLE_DIAMETER_LARGE, CENTER_RADIUS_LARGE,
                    STROKE_WIDTH_LARGE, ARROW_WIDTH_LARGE, ARROW_HEIGHT_LARGE);
        } else {
            setSizeParameters(CIRCLE_DIAMETER, CIRCLE_DIAMETER, CENTER_RADIUS, STROKE_WIDTH,
                    ARROW_WIDTH, ARROW_HEIGHT);
        }
    }
454924
public void append(Map<?, ?> map) {
		if (map == null || map.size() == 0)
			return;

		for (Map.Entry<?, ?> entry : map.entrySet()) {
			put(StringConverter.toString(entry.getKey()), StringConverter.toNullableString(entry.getValue()));
		}
	}
767513
public final void increaseReadBufferSize() {
        if (AbstractIoSessionConfig.ENABLE_BUFFER_SIZE) {
            System.out.println("AbstractIoSession.increaseReadBufferSize()");
            int newReadBufferSize = getConfig().getReadBufferSize() << 1;
            if (newReadBufferSize <= getConfig().getMaxReadBufferSize()) {
                getConfig().setReadBufferSize(newReadBufferSize);
            } else {
                getConfig().setReadBufferSize(getConfig().getMaxReadBufferSize());
            }
        }

        deferDecreaseReadBuffer = true;
    }
1116368
def extend(self, data, size):
        
        return lib.zchunk_extend(self._as_parameter_, data, size)
968897
protected void rehash(int newCapacity)
  {
    HashIntSet rehashed = new HashIntSet(newCapacity);
    @SuppressWarnings("hiding")
    int[] cells = rehashed.cells;
    for (int element : this.cells) {
      if (element < 0)
      // removed or empty
      {
        continue;
      }

      // add the element
      cells[-(rehashed.findElementOrEmpty(element) + 1)] = element;
    }
    this.cells = cells;
    freecells = newCapacity - size;
    modCount++;
  }
47909
protected final void resize(int requiredSize) {
    // Double until 64, then increase by 50% each time.
    int newCapacity = ((queue.length < 64) ? ((queue.length + 1) << 1) : ((queue.length >> 1) + queue.length));
    // overflow?
    if(newCapacity < 0) {
      throw new OutOfMemoryError();
    }
    if(requiredSize > newCapacity) {
      newCapacity = requiredSize;
    }
    queue = Arrays.copyOf(queue, newCapacity);
  }
1112572
private void resize(int newCapacity) {
        // assert (newCapacity & -newCapacity) == newCapacity; // power of 2
        int newLength = newCapacity * 2;

        long[] oldTable = table;
        int oldLength = oldTable.length;
        if (oldLength == 2*MAXIMUM_CAPACITY) { // can't expand any further
            if (threshold == MAXIMUM_CAPACITY-1)
                throw new IllegalStateException("Capacity exhausted.");
            threshold = MAXIMUM_CAPACITY-1;  // Gigantic map!
            return;
        }
        if (oldLength >= newLength)
            return;

        long[] newTable = new long[newLength];
        threshold = (newCapacity * 3) / 4;

        for (int j = 0; j < oldLength; j += 2) {
            long key = oldTable[j];
            if (key != 0) {
                long value = oldTable[j+1];
                int i = hash(key, newLength);
                while (newTable[i] != 0)
                    i = nextKeyIndex(i, newLength);
                newTable[i] = key;
                newTable[i + 1] = value;
            }
        }
        table = newTable;
    }