// deployer Services header
// Copyright (C) 2024 Jean-Cloud
// GNU General Public License v3

#if !defined(SERVICES_H)
#define SERVICES_H

#include <iostream>
#include <cstring>
#include <list>
#include <vector>
#include "Service.h"

using namespace std;


class Services 
//extracts the list of uid|username|service from the services.csv file 
{
    public:
    Services();
    vector<Service> GetServices() const;
    const Service * FindByUsername(string aUsername) const;
    const Service * FindByID(int aUserID) const;
    list<const Service*> FindByServer(string aServer) const;
    ~Services();
    private:
    vector <Service> readServicesFromCSV () const;
    vector <Service> services;
};
#endif