bundles/BlockManagerBundle/Controller/API/V1/Layout/Create.php
private function validateCreateLayout(ParameterBag $data): void
    {
        $this->validate(
            $data->get('layout_type'),
            [
                new Constraints\NotBlank(),
                new Constraints\Type(['type' => 'string']),
            ],
            'layout_type'
        );

        $this->validate(
            $data->get('locale'),
            [
                new Constraints\NotBlank(),
                new Constraints\Type(['type' => 'string']),
                new LocaleConstraint(),
            ],
            'locale'
        );
    }
private function validateCreateLayout(ParameterBag $data): void
    {
        $this->validate(
            $data->get('layout_type'),
            [
                new Constraints\NotBlank(),
                new Constraints\Type(['type' => 'string']),
            ],
            'layout_type'
        );

        $this->validate(
            $data->get('locale'),
            [
                new Constraints\NotBlank(),
                new Constraints\Type(['type' => 'string']),
                new LocaleConstraint(),
            ],
            'locale'
        );
    }
private function validateCreateLayout ( ParameterBag $ data ) : void { $ this -> validate ( $ data -> get ( 'layout_type' ) , [ new Constraints \ NotBlank ( ) , new Constraints \ Type ( [ 'type' => 'string' ] ) , ] , 'layout_type' ) ; $ this -> validate ( $ data -> get ( 'locale' ) , [ new Constraints \ NotBlank ( ) , new Constraints \ Type ( [ 'type' => 'string' ] ) , new LocaleConstraint ( ) , ] , 'locale' ) ; }
Validates layout creation parameters from the request.

@throws \Netgen\BlockManager\Exception\Validation\ValidationException If validation failed
Validates layout creation parameters from the request .