public function validate(array $schema, bool $strong = false): Interfaces\Yaml
    {
        $valid = new Validation();
        $valid->compare($schema, $this->_parameters);

        // Parse parameters in loop
        $parameters = $this->get();

        // Parse two arrays and compare data
        $this->parse($parameters, $schema);

        return $this;
    }
public function validate(array $schema, bool $strong = false): Interfaces\Yaml
    {
        $valid = new Validation();
        $valid->compare($schema, $this->_parameters);

        // Parse parameters in loop
        $parameters = $this->get();

        // Parse two arrays and compare data
        $this->parse($parameters, $schema);

        return $this;
    }
public function validate ( array $ schema , bool $ strong = false ) : Interfaces \ Yaml { $ valid = new Validation ( ) ; $ valid -> compare ( $ schema , $ this -> _parameters ) ; // Parse parameters in loop $ parameters = $ this -> get ( ) ; // Parse two arrays and compare data $ this -> parse ( $ parameters , $ schema ) ; return $ this ; }
Validate Yaml before saving

@param   array $schema - Array of parameters which should be validated
@param   bool $strong - Enable strong check in two ways
@return  Yaml
Validate Yaml before saving