Classes | Public Types | Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | List of all members
canopen::ObjectStorage Class Reference

#include <objdict.h>

Classes

class  Data
 
struct  DataType
 
struct  DataType< ObjectDict::DEFTYPE_DOMAIN >
 
struct  DataType< ObjectDict::DEFTYPE_INTEGER16 >
 
struct  DataType< ObjectDict::DEFTYPE_INTEGER32 >
 
struct  DataType< ObjectDict::DEFTYPE_INTEGER64 >
 
struct  DataType< ObjectDict::DEFTYPE_INTEGER8 >
 
struct  DataType< ObjectDict::DEFTYPE_OCTET_STRING >
 
struct  DataType< ObjectDict::DEFTYPE_REAL32 >
 
struct  DataType< ObjectDict::DEFTYPE_REAL64 >
 
struct  DataType< ObjectDict::DEFTYPE_UNICODE_STRING >
 
struct  DataType< ObjectDict::DEFTYPE_UNSIGNED16 >
 
struct  DataType< ObjectDict::DEFTYPE_UNSIGNED32 >
 
struct  DataType< ObjectDict::DEFTYPE_UNSIGNED64 >
 
struct  DataType< ObjectDict::DEFTYPE_UNSIGNED8 >
 
struct  DataType< ObjectDict::DEFTYPE_VISIBLE_STRING >
 
class  Entry
 

Public Types

typedef boost::shared_ptr< ObjectStorageObjectStorageSharedPtr
 
typedef fastdelegate::FastDelegate2< const ObjectDict::Entry &, String & > ReadDelegate
 
typedef boost::function< std::string()> ReadStringFuncType
 
typedef fastdelegate::FastDelegate2< const ObjectDict::Entry &, const String & > WriteDelegate
 
typedef boost::function< void(const std::string &)> WriteStringFuncType
 

Public Member Functions

template<typename T >
Entry< T > entry (const ObjectDict::Key &key)
 
template<typename T >
Entry< T > entry (uint16_t index)
 
template<typename T >
Entry< T > entry (uint16_t index, uint8_t sub_index)
 
template<typename T >
void entry (Entry< T > &e, uint16_t index)
 
template<typename T >
void entry (Entry< T > &e, uint16_t index, uint8_t sub_index)
 
template<typename T >
bool entry (Entry< T > &e, const ObjectDict::Key &k)
 
ReadStringFuncType getStringReader (const ObjectDict::Key &key, bool cached=false)
 
WriteStringFuncType getStringWriter (const ObjectDict::Key &key, bool cached=false)
 
void init (const ObjectDict::Key &key)
 
void init_all ()
 
size_t map (uint16_t index, uint8_t sub_index, const ReadDelegate &read_delegate, const WriteDelegate &write_delegate)
 
 ObjectStorage (ObjectDictConstSharedPtr dict, uint8_t node_id, ReadDelegate read_delegate, WriteDelegate write_delegate)
 
void reset ()
 

Public Attributes

const ObjectDictConstSharedPtr dict_
 
const uint8_t node_id_
 

Protected Types

typedef boost::shared_ptr< DataDataSharedPtr
 

Protected Member Functions

void init_nolock (const ObjectDict::Key &key, const ObjectDict::EntryConstSharedPtr &entry)
 
size_t map (const ObjectDict::EntryConstSharedPtr &e, const ObjectDict::Key &key, const ReadDelegate &read_delegate, const WriteDelegate &write_delegate)
 

Protected Attributes

boost::mutex mutex_
 
ReadDelegate read_delegate_
 
boost::unordered_map< ObjectDict::Key, DataSharedPtrstorage_
 
WriteDelegate write_delegate_
 

Detailed Description

Definition at line 272 of file objdict.h.

Member Typedef Documentation

typedef boost::shared_ptr<Data> canopen::ObjectStorage::DataSharedPtr
protected

Definition at line 370 of file objdict.h.

