nhalstead / incrementor
dev-master
2020-04-27 04:03 UTC
Requires
- ext-json: *
- tightenco/collect: ^6.11
Requires (Dev)
- phpunit/phpunit: ^9.1
This package is auto-updated.
Last update: 2025-04-27 15:17:47 UTC
README
Generate String from a template in bulk. This can be used to generate
How to use
Basic & Fast Usage of the library:
<?php use \nhalstead\Incrementor\Incrementor; // Using the Get Method you can get a collection of the output. $generated = Incrementor::get('TEST_{0000^}', 10); var_dump($generated); // object(Tightenco\Collect\Support\Collection)#4 (1) { // ["items":protected]=> // array(10) { // [0]=> // string(9) "TEST_0000" // [1]=> // string(9) "TEST_0001" // [2]=> // string(9) "TEST_0002" // [3]=> // string(9) "TEST_0003" // [4]=> // string(9) "TEST_0004" // [5]=> // string(9) "TEST_0005" // [6]=> // string(9) "TEST_0006" // [7]=> // string(9) "TEST_0007" // [8]=> // string(9) "TEST_0008" // [9]=> // string(9) "TEST_0009" // } // } ?>