Skip to content

Commit ea176b5

Browse files
[4.x] Update README to reflect start method rename to make
1 parent 03991bf commit ea176b5

1 file changed

Lines changed: 9 additions & 9 deletions

File tree

README.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -38,17 +38,17 @@ Or manually update `require-dev` block of `composer.json` and run `composer upda
3838
```php
3939
use DragonCode\Benchmark\Benchmark;
4040

41-
Benchmark::start()->compare(
41+
Benchmark::make()->compare(
4242
fn () => /* some code */,
4343
fn () => /* some code */,
4444
);
4545

46-
Benchmark::start()->compare([
46+
Benchmark::make()->compare([
4747
fn () => /* some code */,
4848
fn () => /* some code */,
4949
]);
5050

51-
Benchmark::start()->compare([
51+
Benchmark::make()->compare([
5252
'foo' => fn () => /* some code */,
5353
'bar' => fn () => /* some code */,
5454
]);
@@ -94,7 +94,7 @@ the `iterations` method:
9494
```php
9595
use DragonCode\Benchmark\Benchmark;
9696

97-
Benchmark::start()
97+
Benchmark::make()
9898
->iterations(5)
9999
->compare(
100100
fn () => /* some code */,
@@ -128,7 +128,7 @@ You can also get the number of the current execution iteration from the input pa
128128
```php
129129
use DragonCode\Benchmark\Benchmark;
130130

131-
Benchmark::start()
131+
Benchmark::make()
132132
->iterations(5)
133133
->compare(
134134
fn (int $iteration) => /* some code */,
@@ -146,7 +146,7 @@ For example:
146146
```php
147147
use DragonCode\Benchmark\Benchmark;
148148

149-
Benchmark::start()
149+
Benchmark::make()
150150
->iterations(5)
151151
->round(2)
152152
->compare(
@@ -185,7 +185,7 @@ There is a `prepare` method for this:
185185
```php
186186
use DragonCode\Benchmark\Benchmark;
187187

188-
Benchmark::start()
188+
Benchmark::make()
189189
->prepare(fn () => /* some code */)
190190
->compare(
191191
fn () => /* some code */,
@@ -199,7 +199,7 @@ inside the callback function.
199199
```php
200200
use DragonCode\Benchmark\Benchmark;
201201

202-
Benchmark::start()
202+
Benchmark::make()
203203
->prepare(fn (mixed $name, int $iteration) => /* some code */)
204204
->compare(
205205
fn () => /* some code */,
@@ -213,7 +213,7 @@ the input parameter:
213213
```php
214214
use DragonCode\Benchmark\Benchmark;
215215

216-
Benchmark::start()
216+
Benchmark::make()
217217
->prepare(fn (mixed $name, int $iteration) => /* some code */)
218218
->compare(
219219
fn (int $iteration, mixed $prepareResult) => /* some code */,

0 commit comments

Comments
 (0)