#pragma once

#include <string>
#include <vector>
#include <map>
#include <chrono>
#include "Jikan-config.h"

#ifdef INCLUDE_GPU_TIMER
    #include <cuda_runtime.h>
#endif

typedef std::chrono::steady_clock::time_point chrono_time_type;

class EventData{
public:
#ifdef INCLUDE_GPU_TIMER
    cudaEvent_t gpu_start, gpu_end;
#endif

    chrono_time_type start;
    double elapsed_time;      // seconds
    int count, ifCUDA;
    bool ifStart, ifEnd;
    std::vector<double> time_series;
    std::string event_name;

    EventData();
    ~EventData();
    EventData(const std::string& name);
    EventData& operator=(const EventData& src);

    double GetMeanElapsedTime();
};