public function checkMandatoryColumns(array $data)
    {
        $diff = array_diff($this->mandatoryColumns, array_keys($data));

        if (\count($diff) > 0) {
            throw new \UnexpectedValueException(
                Translator::getInstance()->trans(
                    'The following columns are missing: %columns',
                    [
                        '%columns' => implode(', ', $diff)
                    ]
                )
            );
        }
    }
public function checkMandatoryColumns(array $data)
    {
        $diff = array_diff($this->mandatoryColumns, array_keys($data));

        if (\count($diff) > 0) {
            throw new \UnexpectedValueException(
                Translator::getInstance()->trans(
                    'The following columns are missing: %columns',
                    [
                        '%columns' => implode(', ', $diff)
                    ]
                )
            );
        }
    }
public function checkMandatoryColumns ( array $ data ) { $ diff = array_diff ( $ this -> mandatoryColumns , array_keys ( $ data ) ) ; if ( \ count ( $ diff ) > 0 ) { throw new \ UnexpectedValueException ( Translator :: getInstance ( ) -> trans ( 'The following columns are missing: %columns' , [ '%columns' => implode ( ', ' , $ diff ) ] ) ) ; } }
Check mandatory columns

@param array $data Data

@return boolean Data contains mandatory columns or not
Check mandatory columns