Database System 0.1.0
Advanced C++20 Database System with Multi-Backend Support
Loading...
Searching...
No Matches
database::concepts::PooledResource Concept Reference

A type that can be managed by a pool. More...

#include <concepts.h>

Concept definition

template<typename T>
concept database::concepts::PooledResource = std::is_class_v<T> &&
std::is_default_constructible_v<T>
A type that can be managed by a pool.
Definition concepts.h:284

Detailed Description

A type that can be managed by a pool.

Types satisfying this concept can be pooled and reused.

Example usage:

template<PooledResource T>
class resource_pool {
std::shared_ptr<T> acquire();
void release(std::shared_ptr<T> resource);
};

Definition at line 284 of file concepts.h.