| /** | |
| * @file models.hpp | |
| * @brief Data models with strong typing. | |
| */ | |
| namespace app::core { | |
| /** | |
| * @brief Base entity with timestamps. | |
| */ | |
| struct BaseEntity { | |
| int id{0}; | |
| std::chrono::system_clock::time_point created_at; | |
| std::chrono::system_clock::time_point updated_at; | |
| }; | |
| /** | |
| * @brief User entity. | |
| */ | |
| struct User : BaseEntity { | |
| std::string email; | |
| std::string password_hash; | |
| std::optional<std::string> name; | |
| }; | |
| } // namespace app::core | |