PlotComponent Class Reference
A container of the component data that keeps track of the registered attributes and update their values and their registered charts. More...
#include <Plotting.hh>
Public Member Functions | |
| PlotComponent (const std::string &_type, Entity _entity, ComponentTypeId _typeId) | |
| Constructor.   | |
| ~PlotComponent () | |
| Destructor.   | |
| std::map< std::string, std::shared_ptr< gz::gui::PlotData > > | Data () const | 
| Get all attributes of the component.   | |
| Entity | Entity () | 
| Get the Component entity ID.   | |
| bool | HasCharts () | 
| Check if any of the component attributes has any chart.   | |
| void | RegisterChart (std::string _attribute, int _chart) | 
| Add a registered chart to the attribute.   | |
| void | SetAttributeValue (std::string _attribute, const double &_value) | 
| Set a value of specific component attribute.   | |
| ComponentTypeId | TypeId () | 
| Get the Component type ID.   | |
| void | UnRegisterChart (std::string _attribute, int _chart) | 
| Remove a registered chart from the attribute.   | |
Detailed Description
A container of the component data that keeps track of the registered attributes and update their values and their registered charts.
Constructor & Destructor Documentation
◆ PlotComponent()
| PlotComponent | ( | const std::string & | _type, | 
| Entity | _entity, | ||
| ComponentTypeId | _typeId | ||
| ) | 
Constructor.
- Parameters
 - 
  
[in] _type component data type (Pose3d, Vector3d, double) [in] _entity entity id of that component [in] _typeId type identifier unique to each component type  
◆ ~PlotComponent()
| ~PlotComponent | ( | ) | 
Destructor.
Member Function Documentation
◆ Data()
| std::map< std::string, std::shared_ptr< gz::gui::PlotData > > Data | ( | ) | const | 
Get all attributes of the component.
- Returns
 - component attributes
 
◆ Entity()
◆ HasCharts()
| bool HasCharts | ( | ) | 
Check if any of the component attributes has any chart.
- Returns
 - true if any attribute has a chart false if all attributes are empty from the charts
 
◆ RegisterChart()
| void RegisterChart | ( | std::string | _attribute, | 
| int | _chart | ||
| ) | 
Add a registered chart to the attribute.
- Parameters
 - 
  
[in] _attribute component attribute to add the chart to it [in] _chart chart ID to be added to the attribute  
◆ SetAttributeValue()
| void SetAttributeValue | ( | std::string | _attribute, | 
| const double & | _value | ||
| ) | 
Set a value of specific component attribute.
- Parameters
 - 
  
[in] _attribute component attribute to set its value ex : yaw attribute in Pose3d type Component [in] _value value to be set to the attribute  
◆ TypeId()
| ComponentTypeId TypeId | ( | ) | 
Get the Component type ID.
- Returns
 - component type ID
 
◆ UnRegisterChart()
| void UnRegisterChart | ( | std::string | _attribute, | 
| int | _chart | ||
| ) | 
Remove a registered chart from the attribute.
- Parameters
 - 
  
[in] _attribute component attribute to remove the chart from it [in] _chart chart ID to be removed from the attribute  
The documentation for this class was generated from the following file: