mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-07-31 20:20:15 +02:00
PHP8
This commit is contained in:
@@ -4,11 +4,8 @@ namespace DesignPatterns\Structural\Flyweight;
|
||||
|
||||
class Word implements Text
|
||||
{
|
||||
private string $name;
|
||||
|
||||
public function __construct(string $name)
|
||||
public function __construct(private string $name)
|
||||
{
|
||||
$this->name = $name;
|
||||
}
|
||||
|
||||
public function render(string $font): string
|
||||
|
Reference in New Issue
Block a user