source: FarmatikoData/FarmatikoRepoInterfaces/IRepository.cs@ 993189e

Last change on this file since 993189e was 6f203af, checked in by DimitarSlezenkovski <dslezenkovski@…>, 4 years ago

Change methods & add error controller

  • Property mode set to 100644
File size: 1.7 KB
Line 
1using FarmatikoData.Models;
2using System;
3using System.Collections.Generic;
4using System.Linq;
5using System.Text;
6using System.Threading.Tasks;
7
8namespace FarmatikoData.FarmatikoRepoInterfaces
9{
10 public interface IRepository
11 {
12 //GET
13 Task<IEnumerable<HealthcareWorker>> GetAllWorkers();
14 Task<IEnumerable<HealthFacility>> GetFacilities();
15 Task<HealthFacility> GetFacility(int Id);
16 Task<Medicine> GetMedicine(int Id);
17 Task<IEnumerable<Medicine>> GetMedicines();
18 Task<Pandemic> GetPandemic();
19 Task<IEnumerable<Pharmacy>> GetPharmacies();
20 Task<Pharmacy> GetPharmacy(int id);
21 Task<HealthcareWorker> GetWorker(int id);
22 Task<IEnumerable<HealthFacility>> SearchFacilities(string query);
23 Task<IEnumerable<Medicine>> SearchMedicines(string query);
24 Task<IEnumerable<Pharmacy>> SearchPharmacies(string query);
25 Task<IEnumerable<HealthcareWorker>> SearchWorkers(string query);
26 Task<HealthFacility> GetFacilityJSON(string healthFacility);
27
28 //POST
29 Task AddWorker(HealthcareWorker Worker);
30 Task AddFacility(HealthFacility healthFacility);
31 Task AddPharmacy(Pharmacy pharmacy);
32 Task AddPharmacyHead(PharmacyHead pharmacyHead);
33 Task AddMedicines(Medicine medicine);
34 Task AddPandemic(Pandemic pandemic);
35 Task UpdateFacility(HealthFacility healthFacility);
36 Task RemoveMedicine(Medicine medicine);
37 Task UpdatePandemic(Pandemic pandemic);
38 Task RemovePharmacy(Pharmacy pharmacy);
39 Task UpdateWorker(HealthcareWorker worker);
40 Task UpadatePharmacy(Pharmacy pharmacy);
41 Task UpdateMedicine(Medicine medicine);
42 Task RemovePharmacyHead(int Id);
43 }
44}
Note: See TracBrowser for help on using the repository browser.