27 return "*.svl *.csv *.lab *.mid *.txt";
35 int mainModelSampleRate)
43 if (reader->
isOK())
return reader;
49 reader =
new CSVFileReader(path, format, mainModelSampleRate);
50 if (reader->
isOK())
return reader;
61 int mainModelSampleRate)
64 (path,
false, acquirer,
CSVFormat(), mainModelSampleRate);
65 if (reader)
return reader;
68 (path,
true, acquirer,
CSVFormat(path), mainModelSampleRate);
69 if (reader)
return reader;
77 int mainModelSampleRate)
82 if (!reader)
return NULL;
97 int mainModelSampleRate)
102 mainModelSampleRate);
103 if (!reader)
return NULL;
117 int mainModelSampleRate)
120 mainModelSampleRate);
121 if (!reader)
return NULL;
static QString getKnownExtensions()
Return the file extensions that we have data file readers for, in a format suitable for use with QFil...
static Model * loadCSV(QString path, CSVFormat format, int mainModelSampleRate)
Read the given path using the CSV reader with the given format.
virtual bool isOK() const =0
Return true if the file appears to be of the correct type.
virtual Model * load() const =0
Read the file and return the corresponding data model.
Model is the base class for all data models that represent any sort of data on a time scale based on ...
virtual QString getError() const
static Model * load(QString path, MIDIFileImportPreferenceAcquirer *acquirer, int mainModelSampleRate)
Read the given path, if a suitable reader is available.
static Model * loadNonCSV(QString path, MIDIFileImportPreferenceAcquirer *acquirer, int mainModelSampleRate)
Read the given path, if a suitable reader is available.
static DataFileReader * createReader(QString path, MIDIFileImportPreferenceAcquirer *, int mainModelSampleRate)
Return a data file reader initialised to the file at the given path, or NULL if no suitable reader fo...