Converter.h
Go to the documentation of this file.
1 #pragma once
2 
3 // STD/STL
4 #include <memory>
5 
6 // BaseClass
7 #include "../Converter.h"
8 
9 // ArmarX
11 
13 {
15  {
16  public:
17  ObjectConverter(const ConverterType t, const std::string& id, const std::string& s) :
18  DataConverter(t, id, s, aron::type::Descriptor::OBJECT, nullptr)
19  {
20  }
21 
22  virtual ~ObjectConverter() = default;
23 
24  ConversionResult convert(const aron::data::VariantPtr& data) final;
25  aron::data::VariantPtr convert(const ConversionResult& data,
26  const armarx::aron::Path& p) final;
27 
28  protected:
29  virtual ConversionResult _convert(const aron::data::DictPtr& data) = 0;
30  virtual aron::data::DictPtr _convert(const ConversionResult& data,
31  const armarx::aron::Path& p) = 0;
32  };
33 } // namespace armarx::armem::server::ltm::processor::converter::data
armarx::armem::server::ltm::processor::converter::data::ObjectConverter::ObjectConverter
ObjectConverter(const ConverterType t, const std::string &id, const std::string &s)
Definition: Converter.h:17
armarx::armem::server::ltm::processor::converter::data::ObjectConverter::~ObjectConverter
virtual ~ObjectConverter()=default
armarx::armem::server::ltm::processor::DataConverter
Definition: Converter.h:16
armarx::armem::server::ltm::processor::converter::data::ObjectConverter
Definition: Converter.h:14
Dict.h
armarx::aron::Path
The Path class.
Definition: Path.h:36
armarx::aron::data::VariantPtr
std::shared_ptr< Variant > VariantPtr
Definition: forward_declarations.h:11
armarx::armem::server::ltm::processor::DataConverter::type
const ConverterType type
Definition: Converter.h:49
data
uint8_t data[1]
Definition: EtherCATFrame.h:68
armarx::armem::server::ltm::processor::converter::data::ObjectConverter::convert
ConversionResult convert(const aron::data::VariantPtr &data) final
Definition: Converter.cpp:7
armarx::armem::server::ltm::processor::converter::data
Definition: Converter.cpp:3
armarx::aron::data::DictPtr
std::shared_ptr< Dict > DictPtr
Definition: Dict.h:41
armarx::armem::server::ltm::processor::converter::data::ObjectConverter::_convert
virtual ConversionResult _convert(const aron::data::DictPtr &data)=0
armarx::aron::type::Descriptor
Descriptor
Definition: Descriptor.h:76
armarx::ctrlutil::s
double s(double t, double s0, double v0, double a0, double j)
Definition: CtrlUtil.h:33
armarx::armem::server::ltm::processor::DataConverter::ConverterType
ConverterType
Definition: Converter.h:19