ALib C++ Library
Library Version: 2510 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
resources.prepro.hpp
Go to the documentation of this file.
1//==================================================================================================
2/// \file
3/// This header-file is part of the \aliblong.
4///
5/// \emoji :copyright: 2013-2025 A-Worx GmbH, Germany.
6/// Published under \ref mainpage_license "Boost Software License".
7//==================================================================================================
8#ifndef HPP_ALIB_RESOURCES_PP
9#define HPP_ALIB_RESOURCES_PP
10#pragma once
11#ifndef INL_ALIB
12# include "alib/alib.inl"
13#endif
14
15// #################################################################################################
16// Symbols introduced by module ALib.Resources
17// #################################################################################################
18#if !ALIB_RESOURCES
19# define ALIB_DEBUG_RESOURCES 0
20#elif !defined(ALIB_DEBUG_RESOURCES)
21# define ALIB_DEBUG_RESOURCES 0
22#elif !ALIB_DEBUG && ALIB_DEBUG_RESOURCES
23# undef ALIB_DEBUG_RESOURCES
24# define ALIB_DEBUG_RESOURCES 0
25# pragma message "Symbol ALIB_DEBUG_RESOURCES set (from outside!) while ALIB_DEBUG is not. The symbol got disabled."
26#endif
27
28#if ALIB_RESOURCES
29#define ALIB_RESOURCED( T, ResPool, ResCategory, ResName ) \
30namespace alib::resources { \
31template<> struct ResourcedTraits<T> : std::true_type \
32{ \
33 static ResourcePool* Pool() { return ResPool; } \
34 static constexpr NString Category() { return ResCategory; } \
35 static constexpr NString Name() { return ResName; } \
36};}
37
38#endif
39#endif // HPP_ALIB_RESOURCES_PP
40