Irregularity.h 592 Bytes
Newer Older
Matteo's avatar
update  
Matteo committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#ifndef IRREGULARITY_H
#define IRREGULARITY_H
#include <boost/uuid/uuid.hpp>
#include <nlohmann/json.hpp>
#include "enums.h"

using std::string;
using json = nlohmann::json;

/**
 * @brief an irregularity of the tape detected by the system
 * 
 */
struct Irregularity
{
    boost::uuids::uuid id;
    Source source;
    string time_label;
    IrregularityType type;
    string image_URI;

    Irregularity(Source source, string time_label, IrregularityType type, string image_URI);
    ~Irregularity();
    json toJSON();
    static Irregularity fromJSON(json j);
};

#endif // IRREGULARITY_H