generated from yiisoft/package-template
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
In methods of array definitions add autowiring and improve variadic a…
…rguments support (#44)
- Loading branch information
Showing
5 changed files
with
270 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Yiisoft\Definitions\Tests\Support; | ||
|
||
final class Mouse | ||
{ | ||
private ?string $name = null; | ||
private ?EngineInterface $engine = null; | ||
private array $colors = []; | ||
|
||
public function setNameAndEngine(string $name, EngineInterface $engine): void | ||
{ | ||
$this->name = $name; | ||
$this->engine = $engine; | ||
} | ||
|
||
public function setNameAndColors(string $name, ...$colors): void | ||
{ | ||
$this->name = $name; | ||
$this->colors = $colors; | ||
} | ||
|
||
public function getName(): ?string | ||
{ | ||
return $this->name; | ||
} | ||
|
||
public function getEngine(): ?EngineInterface | ||
{ | ||
return $this->engine; | ||
} | ||
|
||
public function getColors(): array | ||
{ | ||
return $this->colors; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters