#ifndef UNIQUE_ID_HPP_
#define UNIQUE_ID_HPP_

#include <iostream>

#include <Serialize/Serialize.hpp>

/**
 * @brief Represents a unique ID (GUID/UUID).
 */
class UniqueID
{
private:
    alignas(8) uint8_t data[16];

public:
    /**
     * @brief Generate a unique ID.
     */
    static UniqueID generate();

    bool operator==(const UniqueID &other) const;

    friend std::ostream& operator<<(std::ostream &os, UniqueID id);
};

PLAIN_SERIALIZABLE(UniqueID);

std::ostream& operator<<(std::ostream &os, UniqueID id);

#endif