public function isArrayOfModels($models)
    {
        if ( ! is_array($models)) return false;

        $notModels = array_filter($models, function($model)
        {
            return ! $model instanceof Model;
        });

        return empty($notModels);
    }
public function isArrayOfModels($models)
    {
        if ( ! is_array($models)) return false;

        $notModels = array_filter($models, function($model)
        {
            return ! $model instanceof Model;
        });

        return empty($notModels);
    }
public function isArrayOfModels ( $ models ) { if ( ! is_array ( $ models ) ) return false ; $ notModels = array_filter ( $ models , function ( $ model ) { return ! $ model instanceof Model ; } ) ; return empty ( $ notModels ) ; }
Determine whether the given array of models is actually
an array containing model instances. In case at least one
of the elements is not a Model this will return false.

@param  array   $models
@return boolean
Determine whether the given array of models is actually an array containing model instances . In case at least one of the elements is not a Model this will return false .