droplet 1.3.0
A multipurpose Discord bot with the hacker in mind
Loading...
Searching...
No Matches
IRepository.hpp
Go to the documentation of this file.
1/*
2 * (c) Copyright erarnitox.de - All rights reserved
3 * Author: Erarnitox <david@erarnitox.de>
4 *
5 * License: MIT License
6 *
7 * Description:
8 *
9 * Documentation: https://droplet.erarnitox.de/doxygen/html/
10 */
11#pragma once
12
13#include <cstddef>
14
15//-----------------------------------------------------
16//
17//-----------------------------------------------------
18template <typename DTO>
20 public:
21 [[nodiscard]] virtual bool create(const DTO& object) noexcept = 0;
22
23 [[nodiscard]] virtual bool remove(size_t index) noexcept = 0;
24
25 [[nodiscard]] virtual DTO get(size_t index) const noexcept = 0;
26
27 [[nodiscard]] virtual bool update(const DTO& object) noexcept = 0;
28};
Definition IRepository.hpp:19
virtual bool update(const DTO &object) noexcept=0
virtual bool remove(size_t index) noexcept=0
virtual bool create(const DTO &object) noexcept=0
virtual DTO get(size_t index) const noexcept=0