*/
-#include <ardour/export_format_base.h>
+#include "ardour/export_format_base.h"
namespace ARDOUR
{
ExportFormatBase::ExportFormatBase ()
{
-
+
}
ExportFormatBase::ExportFormatBase (ExportFormatBase const & other) :
ExportFormatBase::~ExportFormatBase ()
{
-
+
}
boost::shared_ptr<ExportFormatBase>
ExportFormatBase::do_set_operation (ExportFormatBase const & other, SetOperation operation) const
{
boost::shared_ptr<ExportFormatBase> result (new ExportFormatBase ());
-
+
/* Sets */
-
+
// Endiannesses
{
EndianSet::const_iterator start1 = endiannesses.begin();
EndianSet::const_iterator start2 = other.endiannesses.begin();
EndianSet::const_iterator end2 = other.endiannesses.end();
std::insert_iterator<EndianSet> insert (result->endiannesses, result->endiannesses.begin());
-
+
switch (operation) {
case SetIntersection:
std::set_intersection (start1, end1, start2, end2, insert);
break;
}
}
-
+
// Sample formats
{
SampleFormatSet::const_iterator start1 = sample_formats.begin();
SampleFormatSet::const_iterator start2 = other.sample_formats.begin();
SampleFormatSet::const_iterator end2 = other.sample_formats.end();
std::insert_iterator<SampleFormatSet> insert (result->sample_formats, result->sample_formats.begin());
-
+
switch (operation) {
case SetIntersection:
std::set_intersection (start1, end1, start2, end2, insert);
break;
}
}
-
-
+
+
// Sample rates
{
SampleRateSet::const_iterator start1 = sample_rates.begin();
SampleRateSet::const_iterator start2 = other.sample_rates.begin();
SampleRateSet::const_iterator end2 = other.sample_rates.end();
std::insert_iterator<SampleRateSet> insert (result->sample_rates, result->sample_rates.begin());
-
+
switch (operation) {
case SetIntersection:
std::set_intersection (start1, end1, start2, end2, insert);
break;
}
}
-
+
// Format ids
{
FormatSet::const_iterator start1 = format_ids.begin();
FormatSet::const_iterator start2 = other.format_ids.begin();
FormatSet::const_iterator end2 = other.format_ids.end();
std::insert_iterator<FormatSet> insert (result->format_ids, result->format_ids.begin());
-
+
switch (operation) {
case SetIntersection:
std::set_intersection (start1, end1, start2, end2, insert);
break;
}
}
-
+
// Qualities
{
QualitySet::const_iterator start1 = qualities.begin();
QualitySet::const_iterator start2 = other.qualities.begin();
QualitySet::const_iterator end2 = other.qualities.end();
std::insert_iterator<QualitySet> insert (result->qualities, result->qualities.begin());
-
+
switch (operation) {
case SetIntersection:
std::set_intersection (start1, end1, start2, end2, insert);
break;
}
}
-
+
return result;
}