Commit b9d92535 authored by Davis King's avatar Davis King

Added an is_config_reader template.

parent 1afa8aca
......@@ -8,6 +8,7 @@
#include "tokenizer.h"
#include "algs.h"
#include "is_kind.h"
namespace dlib
......@@ -19,11 +20,15 @@ namespace dlib
tokenizer::kernel_1a
> config_reader;
template <> struct is_config_reader<config_reader> { const static bool value = true; };
#ifndef DLIB_ISO_CPP_ONLY
typedef config_reader_thread_safe_1<
config_reader,
map<std::string,void*>::kernel_1b
> config_reader_thread_safe;
template <> struct is_config_reader<config_reader_thread_safe> { const static bool value = true; };
#endif // DLIB_ISO_CPP_ONLY
......
......@@ -111,6 +111,19 @@ namespace dlib
!*/
};
// ----------------------------------------------------------------------------------------
template <typename T>
struct is_config_reader : public default_is_kind_value
{
/*!
- if (T is an implementation of config_reader/config_reader_kernel_abstract.h) then
- is_config_reader<T>::value == true
- else
- is_config_reader<T>::value == false
!*/
};
// ----------------------------------------------------------------------------------------
// ----------------------------------------------------------------------------------------
// Implementation details
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment