#include "BDDevices.h"

const char* swic_devices[] = {
    "E:M101DS",
    "E:M105DS",
    "E:M107DS",
    "E:M108DS",
    "E:M112DS",

    "E:M114DS",
    "E:M115DS",
    "E:M117DS",
    "E:M121DS",
    "E:MTGTDS",

    "E:HADMDS",
    "E:MMA1DS",
    "E:MMA2DS",
    "E:MMA3DS",
    0
};

///  List of profile monitors
const char* profile_monitors[] = {
    "E:M101DS",
    "E:M105DS",
    "E:M107DS",
    "E:M108DS",
    "E:M112DS",

    "E:M114DS",
    "E:M115DS",
    "E:M117DS",
    "E:M121DS",
    "E:MTGTDS",
    0
};

///  List of BPM positions
const char* bpm_positions[] = {
    "E:VP101",
    "E:HP101",
    "E:HP102",
    "E:VP103",
    "E:HP104",
    "E:HP105",
    "E:VP106",
    "E:HP107",
    "E:VP108",
    "E:HP109",
    "E:VP110",
    "E:VP111",
    "E:HP112",
    "E:VP113",
    "E:HP114",
    "E:HP115",
    "E:VP116",
    "E:HP117",
    "E:VP118",
    "E:HP119",
    "E:HP121",
    "E:VP121",
    "E:HPTGT",
    "E:VPTGT",
    0
};


const char* toroids[] = {
    "E:TOR101",
    "E:TR101D",
    "E:TORTGT",
    "E:TRTGTD",
    0
};

///  List of BPM intensities
const char* bpm_intensities[] = {
    "E:VI101",
    "E:HI101",
    "E:HI102",
    "E:VI103",
    "E:HI104",
    "E:HI105",
    "E:VI106",
    "E:HI107",
    "E:VI108",
    "E:HI109",
    "E:VI110",
    "E:VI111",
    "E:HI112",
    "E:VI113",
    "E:HI114",
    "E:HI115",
    "E:VI116",
    "E:HI117",
    "E:VI118",
    "E:HI119",
    "E:HI121",
    "E:VI121",
    "E:HITGT",
    "E:VITGT",
    0
};

/// List of Had, mu1, mu2 and mu3 monitors
const char* had_mu_monitors[] = {
    "E:HADMDS",
    "E:MMA1DS",
    "E:MMA2DS",
    "E:MMA3DS",
    0
};
    

using namespace std;

vector<string> array2vector(const char* a[])
{
    vector<string> ret;
    for (int ind=0; a[ind]; ++ind)
	ret.push_back(a[ind]);
    return ret;
}


vector<string> BDDevices::SwicDevices()
{
    return array2vector(swic_devices);
}
vector<string> BDDevices::ProfileMonitors()
{
    return array2vector(profile_monitors);
}
vector<string> BDDevices::BpmPositions()
{
    return array2vector(bpm_positions);
}
vector<string> BDDevices::BpmIntensities()
{
    return array2vector(bpm_intensities);
}
vector<string> BDDevices::Toroids()
{
    return array2vector(toroids);
}
vector<string> BDDevices::HadMuMonitors()
{
    return array2vector(had_mu_monitors);
}
