chore: adds doc blocks to Search module
This commit is contained in:
@@ -4,9 +4,9 @@ namespace App\Search\Action\Command;
|
||||
|
||||
use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
|
||||
/** @implements CommandInterface<GetMediaInfoCommand> */
|
||||
class GetMediaInfoCommand implements CommandInterface
|
||||
{
|
||||
/** @implements CommandInterface<GetMediaInfoCommand> */
|
||||
public function __construct(
|
||||
public string $tmdbId,
|
||||
public string $mediaType,
|
||||
|
||||
@@ -4,12 +4,9 @@ namespace App\Search\Action\Command;
|
||||
|
||||
use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
|
||||
/** @implements CommandInterface<SearchCommand> */
|
||||
class SearchCommand implements CommandInterface
|
||||
{
|
||||
/**
|
||||
* @param string $term
|
||||
* @implements CommandInterface<SearchCommand>
|
||||
*/
|
||||
public function __construct(
|
||||
public string $term
|
||||
) {}
|
||||
|
||||
@@ -2,12 +2,14 @@
|
||||
|
||||
namespace App\Search\Action\Handler;
|
||||
|
||||
use App\Search\Action\Command\GetMediaInfoCommand;
|
||||
use App\Search\Action\Result\GetMediaInfoResult;
|
||||
use App\Tmdb\Tmdb;
|
||||
use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
use OneToMany\RichBundle\Contract\HandlerInterface;
|
||||
use OneToMany\RichBundle\Contract\ResultInterface;
|
||||
|
||||
/** @implements HandlerInterface<GetMediaInfoCommand, GetMediaInfoResult> */
|
||||
class GetMediaInfoHandler implements HandlerInterface
|
||||
{
|
||||
public function __construct(
|
||||
|
||||
@@ -8,13 +8,13 @@ use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
use OneToMany\RichBundle\Contract\HandlerInterface;
|
||||
use OneToMany\RichBundle\Contract\ResultInterface;
|
||||
|
||||
/*** @implements HandlerInterface<SearchResult> */
|
||||
class SearchHandler implements HandlerInterface
|
||||
{
|
||||
public function __construct(
|
||||
private Tmdb $tmdb,
|
||||
) {}
|
||||
|
||||
/*** @implements HandlerInterface<SearchResult> */
|
||||
public function handle(CommandInterface $command): ResultInterface
|
||||
{
|
||||
return new SearchResult(
|
||||
|
||||
@@ -8,6 +8,7 @@ use OneToMany\RichBundle\Attribute\SourceRoute;
|
||||
use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
use OneToMany\RichBundle\Contract\InputInterface;
|
||||
|
||||
/** @implements InputInterface<GetMediaInfoInput> */
|
||||
class GetMediaInfoInput implements InputInterface
|
||||
{
|
||||
public function __construct(
|
||||
|
||||
@@ -8,9 +8,7 @@ use OneToMany\RichBundle\Attribute\SourceRequest;
|
||||
use OneToMany\RichBundle\Contract\CommandInterface;
|
||||
use OneToMany\RichBundle\Contract\InputInterface;
|
||||
|
||||
/**
|
||||
* @implements InputInterface<SearchCommand>
|
||||
*/
|
||||
/** @implements InputInterface<SearchCommand> */
|
||||
class SearchInput implements InputInterface
|
||||
{
|
||||
public function __construct(
|
||||
|
||||
@@ -5,9 +5,9 @@ namespace App\Search\Action\Result;
|
||||
use App\Tmdb\TmdbResult;
|
||||
use OneToMany\RichBundle\Contract\ResultInterface;
|
||||
|
||||
/** @implements ResultInterface<GetMediaInfoResult> */
|
||||
class GetMediaInfoResult implements ResultInterface
|
||||
{
|
||||
/** @implements ResultInterface<GetMediaInfoResult> */
|
||||
public function __construct(
|
||||
public TmdbResult $media,
|
||||
) {}
|
||||
|
||||
@@ -4,6 +4,7 @@ namespace App\Search\Action\Result;
|
||||
|
||||
use OneToMany\RichBundle\Contract\ResultInterface;
|
||||
|
||||
/** @implements ResultInterface<SearchResult> */
|
||||
class SearchResult implements ResultInterface
|
||||
{
|
||||
public function __construct(
|
||||
|
||||
Reference in New Issue
Block a user