+const Plugin::PresetRecord*
+Plugin::preset_by_label(const string& label)
+{
+ // FIXME: O(n)
+ for (map<string,PresetRecord>::const_iterator i = presets.begin(); i != presets.end(); ++i) {
+ if (i->second.label == label) {
+ return &i->second;
+ }
+ }
+ return NULL;
+}
+
+const Plugin::PresetRecord*
+Plugin::preset_by_uri(const string& uri)
+{
+ map<string,PresetRecord>::const_iterator pr = presets.find(uri);
+ if (pr != presets.end()) {
+ return &pr->second;
+ } else {
+ return NULL;
+ }
+}
+
+vector<Plugin::PresetRecord>