libalmemoryfastaccess  2.5.11.14a
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | List of all members
AL::ALMemoryFastAccess Class Reference

ALMemoryFastAccess is a fast access in Read/Write to some variables of ALMemory. More...

#include <almemoryfastaccess.h>

Public Member Functions

 ALMemoryFastAccess ()
 
 ~ALMemoryFastAccess ()
 
void StopAllAccess (void)
 Remove all pointer. More...
 
void insertBuffer (const std::string &pName, const ALValue &pBuff)
 Insert a binary ALValue in ALMemory. More...
 
void ConnectToVariables (const boost::shared_ptr< AL::ALBroker > pBroker, const std::vector< std::string > &pListVariables, bool bAllowNonExistantVariable=false)
 First time, you must "connect" to variables to access later, many times. More...
 
void ConnectToIntVariables (const boost::shared_ptr< AL::ALBroker > pBroker, const std::vector< std::string > &pListVariables)
 First time, you must "connect" to int variables to access later, many times. More...
 
void GetValues (std::vector< float > &pListValue) const
 Get previous "connected" variables. More...
 
void SetValues (const std::vector< float > &pListValue)
 Set previous "connected" variables. More...
 
void GetValues (std::vector< int > &pListValue) const
 Get previous "connected" variables. More...
 
void SetValues (const std::vector< int > &pListValue)
 Set previous "connected" variables. More...
 

Static Public Member Functions

static void * getDataPtr (boost::shared_ptr< AL::ALBroker > pBroker, const std::string &pStrValue, bool bAllowUnexistantVariable)
 Get pointer on 32bit data. More...
 
template<typename T >
static T * getSafeDataPtr (boost::shared_ptr< ALMemoryProxy > pMemoryProxy, const std::string &pStrValue, T pValue)
 Get pointer on 32bit data. More...
 
static bool InnerTest (const boost::shared_ptr< AL::ALBroker > pBroker)
 Test function. More...
 

Detailed Description

ALMemoryFastAccess is a fast access in Read/Write to some variables of ALMemory.

ALMemoryFastAccess is a fast access in Read/Write to some variables of ALMemory regularily accessed, with a unified interface.

Definition at line 40 of file almemoryfastaccess.h.

Constructor & Destructor Documentation

AL::ALMemoryFastAccess::ALMemoryFastAccess ( )
AL::ALMemoryFastAccess::~ALMemoryFastAccess ( )

Member Function Documentation

void AL::ALMemoryFastAccess::ConnectToIntVariables ( const boost::shared_ptr< AL::ALBroker pBroker,
const std::vector< std::string > &  pListVariables 
)

First time, you must "connect" to int variables to access later, many times.

Parameters
pBrokera pointer to the broker
pListVariableslist of variable names, eg: {"DCM/Sensor1", "DCM/Sensor2"} ...
void AL::ALMemoryFastAccess::ConnectToVariables ( const boost::shared_ptr< AL::ALBroker pBroker,
const std::vector< std::string > &  pListVariables,
bool  bAllowNonExistantVariable = false 
)

First time, you must "connect" to variables to access later, many times.

Parameters
pBrokera pointer to the broker
pListVariableslist of variable names, eg: {"DCM/Sensor1", "DCM/Sensor2"} ...
bAllowNonExistantVariableunused parameter
static void* AL::ALMemoryFastAccess::getDataPtr ( boost::shared_ptr< AL::ALBroker pBroker,
const std::string &  pStrValue,
bool  bAllowUnexistantVariable 
)
static

Get pointer on 32bit data.

Parameters
pBrokera pointer to the broker
pStrValuevalue name
bAllowUnexistantVariableunused parameter
template<typename T >
static T* AL::ALMemoryFastAccess::getSafeDataPtr ( boost::shared_ptr< ALMemoryProxy >  pMemoryProxy,
const std::string &  pStrValue,
pValue 
)
inlinestatic

Get pointer on 32bit data.

Parameters
pMemoryProxya pointer to the memory
pStrValuevalue name
pValuevalue to insert if pStrValue is non-existent

Definition at line 98 of file almemoryfastaccess.h.

void AL::ALMemoryFastAccess::GetValues ( std::vector< float > &  pListValue) const

Get previous "connected" variables.

Parameters
pListValuewhere to put the gathered value of variables
void AL::ALMemoryFastAccess::GetValues ( std::vector< int > &  pListValue) const

Get previous "connected" variables.

Parameters
pListValuewhere to put the gathered value of variables
static bool AL::ALMemoryFastAccess::InnerTest ( const boost::shared_ptr< AL::ALBroker pBroker)
static

Test function.

Parameters
pBrokera pointer to the broker
Returns
true if test ok, false otherwise
void AL::ALMemoryFastAccess::insertBuffer ( const std::string &  pName,
const ALValue &  pBuff 
)

Insert a binary ALValue in ALMemory.

Parameters
pNamevalue
pBuffALValue
void AL::ALMemoryFastAccess::SetValues ( const std::vector< float > &  pListValue)

Set previous "connected" variables.

Parameters
pListValueValue of variables to put into memory.
void AL::ALMemoryFastAccess::SetValues ( const std::vector< int > &  pListValue)

Set previous "connected" variables.

Parameters
pListValueValue of variables to put into memory.
void AL::ALMemoryFastAccess::StopAllAccess ( void  )

Remove all pointer.


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