cv::dnn::Dict Class Reference DNN (深度神经网络) 模块


This class implements name-value dictionary, values are instances of DictValue . 更多...

#include <opencv2/dnn/dict.hpp>

Inheritance diagram for cv::dnn::Dict:
cv::dnn::LayerParams

Public Member Functions

std::map< 字符串 , DictValue >::const_iterator  begin () const
 
std::map< 字符串 , DictValue >::const_iterator  end () const
 
void  erase (const 字符串 &key)
  Erase key from the dictionary. 更多...
 
const DictValue get (const 字符串 &key) const
  key in the dictionary then returns its value, else an error will be generated. 更多...
 
template<typename T >
get (const 字符串 &key) const
 
template<typename T >
get (const 字符串 &key, const T &defaultValue) const
  key in the dictionary then returns its value, else returns defaultValue . 更多...
 
bool  has (const 字符串 &key) const
  Checks a presence of the key in the dictionary. 更多...
 
DictValue ptr (const 字符串 &key)
  key in the dictionary then returns pointer to its value, else returns NULL. 更多...
 
const DictValue ptr (const 字符串 &key) const
 
template<typename T >
const T &  set (const 字符串 &key, const T &value)
  Sets new value key , or adds new key-value pair into the dictionary. 更多...
 

Friends

std::ostream &  operator<< (std::ostream &stream, const Dict &dict)
 

详细描述

This class implements name-value dictionary, values are instances of DictValue .

成员函数文档编制

◆  begin()

std::map< 字符串 , DictValue >::const_iterator cv::dnn::Dict::begin ( ) const

◆  end()

std::map< 字符串 , DictValue >::const_iterator cv::dnn::Dict::end ( ) const

◆  erase()

void cv::dnn::Dict::erase ( const 字符串 key )

Erase key from the dictionary.

◆  get() [1/3]

const DictValue & cv::dnn::Dict::get ( const 字符串 key ) const

key in the dictionary then returns its value, else an error will be generated.

◆  get() [2/3]

template<typename T >
T cv::dnn::Dict::get ( const 字符串 key ) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆  get() [3/3]

template<typename T >
T cv::dnn::Dict::get ( const 字符串 key ,
const T &  defaultValue  
) const

key in the dictionary then returns its value, else returns defaultValue .

◆  has()

bool cv::dnn::Dict::has ( const 字符串 key ) const

Checks a presence of the key in the dictionary.

◆  ptr() [1/2]

DictValue * cv::dnn::Dict::ptr ( const 字符串 key )

key in the dictionary then returns pointer to its value, else returns NULL.

◆  ptr() [2/2]

const DictValue * cv::dnn::Dict::ptr ( const 字符串 key ) const

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆  set()

template<typename T >
const T& cv::dnn::Dict::set ( const 字符串 key ,
const T &  value  
)

Sets new value key , or adds new key-value pair into the dictionary.

Friends And Related Function Documentation

◆  operator <<

std::ostream& operator<< ( std::ostream &  stream ,
const Dict dict  
)
friend

The documentation for this class was generated from the following file: