OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | List of all members
ossimCallback1< P1 > Class Template Referenceabstract

Usage example, note template params can be anything: More...

#include <ossimCallback1.h>

Public Member Functions

 ossimCallback1 ()
 
virtual ~ossimCallback1 ()
 
virtual void operator() (P1 p1) const =0
 

Detailed Description

template<class P1>
class ossimCallback1< P1 >

Usage example, note template params can be anything:

Caller interface to register callback:

void registerCallback(ossimCallback1<const ossimFilename&>* cb);

Callee creation of call back mechanism:

class ProcessFileCB: public ossimCallback1<const ossimFilename&>
{
public:
ProcessFileCB(
:
m_obj(obj),
m_func(func)
{}
virtual void operator()(const ossimFilename& file) const
{
( m_obj->*m_func)(file);
}
private:
void (ossimImageElevationDatabase::*m_func)(const ossimFilename& file);
};

Making/registering a callback.

new ProcessFileCB(this, &ossimImageElevationDatabase::processFile);
fw->registerProcessFileCallback(cb);

Definition at line 73 of file ossimCallback1.h.

Constructor & Destructor Documentation

◆ ossimCallback1()

template<class P1>
ossimCallback1< P1 >::ossimCallback1 ( )
inline

Definition at line 76 of file ossimCallback1.h.

76 {}

◆ ~ossimCallback1()

template<class P1>
virtual ossimCallback1< P1 >::~ossimCallback1 ( )
inlinevirtual

Definition at line 77 of file ossimCallback1.h.

77 {}

Member Function Documentation

◆ operator()()

template<class P1>
virtual void ossimCallback1< P1 >::operator() ( P1  p1) const
pure virtual

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