mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-02 21:13:57 +00:00
apply more cs rules for php-cs
This commit is contained in:
@@ -17,12 +17,12 @@ use Chill\DocGeneratorBundle\Entity\DocGeneratorTemplate;
|
||||
interface ContextManagerInterface
|
||||
{
|
||||
/**
|
||||
* @throws ContextNotFoundException When the context is not found.
|
||||
* @throws ContextNotFoundException when the context is not found
|
||||
*/
|
||||
public function getContextByDocGeneratorTemplate(DocGeneratorTemplate $docGeneratorTemplate): DocGeneratorContextInterface;
|
||||
|
||||
/**
|
||||
* @throws ContextNotFoundException When the context is not found.
|
||||
* @throws ContextNotFoundException when the context is not found
|
||||
*/
|
||||
public function getContextByKey(string $searchedKey): DocGeneratorContextInterface;
|
||||
|
||||
|
@@ -15,6 +15,7 @@ use Symfony\Component\Form\FormBuilderInterface;
|
||||
|
||||
/**
|
||||
* @template T of object
|
||||
*
|
||||
* @extends DocGeneratorContextInterface<T>
|
||||
*/
|
||||
interface DocGeneratorContextWithAdminFormInterface extends DocGeneratorContextInterface
|
||||
|
@@ -16,6 +16,7 @@ use Symfony\Component\Form\FormBuilderInterface;
|
||||
|
||||
/**
|
||||
* @template T of object
|
||||
*
|
||||
* @extends DocGeneratorContextInterface<T>
|
||||
*/
|
||||
interface DocGeneratorContextWithPublicFormInterface extends DocGeneratorContextInterface
|
||||
@@ -28,7 +29,7 @@ interface DocGeneratorContextWithPublicFormInterface extends DocGeneratorContext
|
||||
public function buildPublicForm(FormBuilderInterface $builder, DocGeneratorTemplate $template, mixed $entity): void;
|
||||
|
||||
/**
|
||||
* Fill the form with initial data
|
||||
* Fill the form with initial data.
|
||||
*
|
||||
* @param T $entity
|
||||
*/
|
||||
@@ -42,14 +43,14 @@ interface DocGeneratorContextWithPublicFormInterface extends DocGeneratorContext
|
||||
public function hasPublicForm(DocGeneratorTemplate $template, mixed $entity): bool;
|
||||
|
||||
/**
|
||||
* Transform the data from the form into serializable data, storable into messenger's message
|
||||
* Transform the data from the form into serializable data, storable into messenger's message.
|
||||
*
|
||||
* @param T $entity
|
||||
*/
|
||||
public function contextGenerationDataNormalize(DocGeneratorTemplate $template, mixed $entity, array $data): array;
|
||||
|
||||
/**
|
||||
* Reverse the data from the messenger's message into data usable for doc's generation
|
||||
* Reverse the data from the messenger's message into data usable for doc's generation.
|
||||
*
|
||||
* @param T $entity
|
||||
*/
|
||||
|
@@ -11,9 +11,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Chill\DocGeneratorBundle\Context\Exception;
|
||||
|
||||
use RuntimeException;
|
||||
|
||||
class ContextNotFoundException extends RuntimeException
|
||||
class ContextNotFoundException extends \RuntimeException
|
||||
{
|
||||
public function __construct($contextName)
|
||||
{
|
||||
|
@@ -11,13 +11,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Chill\DocGeneratorBundle\Context\Exception;
|
||||
|
||||
use LogicException;
|
||||
|
||||
use function get_class;
|
||||
use function gettype;
|
||||
use function is_object;
|
||||
|
||||
class UnexpectedTypeException extends LogicException
|
||||
class UnexpectedTypeException extends \LogicException
|
||||
{
|
||||
public function __construct($value, string $expectedType)
|
||||
{
|
||||
|
Reference in New Issue
Block a user