DataDisplayVisitor.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <sstream>
4 
6 
7 #include "StringStreamMixin.h"
8 
9 namespace armarx::aron
10 {
11 
13  {
14  public:
15  static std::string getValue(const data::VariantPtr& n);
16 
17 
18  public:
19  void visitDict(const data::VariantPtr& n) override;
20  void visitList(const data::VariantPtr& n) override;
21 
22  void visitBool(const data::VariantPtr& b) override;
23  void visitDouble(const data::VariantPtr& n) override;
24  void visitFloat(const data::VariantPtr& n) override;
25  void visitInt(const data::VariantPtr& n) override;
26  void visitLong(const data::VariantPtr& n) override;
27  void visitString(const data::VariantPtr& n) override;
28 
29  void visitNDArray(const data::VariantPtr& n) override;
30 
31  private:
32  template <typename ScalarT>
33  void processMatrix(const data::NDArray& data);
34 
35  void printShape(const data::NDArray& data);
36  };
37 
38 } // namespace armarx::aron
armarx::aron::DataDisplayVisitor::visitBool
void visitBool(const data::VariantPtr &b) override
Definition: DataDisplayVisitor.cpp:31
armarx::aron::data::ConstVariantVisitor
Definition: VariantVisitor.h:39
armarx::aron::data::NDArray
Definition: NDArray.h:48
armarx::aron::StringStreamMixin
Definition: StringStreamMixin.h:10
armarx::aron::DataDisplayVisitor::visitList
void visitList(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:24
StringStreamMixin.h
armarx::aron::data::VariantPtr
std::shared_ptr< Variant > VariantPtr
Definition: forward_declarations.h:11
armarx::aron::DataDisplayVisitor::visitFloat
void visitFloat(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:52
armarx::aron::DataDisplayVisitor::visitDict
void visitDict(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:17
armarx::aron::DataDisplayVisitor::visitNDArray
void visitNDArray(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:80
armarx::aron
Definition: DataDisplayVisitor.cpp:5
data
uint8_t data[1]
Definition: EtherCATFrame.h:68
armarx::aron::DataDisplayVisitor
Definition: DataDisplayVisitor.h:12
armarx::aron::DataDisplayVisitor::visitLong
void visitLong(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:66
armarx::aron::DataDisplayVisitor::getValue
static std::string getValue(const data::VariantPtr &n)
Definition: DataDisplayVisitor.cpp:9
armarx::aron::DataDisplayVisitor::visitString
void visitString(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:73
armarx::aron::DataDisplayVisitor::visitInt
void visitInt(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:59
armarx::aron::DataDisplayVisitor::visitDouble
void visitDouble(const data::VariantPtr &n) override
Definition: DataDisplayVisitor.cpp:45
VariantVisitor.h