Download the PHP package braincrafted/expexp without Composer

On this page you can find all versions of the php package braincrafted/expexp. 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 expexp

ExpExp

ExpExp expands expressions. That's kinda the opposite of what regular expressions do.

For example ab(cd|[xy]) expands to

Build Status Scrutinizer Quality Score Code Coverage

Author

Features

The following expressions can be expanded by the library:

Disjunction:

abc[xyz]

will be expanded to

Named character classes:

Instead of listing all disjunct characters, you can also select from a set of available character classes:

You can use named character classes by wrapping them in colons:

[:upper:]

Dot Operator:

abc.

will be expanded to

The Dot opterator does not expand to every character, but only to A-Za-z0-9_.

Parantheses:

ab(c)

will be expanded to

Repetition:

The repetition operator allows to repeat the previous character(s). If only one value is given the previous character is repeated that often, if two values are given the character is multiplied with each value in the given range. {,3} is the same as {0,3}.

a{3}

will expand to

Or with a minimum and a maximum value:

a{1,3}

will expand to

This also works with disjunctions and parentheses.

Alternation:

abc|xyz

will be expanded to

Optional:

abc?

will be expanded to

This also works with parantheses:

abc(xyz)?

will be expanded to

The optional operator has thus the same effect as {0,1}.

More examples

Pattern Count Expansion
abc 1 abc
ab(c) 1 abc
[abc] 3 a, b, c
a{3} 1 aaa
a{} 1 a
a{1,3} 3 a, aa, aaa
a{,3} 4 , a, aa, aaa
a(bc){2} 1 abcbc
a(bc){1,2} 2 abcbc, abc
a(bc){,2} 3 a, abc, abcbc
[ab]{2} 2 aa, bb
ab. 63 abA, abB, aba, ab0, ab_, ...
abc|xyz 2 abc, xyz
a|b|c 3 a, b, c
ab(c|d) 2 abc, abd
ab(cde|[xyz]) 4 abcde, abx, aby, abz
abc? 2 abc, ab
abc(xyz)? 2 abc, abcxyz

Usage

Instantiate the object and call the expand() method with the pattern:

use Bc\ExpExp\ExpExp;

$e = new ExpExp();
$result = $e->expand('abc|xyz');

More examples can be found in the test cases.

Changelog

Version 0.2.2 (2013-10-20)

Version 0.2.1 (2013-10-19)

Version 0.2 (2013-10-19)

Version 0.1.1 (2013-10-16)

Version 0.1 (2013-10-16)

License

ExpExp is licensed under The MIT License. See the LICENSE file in the projects root directory for more information.

Bitdeli Badge


All versions of expexp 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 braincrafted/expexp contains the following files

Loading the files please wait ....