This is a static copy of a profile report

Home

AcceptsFileType>AcceptsFileType.getFileTypeFirst (Calls: 2, Time: 0.007 s)
Generated 04-Jun-2021 04:11:05 using performance time.
class method in file C:\Program Files\MATLAB\R2020b\toolbox\shared\io\general\+matlab\+io\+internal\+functions\AcceptsFileType.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
...tions>DetectImportOptions.validateclass method2
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
18
results = func.Parser.canonica...
20.005 s74.9%
17
[args{namesIdx}] = convertStri...
20.001 s7.3%
20
args(namesIdx) = cellstr(resul...
20.000 s6.7%
19
matches = find(results.Canonic...
20.000 s4.0%
16
namesIdx = 2:2:(numel(args)-1)...
20.000 s2.0%
All other lines  0.000 s5.1%
Totals  0.007 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
...r>ArgumentParser.canonicalizeNamesclass method20.005 s62.7%
Self time (built-ins, overhead, etc.)  0.003 s37.3%
Totals  0.007 s100% 
Code Analyzer results
Line numberMessage
Coverage results
Show coverage for parent directory
Total lines in function12
Non-code lines (comments, blank lines)2
Code lines (lines that can run)10
Code lines that did run8
Code lines that did not run2
Coverage (did run/can run)80.00 %
Function listing
time 
Calls 
 line
  15 
        function [func,args] = getFileTypeFirst(func,args)
< 0.001 
      2 
  16
            namesIdx = 2:2:(numel(args)-1); 
< 0.001 
      2 
  17
            [args{namesIdx}] = convertStringsToChars(args{namesIdx}); 
  0.005 
      2 
  18
            results = func.Parser.canonicalizeNames(args(namesIdx)); 
< 0.001 
      2 
  19
            matches = find(results.CanonicalNames == "FileType"); 
< 0.001 
      2 
  20
            args(namesIdx) = cellstr(results.CanonicalNames); 
< 0.001 
      2 
  21
            if ~isempty(matches) 
  22 
                % Use the last setting for file type
  23 
                func.FileType = args{2*matches(end)+1};
  24 
                args([2*matches(1:end-1); 2*matches(1:end-1)+1]) = [];
< 0.001 
      2 
  25
            end 
< 0.001 
      2 
  26
        end 

Other subfunctions in this file are not included in this listing.