OpenCV  4.3.0
Open Source Computer Vision
Public Member Functions | Protected Member Functions | List of all members
cv::TLSData< T > Class Template Reference

Simple TLS data class. More...

#include <opencv2/core/utils/tls.hpp>

Inheritance diagram for cv::TLSData< T >:
cv::TLSDataContainer cv::TLSDataAccumulator< T >

Public Member Functions

 TLSData ()
 
 ~TLSData ()
 
void cleanup ()
 Release associated thread data. More...
 
T * get () const
 Get data associated with key. More...
 
T & getRef () const
 Get data associated with key. More...
 

Protected Member Functions

virtual void * createDataInstance () const CV_OVERRIDE
 Wrapper to allocate data by template. More...
 
virtual void deleteDataInstance (void *pData) const CV_OVERRIDE
 Wrapper to release data by template. More...
 
- Protected Member Functions inherited from cv::TLSDataContainer
 TLSDataContainer ()
 
virtual ~TLSDataContainer ()
 
void detachData (std::vector< void *> &data)
 get TLS data and detach all data from threads (similar to cleanup() call) More...
 
void gatherData (std::vector< void *> &data) const
 
void * getData () const
 
void release ()
 
void cleanup ()
 Release created TLS data container objects. It is similar to release() call, but it keeps TLS container valid. More...
 

Detailed Description

template<typename T>
class cv::TLSData< T >

Simple TLS data class.

See also
TLSDataAccumulator

Constructor & Destructor Documentation

◆ TLSData()

template<typename T>
cv::TLSData< T >::TLSData ( )
inline

◆ ~TLSData()

template<typename T>
cv::TLSData< T >::~TLSData ( )
inline

Member Function Documentation

◆ cleanup()

template<typename T>
void cv::TLSData< T >::cleanup ( )
inline

Release associated thread data.

◆ createDataInstance()

template<typename T>
virtual void* cv::TLSData< T >::createDataInstance ( ) const
inlineprotectedvirtual

Wrapper to allocate data by template.

Implements cv::TLSDataContainer.

Reimplemented in cv::TLSDataAccumulator< T >, and cv::TLSDataAccumulator< cv::instr::NodeDataTls >.

◆ deleteDataInstance()

template<typename T>
virtual void cv::TLSData< T >::deleteDataInstance ( void *  pData) const
inlineprotectedvirtual

Wrapper to release data by template.

Implements cv::TLSDataContainer.

Reimplemented in cv::TLSDataAccumulator< T >, and cv::TLSDataAccumulator< cv::instr::NodeDataTls >.

◆ get()

template<typename T>
T* cv::TLSData< T >::get ( ) const
inline

Get data associated with key.

◆ getRef()

template<typename T>
T& cv::TLSData< T >::getRef ( ) const
inline

Get data associated with key.


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