original_string: public static function mimetype_from_file($fullpath) {
          if (file_exists($fullpath)) {
              // The type is unknown. Attempt to look up the file type now.
              $finfo = new finfo(FILEINFO_MIME_TYPE);
              return mimeinfo_from_type('type', $finfo->file($fullpath));
          }
  
          return 'document/unknown';
      }
code: public static function mimetype_from_file($fullpath) {
          if (file_exists($fullpath)) {
              // The type is unknown. Attempt to look up the file type now.
              $finfo = new finfo(FILEINFO_MIME_TYPE);
              return mimeinfo_from_type('type', $finfo->file($fullpath));
          }
  
          return 'document/unknown';
      }
code_tokens: public static function mimetype_from_file ( $ fullpath ) { if ( file_exists ( $ fullpath ) ) { // The type is unknown. Attempt to look up the file type now. $ finfo = new finfo ( FILEINFO_MIME_TYPE ) ; return mimeinfo_from_type ( 'type' , $ finfo -> file ( $ fullpath ) ) ; } return 'document/unknown' ; }
docstring: Inspect a file on disk for it's mimetype.
  
  @param string $fullpath Path to file on disk
  @return string The mimetype
docstring_tokens: Inspect a file on disk for it s mimetype .