private function count_files($submissionid, $area) {
        $fs = get_file_storage();
        $files = $fs->get_area_files($this->assignment->get_context()->id,
                                     'assignsubmission_file',
                                     $area,
                                     $submissionid,
                                     'id',
                                     false);

        return count($files);
    }
private function count_files($submissionid, $area) {
        $fs = get_file_storage();
        $files = $fs->get_area_files($this->assignment->get_context()->id,
                                     'assignsubmission_file',
                                     $area,
                                     $submissionid,
                                     'id',
                                     false);

        return count($files);
    }
private function count_files ( $ submissionid , $ area ) { $ fs = get_file_storage ( ) ; $ files = $ fs -> get_area_files ( $ this -> assignment -> get_context ( ) -> id , 'assignsubmission_file' , $ area , $ submissionid , 'id' , false ) ; return count ( $ files ) ; }
Count the number of files

@param int $submissionid
@param string $area
@return int
Count the number of files