Newer
Older
// Basic
#include <fstream>
#include <iostream>
#include <iomanip>
#include <string>
#include <vector>
// Boost
#include <boost/program_options.hpp>
// Custom
#include "ProdDbAccess.h"
#include "BulkDbAccess.h"
#include "toolbox.cpp"
using namespace std;
namespace po = boost::program_options;
static string fileName = "serials.dat";
int main(int argc, char* argv[]) {
if ( argc < 2 ) {
cerr << "ERROR: Missing parameters! Please provide the name of a text file containing the serials needed." << endl;
exit(1);
}
if ( argc > 2 ) {
cerr << "ERROR: Too many parameters! Please only provide the name of a text file containing the serials needed." << endl;
exit(1);
}
fileName = string(argv[1]);
vector<string> apdSerials = loadSerialsFromFileName(fileName);
AbsDbAccess* _dba = suitedDbAccess(apdSerials.size());