public function validateConfig(array $rules, array $configData)
    {
        $validator = $this->createNew(Validator::class);
        
        if ($validator->isValid($rules, $configData) == false) {
            throw new DataValidationException('The config is invalid: ' . print_r($validator->getErrors(), 1));
        }
    }
public function validateConfig(array $rules, array $configData)
    {
        $validator = $this->createNew(Validator::class);
        
        if ($validator->isValid($rules, $configData) == false) {
            throw new DataValidationException('The config is invalid: ' . print_r($validator->getErrors(), 1));
        }
    }
public function validateConfig ( array $ rules , array $ configData ) { $ validator = $ this -> createNew ( Validator :: class ) ; if ( $ validator -> isValid ( $ rules , $ configData ) == false ) { throw new DataValidationException ( 'The config is invalid: ' . print_r ( $ validator -> getErrors ( ) , 1 ) ) ; } }
Validate some config data

@param array $rules      The config rules
@param array $configData The config data

@throws Mooti\Framework\Exception\DataValidationException
Validate some config data