function createOrUpdate(minX, maxX, minY, maxY, tileRange) {
  if (tileRange !== undefined) {
    tileRange.minX = minX;
    tileRange.maxX = maxX;
    tileRange.minY = minY;
    tileRange.maxY = maxY;
    return tileRange;
  }
  return new TileRange(minX, maxX, minY, maxY);
}
@param {number} minX Minimum X.
@param {number} maxX Maximum X.
@param {number} minY Minimum Y.
@param {number} maxY Maximum Y.
@param {TileRange} [tileRange] TileRange.
@return {TileRange} Tile range.