PHPackages                             localheinz/token - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. localheinz/token

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

localheinz/token
================

Provides a simple abstraction for a token and a sequence of tokens.

0.2.2(8y ago)3195MITPHPPHP ^7.0

Since Oct 3Pushed 6y ago1 watchersCompare

[ Source](https://github.com/localheinz/token)[ Packagist](https://packagist.org/packages/localheinz/token)[ RSS](/packages/localheinz-token/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (4)Dependencies (5)Versions (8)Used By (0)

token
=====

[](#token)

[![CI Status](https://github.com/localheinz/token/workflows/Continuous%20Integration/badge.svg)](https://github.com/localheinz/token/actions)[![codecov](https://camo.githubusercontent.com/fd6cc423ec24bc38bedce052f79a1e14462d53889d88d866d866192f0d8b7bee/68747470733a2f2f636f6465636f762e696f2f67682f6c6f63616c6865696e7a2f746f6b656e2f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://codecov.io/gh/localheinz/token)[![Latest Stable Version](https://camo.githubusercontent.com/c2932107c782bedc8db7d6e1082054fd2924ca7c25dfcb7c4d103dd6dae067a6/68747470733a2f2f706f7365722e707567782e6f72672f6c6f63616c6865696e7a2f746f6b656e2f762f737461626c65)](https://packagist.org/packages/localheinz/token)[![Total Downloads](https://camo.githubusercontent.com/dcd1108bb5b68cab5e7eda1fc53d7784689b4eac609459ac051374f45f55d695/68747470733a2f2f706f7365722e707567782e6f72672f6c6f63616c6865696e7a2f746f6b656e2f646f776e6c6f616473)](https://packagist.org/packages/localheinz/token)

Provides a simple read-only abstraction for a token and a sequence of tokens, inspired by [`friendsofphp/php-cs-fixer`](http://github.com/FriendsOfPHP/PHP-CS-Fixer).

Installation
------------

[](#installation)

Run

```
$ composer require localheinz/token

```

Usage
-----

[](#usage)

### Sequence of tokens

[](#sequence-of-tokens)

Create a sequence of tokens from source code:

```
use Localheinz\Token\Sequence;

$source =
