This commit is contained in:
AhJ
2024-07-24 12:10:58 +03:30
parent 3acbe24b17
commit 19b5535d39
4 changed files with 13 additions and 39 deletions
-13
View File
@@ -48,17 +48,4 @@ final class Mixin extends TagWithType implements Factory\StaticMethod
return new static($type, $description);
}
public function __toString(): string
{
if ($this->description) {
$description = $this->description->render();
} else {
$description = '';
}
$type = (string) $this->type;
return $type . ($description !== '' ? ($type !== '' ? ' ' : '') . $description : '');
}
}
-13
View File
@@ -60,17 +60,4 @@ final class Return_ extends TagWithType implements Factory\StaticMethod
return new static($type, $description);
}
public function __toString(): string
{
if ($this->description) {
$description = $this->description->render();
} else {
$description = '';
}
$type = $this->type ? '' . $this->type : 'mixed';
return $type . ($description !== '' ? ' ' . $description : '');
}
}
+13
View File
@@ -71,4 +71,17 @@ abstract class TagWithType extends BaseTag
return [$type, $description];
}
public function __toString(): string
{
if ($this->description) {
$description = $this->description->render();
} else {
$description = '';
}
$type = (string) $this->type;
return $type . ($description !== '' ? ($type !== '' ? ' ' : '') . $description : '');
}
}
-13
View File
@@ -48,17 +48,4 @@ final class Throws extends TagWithType implements Factory\StaticMethod
return new static($type, $description);
}
public function __toString(): string
{
if ($this->description) {
$description = $this->description->render();
} else {
$description = '';
}
$type = (string) $this->type;
return $type . ($description !== '' ? ($type !== '' ? ' ' : '') . $description : '');
}
}