Download the PHP package std/lib without Composer

On this page you can find all versions of the php package std/lib. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package lib

std/lib: unofficial new std runtime kit

std-lib is a type-safe collection of helper utilities and safe implementations of several php “core” functions.

For more about the guarantees of std/lib, see the stdlib website.

This library is currently on hold undergoing very basic QA. It should be generally available by the end of September 2019.

Methods Provided:

Std\Str functions

Str is the standard name for the UTF-8 ready string utilities.

Std\Arr functions

Arr is the standard name for array utilities (due to Array being reserved).

\Std\Arr::callRecursive(array $array, callable $method)
\Std\Arr::arrayUniqueRecursive(array $array)
\Std\Arr::keyWalk(array $inputArray, callable $fn)
\Std\Arr::count($array) : array

​ Counts the value or throws an exception.

\Std\Arr::countAny($arrayOrOther): int

​ Accepts any value, not just countables, returning zero for non-countables and throwing no exception.

\Std\Arr::getColumn($array)

​ Same as array_column, but preserves keys and additional type-checks. ​ If the key (column) does not exist within the sub-element, a Array\MissingKeyException is thrown. ​ If any of the sub-elements are not arrays, a Array\UnexpectedElementException is thrown.

\Std\Arr::pileByColumn(array $inputArray, string $column) : array`

Returns a newly structured array with an additional dimension added, so that the input array

If "piled" by the column "id", would become:

\Std\Arr::rekeyByColumn(array[] $inputArray, string $columnName): array`

​ Assuming each element of $inputArray is an array, and within it a sub-element with key $columnName with a valid key as the value, re-keys the array using that value.

​ If the values of these values are not unique, an LossyOperationException exception will be thrown.
​ If any of elements aren't an array, a Array\MissingKeyException or Array\UnexpectedElementException is thrown.

\Std\Arr::rekeyByColumnLossy(array[] $inputArray, string $columnName) : array

​ See \Std\Arr::rekeyByColumn, however this allows losses during conversion.

\Std\Arr::columnPopLeft(array[] $inputArray) : array

​ Pops the "left" or "top" (first-most, or lowest-indexed) element off of each sub-array element, returning an array of these values.
​ If any element contains zero elements, NULL is returned in it's place.
​ If it is any other type than array, Array\UnexpectedElementException is thrown.

\Std\Arr::columnPopLeft(array[] $inputArray) : array Pops the "right" or "bottom" most element off each sub-array element.

Undocumented
\Std\Arr::columnRecursive(Iterable $haystack, ...$subKey)
\Std\Arr::columnSearch(Iterable $haystack, $needle)
\Std\Arr::columnSearchRecursive(Iterable $haystack, $needle)
\Std\Arr::combineWith($value, $keyKey, $valueKey, $keyInsensitive = false)
\Std\Arr::idiff($x, $y)

​ Effectively: array_unique(array_merge(array_intersect($x, $y), array_intersect($y, $x)));

\Std\Arr::keyEach($array, $callback)
\Std\Arr::mapReduce(callable $mapReduceFn, ... $values)
\Std\Arr::merge(array $array1, array $array2 = null, array $_ = null)
\Std\Arr::multisort(array $arr, $arg = null, $arg = null, $_ = null)
\Std\Arr::popLeft(array $array)
\Std\Arr::popRight(array $array)
\Std\Arr::push(array $array, ...$vars)
\Std\Arr::reduce_j(callable $reduceFn, $values)
\Std\Arr::search($needle, array $haystack, $strict = null)
\Std\Arr::shift(array $array)
\Std\Arr::slice(array $array, $offset, $length = null)

​ See Also: Std\List::slice(array $array, $offset, $length = null)

\Std\Arr::splice(array $input, $offset, $length = null, $replacement = null)
\Std\Arr::unshift(array $array, ...$vars)
\Std\Arr::walk(array $array, $funcname, $userdata = null)
\Std\Arr::walkRecursive(array $input, $funcname, $userdata = null)
\Std\Arr::trim($array)

Exceptions

Std\Introspect

Introspection and internals functions

Introspect::getCallableName($callable)

All versions of lib with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package std/lib contains the following files

Loading the files please wait ....