Mercurial > hg > svcore
diff rdf/RDFTransformFactory.cpp @ 994:8c9c425b4958
Support plugin version in RDF transforms, and bail out in Sonic Annotator if it doesn't match
author | Chris Cannam |
---|---|
date | Fri, 10 Oct 2014 15:24:28 +0100 |
parents | a51781b11dd4 |
children | 274c4362bda6 |
line wrap: on
line diff
--- a/rdf/RDFTransformFactory.cpp Wed Oct 08 13:14:17 2014 +0100 +++ b/rdf/RDFTransformFactory.cpp Fri Oct 10 15:24:28 2014 +0100 @@ -212,7 +212,8 @@ "window_type", "sample_rate", "start", - "duration" + "duration", + "plugin_version" }; for (int j = 0; j < int(sizeof(optionals)/sizeof(optionals[0])); ++j) { @@ -249,6 +250,8 @@ if (duration == RealTime::zeroTime) { cerr << "\nRDFTransformFactory: WARNING: Duration is specified as \"" << onode.value << "\" in RDF file,\n but this evaluates to zero when parsed as an xsd:duration datatype.\n The duration property will therefore be ignored.\n To specify start time and duration use the xsd:duration format,\n for example \"PT2.5S\"^^xsd:duration (for 2.5 seconds).\n\n"; } + } else if (optional == "plugin_version") { + transform.setPluginVersion(onode.value); } else { cerr << "RDFTransformFactory: ERROR: Inconsistent optionals lists (unexpected optional \"" << optional << "\"" << endl; }