libcrn  3.9.5
A document image processing library
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Macros
Containers
+ Collaboration diagram for Containers:

Classes

class  crn::Map
 Data map class. More...
 
class  crn::Vector
 Data vector class. More...
 

Macros

#define CRN_ADD_RANGED_FOR_TO_POINTERS(TYPE)
 Enables ranged for for smart pointers on a type. More...
 
#define CRN_ADD_RANGED_FOR_TO_CONST_POINTERS(TYPE)
 Enables ranged for for smart pointers on a type. More...
 

Detailed Description

Macro Definition Documentation

#define CRN_ADD_RANGED_FOR_TO_CONST_POINTERS (   TYPE)
Value:
namespace std { \
inline auto begin(const std::unique_ptr<const TYPE> &v) -> decltype (v->cbegin()) { return v->cbegin(); } \
inline auto begin(const std::shared_ptr<const TYPE> &v) -> decltype (v->cbegin()) { return v->cbegin(); } \
inline auto end(const std::unique_ptr<const TYPE> &v) -> decltype (v->cend()) { return v->cend(); } \
inline auto end(const std::shared_ptr<const TYPE> &v) -> decltype (v->cend()) { return v->cend(); } \
}

Enables ranged for for smart pointers on a type.

Enables ranged for for smart pointers on a type. Must be call out all of namespaces.

Parameters
[in]TYPEthe container's type with full namespace scope

Definition at line 51 of file CRNForeach.h.

#define CRN_ADD_RANGED_FOR_TO_POINTERS (   TYPE)
Value:
namespace std { \
inline auto begin(const std::unique_ptr<TYPE> &v) -> decltype (v->begin()) { return v->begin(); } \
inline auto begin(const std::shared_ptr<TYPE> &v) -> decltype (v->begin()) { return v->begin(); } \
inline auto end(const std::unique_ptr<TYPE> &v) -> decltype (v->end()) { return v->end(); } \
inline auto end(const std::shared_ptr<TYPE> &v) -> decltype (v->end()) { return v->end(); } \
}

Enables ranged for for smart pointers on a type.

Enables ranged for for smart pointers on a type. Must be call out all of namespaces.

Parameters
[in]TYPEthe container's type with full namespace scope

Definition at line 37 of file CRNForeach.h.