OpenCV  
Open Source Computer Vision
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Namespaces | Classes | Typedefs | Functions
cv::util Namespace Reference

Namespaces

namespace  detail
 

Classes

class  any
 
class  bad_any_cast
 
class  bad_optional_access
 
class  bad_variant_access
 
struct  copy_through_move_t
 
struct  monostate
 
class  optional
 
struct  static_indexed_visitor
 
struct  static_visitor
 
struct  type_list_element
 
struct  type_list_index
 
class  variant
 
struct  variant_size
 
struct  variant_size< util::variant< Types... > >
 

Typedefs

template<class T , class U , class V = void>
using are_different_t = enable_if_t< !std::is_same< decay_t< T >, decay_t< U > >::value, V >
 
template<typename T >
using decay_t = typename std::decay< T >::type
 
template<bool B, class T = void>
using enable_if_t = typename std::enable_if< B, T >::type
 

Functions

template<class value_t >
value_t & any_cast (any &operand)
 
template<class value_t >
value_t * any_cast (any *operand)
 
template<class value_t >
const value_t & any_cast (const any &operand)
 
template<class value_t >
const value_t * any_cast (const any *operand)
 
template<typename T >
copy_through_move_t< util::decay_t< T > > copy_through_move (T &&t)
 
template<typename T , typename... Types>
const T & get (const util::variant< Types... > &v)
 
template<std::size_t Index, typename... Types>
const util::type_list_element< Index, Types... >::type & get (const util::variant< Types... > &v)
 
template<typename T , typename... Types>
T & get (util::variant< Types... > &v)
 
template<std::size_t Index, typename... Types>
util::type_list_element< Index, Types... >::type & get (util::variant< Types... > &v)
 
template<typename T , typename... Types>
const T * get_if (const util::variant< Types... > *v) noexcept
 
template<typename T , typename... Types>
T * get_if (util::variant< Types... > *v) noexcept
 
template<typename T , typename... Types>
bool holds_alternative (const util::variant< Types... > &v) noexcept
 
template<class T >
optional< typename std::decay< T >::type > make_optional (T &&value)
 
template<typename... Us>
bool operator!= (const variant< Us... > &lhs, const variant< Us... > &rhs)
 
bool operator== (const util::monostate &, const util::monostate &)
 
template<typename... Us>
bool operator== (const variant< Us... > &lhs, const variant< Us... > &rhs)
 
template<typename T >
void suppress_unused_warning (const T &)
 Utility template function to prevent "unused" warnings by various compilers.
 
template<class ExceptionType >
void throw_error (ExceptionType &&e)
 
template<class value_t >
value_t & unsafe_any_cast (any &operand)
 
template<class value_t >
const value_t & unsafe_any_cast (const any &operand)
 
template<typename Visitor , typename Variant >
auto visit (Visitor &&visitor, const Variant &var) -> decltype(visitor(get< 0 >(var)))
 
template<typename Visitor , typename Variant , typename... VisitorArg>
auto visit (Visitor &visitor, const Variant &var, VisitorArg &&...args) -> decltype(visitor(get< 0 >(var)))
 

Typedef Documentation

◆ are_different_t

template<class T , class U , class V = void>
using cv::util::are_different_t = typedef enable_if_t< !std::is_same<decay_t<T>, decay_t<U> >::value, V>

◆ decay_t

template<typename T >
using cv::util::decay_t = typedef typename std::decay<T>::type

◆ enable_if_t

template<bool B, class T = void>
using cv::util::enable_if_t = typedef typename std::enable_if<B,T>::type

Function Documentation

◆ any_cast() [1/4]

template<class value_t >
value_t & cv::util::any_cast ( any operand)
Here is the call graph for this function:

◆ any_cast() [2/4]

template<class value_t >
value_t * cv::util::any_cast ( any operand)

◆ any_cast() [3/4]

template<class value_t >
const value_t & cv::util::any_cast ( const any operand)
Here is the call graph for this function:

◆ any_cast() [4/4]

template<class value_t >
const value_t * cv::util::any_cast ( const any operand)

◆ copy_through_move()

template<typename T >
copy_through_move_t< util::decay_t< T > > cv::util::copy_through_move ( T &&  t)

◆ get() [1/4]

template<typename T , typename... Types>
const T & cv::util::get ( const util::variant< Types... > &  v)
Here is the call graph for this function:

◆ get() [2/4]

template<std::size_t Index, typename... Types>
const util::type_list_element< Index, Types... >::type & cv::util::get ( const util::variant< Types... > &  v)
Here is the call graph for this function:

◆ get() [3/4]

template<typename T , typename... Types>
T & cv::util::get ( util::variant< Types... > &  v)
Here is the call graph for this function:

◆ get() [4/4]

template<std::size_t Index, typename... Types>
util::type_list_element< Index, Types... >::type & cv::util::get ( util::variant< Types... > &  v)
Here is the call graph for this function:

◆ get_if() [1/2]

template<typename T , typename... Types>
const T * cv::util::get_if ( const util::variant< Types... > *  v)
noexcept

◆ get_if() [2/2]

template<typename T , typename... Types>
T * cv::util::get_if ( util::variant< Types... > *  v)
noexcept

◆ holds_alternative()

template<typename T , typename... Types>
bool cv::util::holds_alternative ( const util::variant< Types... > &  v)
noexcept

◆ make_optional()

template<class T >
optional< typename std::decay< T >::type > cv::util::make_optional ( T &&  value)

◆ operator!=()

template<typename... Us>
bool cv::util::operator!= ( const variant< Us... > &  lhs,
const variant< Us... > &  rhs 
)

◆ operator==() [1/2]

bool cv::util::operator== ( const util::monostate ,
const util::monostate  
)
inline

◆ operator==() [2/2]

template<typename... Us>
bool cv::util::operator== ( const variant< Us... > &  lhs,
const variant< Us... > &  rhs 
)

◆ suppress_unused_warning()

template<typename T >
void cv::util::suppress_unused_warning ( const T &  )

Utility template function to prevent "unused" warnings by various compilers.

◆ throw_error()

template<class ExceptionType >
void cv::util::throw_error ( ExceptionType &&  e)

◆ unsafe_any_cast() [1/2]

template<class value_t >
value_t & cv::util::unsafe_any_cast ( any operand)
inline

◆ unsafe_any_cast() [2/2]

template<class value_t >
const value_t & cv::util::unsafe_any_cast ( const any operand)
inline

◆ visit() [1/2]

template<typename Visitor , typename Variant >
auto cv::util::visit ( Visitor &&  visitor,
const Variant &  var 
) -> decltype(visitor(get<0>(var)))

◆ visit() [2/2]

template<typename Visitor , typename Variant , typename... VisitorArg>
auto cv::util::visit ( Visitor &  visitor,
const Variant &  var,
VisitorArg &&...  args 
) -> decltype(visitor(get<0>(var)))