Definition at line 276 of file objdict.h.

Definition at line 274 of file objdict.h.

typedef boost::function<std::string()> canopen::ObjectStorage::ReadStringFuncType

Definition at line 510 of file objdict.h.

Definition at line 275 of file objdict.h.

typedef boost::function<void(const std::string &)> canopen::ObjectStorage::WriteStringFuncType

Definition at line 512 of file objdict.h.

Constructor & Destructor Documentation

ObjectStorage::ObjectStorage ( ObjectDictConstSharedPtr  dict,
uint8_t  node_id,
ReadDelegate  read_delegate,
WriteDelegate  write_delegate 
)

Definition at line 384 of file objdict.cpp.

Member Function Documentation

template<typename T >
Entry<T> canopen::ObjectStorage::entry ( const ObjectDict::Key key)
inline

Definition at line 455 of file objdict.h.

template<typename T >
Entry<T> canopen::ObjectStorage::entry ( uint16_t  index)
inline

Definition at line 489 of file objdict.h.

template<typename T >
Entry<T> canopen::ObjectStorage::entry ( uint16_t  index,
uint8_t  sub_index 
)
inline

Definition at line 492 of file objdict.h.

template<typename T >
void canopen::ObjectStorage::entry ( Entry< T > &  e,
uint16_t  index 
)
inline

Definition at line 496 of file objdict.h.

template<typename T >
void canopen::ObjectStorage::entry ( Entry< T > &  e,
uint16_t  index,
uint8_t  sub_index 
)
inline

Definition at line 499 of file objdict.h.

template<typename T >
bool canopen::ObjectStorage::entry ( Entry< T > &  e,
const ObjectDict::Key k 
)
inline

Definition at line 502 of file objdict.h.

ObjectStorage::ReadStringFuncType ObjectStorage::getStringReader ( const ObjectDict::Key key,
bool  cached = false 
)

Definition at line 450 of file objdict.cpp.

ObjectStorage::WriteStringFuncType ObjectStorage::getStringWriter ( const ObjectDict::Key key,
bool  cached = false 
)

Definition at line 477 of file objdict.cpp.

void ObjectStorage::init ( const ObjectDict::Key key)

Definition at line 407 of file objdict.cpp.

void ObjectStorage::init_all ( )

Definition at line 411 of file objdict.cpp.

void ObjectStorage::init_nolock ( const ObjectDict::Key key,
const ObjectDict::EntryConstSharedPtr entry 
)
protected

Definition at line 391 of file objdict.cpp.

size_t ObjectStorage::map ( const ObjectDict::EntryConstSharedPtr e,
const ObjectDict::Key key,
const ReadDelegate read_delegate,
const WriteDelegate write_delegate 
)
protected

Definition at line 334 of file objdict.cpp.

size_t ObjectStorage::map ( uint16_t  index,
uint8_t  sub_index,
const ReadDelegate read_delegate,
const WriteDelegate write_delegate 
)

Definition at line 367 of file objdict.cpp.

void ObjectStorage::reset ( )

Definition at line 420 of file objdict.cpp.

Member Data Documentation

const ObjectDictConstSharedPtr canopen::ObjectStorage::dict_

Definition at line 515 of file objdict.h.

boost::mutex canopen::ObjectStorage::mutex_
protected

Definition at line 447 of file objdict.h.

const uint8_t canopen::ObjectStorage::node_id_

Definition at line 516 of file objdict.h.

ReadDelegate canopen::ObjectStorage::read_delegate_
protected

Definition at line 451 of file objdict.h.

boost::unordered_map<ObjectDict::Key, DataSharedPtr > canopen::ObjectStorage::storage_
protected

Definition at line 446 of file objdict.h.

WriteDelegate canopen::ObjectStorage::write_delegate_
protected

Definition at line 452 of file objdict.h.


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


canopen_master
Author(s): Mathias Lüdtke
autogenerated on Sat May 4 2019 02:40:43