replicode
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes | Friends | List of all members
mBrane::sdk::module::_Module Class Referenceabstract

#include <module.h>

Inheritance diagram for mBrane::sdk::module::_Module:
Inheritance graph
Collaboration diagram for mBrane::sdk::module::_Module:
Collaboration graph

Public Types

enum  Decision { DISCARD = 0, WAIT = 1, PREEMPT = 2 }
 

Public Member Functions

virtual ~_Module ()
 
virtual void loadParameters (const std::vector< int32_t > &numbers, const std::vector< std::string > &strings)
 
uint8_tpriority ()
 
bool canMigrate ()
 
bool isReady ()
 
virtual uint32_t dumpSize ()
 
virtual _Payloaddump ()
 
virtual void load (_Payload *chunk)
 
virtual void _start ()=0
 
virtual void _stop ()=0
 
virtual void migrateOut ()
 
virtual void migrateIn ()
 
virtual void notify (_Payload *p)=0
 
virtual void notify (uint16_t sid, _Payload *p)=0
 
virtual Decision dispatch (_Payload *p)=0
 
- Public Member Functions inherited from core::_Object
virtual ~_Object ()
 
void incRef ()
 
virtual void decRef ()
 

Protected Member Functions

 _Module ()
 
void sleep (int64_t d)
 
void wait (std::thread *threads[], uint32_t threadCount)
 
void wait (std::thread *_thread)
 
- Protected Member Functions inherited from core::_Object
 _Object ()
 

Protected Attributes

uint16_t _cid
 
uint16_t _id
 
bool _canMigrate
 
uint8_t _priority
 
bool _ready
 
- Protected Attributes inherited from core::_Object
std::atomic_int refCount
 

Private Attributes

XThreadprocessor
 
std::mutex mutex
 
ModuleDescriptordescriptor
 

Friends

class mBrane::Node
 
class mBrane::XThread
 
class mBrane::ModuleDescriptor
 

Member Enumeration Documentation

Enumerator
DISCARD 
WAIT 
PREEMPT 

Constructor & Destructor Documentation

mBrane::sdk::module::_Module::_Module ( )
protected
mBrane::sdk::module::_Module::~_Module ( )
virtual

Here is the call graph for this function:

Member Function Documentation

virtual void mBrane::sdk::module::_Module::_start ( )
pure virtual

Implemented in Module< U >, and LibraryModule< U >.

Here is the caller graph for this function:

virtual void mBrane::sdk::module::_Module::_stop ( )
pure virtual

Implemented in Module< U >, and LibraryModule< U >.

Here is the caller graph for this function:

bool mBrane::sdk::module::_Module::canMigrate ( )
inline

Here is the caller graph for this function:

virtual Decision mBrane::sdk::module::_Module::dispatch ( _Payload p)
pure virtual

Here is the caller graph for this function:

_Payload * mBrane::sdk::module::_Module::dump ( )
virtual
uint32_t mBrane::sdk::module::_Module::dumpSize ( )
virtual
bool mBrane::sdk::module::_Module::isReady ( )
void mBrane::sdk::module::_Module::load ( _Payload chunk)
virtual
virtual void mBrane::sdk::module::_Module::loadParameters ( const std::vector< int32_t > &  numbers,
const std::vector< std::string > &  strings 
)
inlinevirtual

Here is the caller graph for this function:

void mBrane::sdk::module::_Module::migrateIn ( )
inlinevirtual
void mBrane::sdk::module::_Module::migrateOut ( )
inlinevirtual
virtual void mBrane::sdk::module::_Module::notify ( _Payload p)
pure virtual

Here is the caller graph for this function:

virtual void mBrane::sdk::module::_Module::notify ( uint16_t  sid,
_Payload p 
)
pure virtual
uint8_t & mBrane::sdk::module::_Module::priority ( )
inline
void mBrane::sdk::module::_Module::sleep ( int64_t  d)
protected
void mBrane::sdk::module::_Module::wait ( std::thread threads[],
uint32_t  threadCount 
)
protected
void mBrane::sdk::module::_Module::wait ( std::thread _thread)
protected

Friends And Related Function Documentation

friend class mBrane::ModuleDescriptor
friend
friend class mBrane::Node
friend
friend class mBrane::XThread
friend

Member Data Documentation

bool mBrane::sdk::module::_Module::_canMigrate
protected
uint16_t mBrane::sdk::module::_Module::_cid
protected
uint16_t mBrane::sdk::module::_Module::_id
protected
uint8_t mBrane::sdk::module::_Module::_priority
protected
bool mBrane::sdk::module::_Module::_ready
protected
ModuleDescriptor* mBrane::sdk::module::_Module::descriptor
private
std::mutex mBrane::sdk::module::_Module::mutex
private
XThread* mBrane::sdk::module::_Module::processor
private

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