Increment the build number.

@param null $by

@return int

@internal param null $increment
322271
public function incrementBuild($by = null)
    {
        return $this->increment(function ($config) use ($by) {
            $increment_by = $by ?: $config['build']['increment_by'];

            $config['build']['number'] =
                $config['build']['number'] + $increment_by;

            return $config;
        }, 'build.number');
    }
270527
public function skip($by = 1)
    {
        $i = 0;
        while($this->cursor->valid() && $i < $by) {
            $this->cursor->next();
            $i++;
        }
        return $this;
    }
331278
public function incrementMajor($amount = 1)
    {
        $this->major += $amount;
        $this->minor = 0;
        $this->patch = 0;

        return $this;
    }
257584
public function setNumber($number = null)
    {
        $this->number = null !== $number ? floatval($number) : null;

        return $this;
    }
598075
public function increment($increment = null, $value = null)
    {
        if(!isset($this->options['increment']))  $this->options['increment'] = array();

        if(is_string($increment) && is_numeric($value))
            $this->options['increment'][$increment] = $value;
        elseif(is_array($increment) && is_null($value))
            foreach($increment as $k => $v)
                if(is_string($k) && is_numeric($v))
                    $this->options['increment'][$k] = $v;
        return $this;
    }
945164
public function increment($key, $value = 1)
    {
        $val = (int) $this->get($key) + $value;
        return $this->put($key, $val) ? $val : false;
    }
188538
public function increment($key, $value = 1)
    {
        return $this->incrementOrDecrement($key, $value, function ($current, $value) {
            return $current + $value;
        });
    }
491388
public function incr($key, $increment = 1) {
        if ($increment === 1) {
            return $this->send(['incr', $key]);
        }

        return $this->send(['incrby', $key, $increment]);
    }
811089
public function count(): ?int
    {
        $result = $this->builderOnCount(
            $this->createCountBuilderFromBuilder($this->createIndexModelBuilder())
        )->execute()->fetchColumn();

        return $result === false ? null : (int)$result;
    }
622985
public static function incrementStep()
    {
        if (self::isLastStep()) {
            return;
        }
        $next = self::classNameNumber() + 1;
        if ($next == 1) {
            $next++;
        }
        return self::setCurrentStep($next);
    }
843808
public function increment(string $field, int $howMuch = 1): Update
    {
        return $this->set($field, new Expr("{$field} + {$howMuch}"));
    }
340902
public function incrBy($key, $increment) {
        return $this->getHandler($this->judge(__FUNCTION__))->incrBy($key, $increment);
    }
1163325
public function increment($column, $amount = 1, array $extra = [])
    {
        $result = $this->getBuilder()->increment($column, $amount, $extra);

        // Reset query builder
        $this->resetBuilder();

        return (int) $result;
    }
340878
public function build_sql( $data = null ) {

		if ( ! empty( $data ) ) {
			$this->set_data( $data );
		}

		$this->built = $data;

		return $this->built;
	}
1333569
public function setTotal($total) {
		if ($total instanceof Builder) {
			$this->_total = intval($total->count());
			return $this;
		}
		$this->_total = intval($total);
		return $this;
	}
1194527
public function increment($byAmount = 1) {
		if ($this->name === null) {
			throw new InvalidConfigException(get_class($this)." requires a name!");
		}
		return $this->_value = (int) $this->getConnection()->getClient()->incrBy($this->name,$byAmount);
	}
1304343
public function getMigrationSql($version, $increment)
    {
        // I could use the GLOB_BRACE but it is not supported on ALPINE distros.
        // So, I have to call multiple times to simulate the braces.

        if (intval($version) != $version) {
            throw new \InvalidArgumentException("Version '$version' should be a integer number");
        }
        $version = intval($version);

        $filePattern = $this->folder
            . "/migrations"
            . "/" . ($increment < 0 ? "down" : "up")
            . "/*.sql";

        $result = array_filter(glob($filePattern), function ($file) use ($version) {
            return preg_match("/^0*$version(-dev)?\.sql$/", basename($file));
        });

        // Valid values are 0 or 1
        if (count($result) > 1) {
            throw new InvalidMigrationFile("You have two files with the same version number '$version'");
        }

        foreach ($result as $file) {
            if (intval(basename($file)) === $version) {
                return $file;
            }
        }
        return null;
    }