#pragma once

#include <Windows.h>

#include <string>
#include <vector>

#include "Core/Constant.h"

class CriticalSection {
    NON_COPYABLE(CriticalSection)

public:
    explicit CriticalSection() noexcept;
    ~CriticalSection() noexcept;
    void Lock() {
        EnterCriticalSection(&section_);
    }
    void Unlock() {
        LeaveCriticalSection(&section_);
    }

private:
    CRITICAL_SECTION section_;
};
