Robox Library for Cpp: BCC/31 module 1.0.0
RLibCpp BCC/31 protocol implementation
Public Member Functions | Protected Member Functions | List of all members
Connection::VariablesCacheItem Class Reference

Class to handle an item in the variables cache. More...

#include <connection.h>

Public Member Functions

 VariablesCacheItem ()
 Default class constructor.
 
 ~VariablesCacheItem ()
 Virtual class destructor.
 
void cleanup ()
 Cache cleanup.
 
Message::DataTypes dataType ()
 Get the variable data type.
 
String name () const
 Get the name.
 
void setName (String value)
 Set the name.
 
RVar::Index * srcIndex () const
 Get the original RVar::Index i.e the index as parsed from user input before splitting.
 
void setSrcIndex (RVar::Index *value)
 Set the original RVar::Index i.e the index as parsed from user input before splitting.
 
bool useCoherentValues () const
 Get the to ensure the variable will be handled with coherent operations (i.e. varDataList() will contains just one item)
 
void setUseCoherentValues (bool value)
 Set the to ensure the variable will be handled with coherent operations (i.e. varDataList() will contains just one item)
 
uint32_t splitOffset () const
 Get the offset used in the last splitting.
 
void setSplitOffset (uint32_t value)
 Set the offset used in the last splitting.
 
RVar::Dict::VarData::PtrVector & varDataList ()
 Get the list of variable data.
 

Protected Member Functions

Message::DataTypes baseTypeToDataType (uint32_t baseType)
 

Detailed Description

Class to handle an item in the variables cache.

Constructor & Destructor Documentation

◆ VariablesCacheItem()

Default class constructor.

◆ ~VariablesCacheItem()

Virtual class destructor.

Member Function Documentation

◆ baseTypeToDataType()

Message::DataTypes baseTypeToDataType ( uint32_t baseType)
protected

◆ cleanup()

void cleanup ( )

Cache cleanup.

◆ dataType()

Message::DataTypes dataType ( )

Get the variable data type.

◆ name()

String name ( ) const

Get the name.

Returns
The parameter value

◆ setName()

void setName ( String value)

Set the name.

Parameters
valueThe value to set

◆ setSplitOffset()

void setSplitOffset ( uint32_t value)

Set the offset used in the last splitting.

Parameters
valueThe value to set
Remarks
Changing this value between consecutive access will cause a new variable splitting and consequently performanca issue That will tipically occurs when mixing Oscilloscope and raw Read/Write access.
It is advisable to cache a variable for each type of access Oscilloscope and Read/Write. Use the extraTag param of the addToVarsCache(const String &, const String &) method for that

◆ setSrcIndex()

void setSrcIndex ( RVar::Index * value)

Set the original RVar::Index i.e the index as parsed from user input before splitting.

Parameters
valueThe value to set

◆ setUseCoherentValues()

void setUseCoherentValues ( bool value)

Set the to ensure the variable will be handled with coherent operations (i.e. varDataList() will contains just one item)

Parameters
valueThe value to set
Remarks
Changing this value between consecutive access will cause a new variable splitting and consequently performanca issue That will tipically occurs when mixing Oscilloscope and raw Read/Write access.
It is advisable to cache a variable for each type of access coherent or not. Use the extraTag param of the addToVarsCache(const String &, const String &) method for that

◆ splitOffset()

uint32_t splitOffset ( ) const

Get the offset used in the last splitting.

Returns
The parameter value
Remarks
Changing this value between consecutive access will cause a new variable splitting and consequently performanca issue That will tipically occurs when mixing Oscilloscope and raw Read/Write access.
It is advisable to cache a variable for each type of access Oscilloscope and Read/Write. Use the extraTag param of the addToVarsCache(const String &, const String &) method for that

◆ srcIndex()

RVar::Index * srcIndex ( ) const

Get the original RVar::Index i.e the index as parsed from user input before splitting.

Returns
The parameter value

◆ useCoherentValues()

bool useCoherentValues ( ) const

Get the to ensure the variable will be handled with coherent operations (i.e. varDataList() will contains just one item)

Returns
The parameter value
Remarks
Changing this value between consecutive access will cause a new variable splitting and consequently performanca issue That will tipically occurs when mixing Oscilloscope and raw Read/Write access.
It is advisable to cache a variable for each type of access coherent or not. Use the extraTag param of the addToVarsCache(const String &, const String &) method for that

◆ varDataList()

RVar::Dict::VarDataList & varDataList ( )

Get the list of variable data.

Returns
The parameter value